[Bug 1916715] Re: fails on install due to systemd-service/sysv-service mismatch and lack of mkdir

Christian Ehrhardt  1916715 at bugs.launchpad.net
Wed Apr 7 06:26:10 UTC 2021


#2 Container without modules installed

old:
● rtslib-fb-targetctl.service - LSB: Start LIO targets
     Loaded: loaded (/etc/init.d/rtslib-fb-targetctl; generated)
     Active: active (exited) since Wed 2021-04-07 06:14:25 UTC; 8s ago
       Docs: man:systemd-sysv-generator(8)
      Tasks: 0 (limit: 38268)
     Memory: 0B
     CGroup: /system.slice/rtslib-fb-targetctl.service

Apr 07 06:14:25 python-rtslib-fb-lp1916715-groovy systemd[1]: Starting LSB: Start LIO targets...
Apr 07 06:14:25 python-rtslib-fb-lp1916715-groovy rtslib-fb-targetctl[1193]: modprobe: FATAL: Module configfs not found in directory /lib/modules/5.4.0-70-generic
Apr 07 06:14:25 python-rtslib-fb-lp1916715-groovy rtslib-fb-targetctl[1187]: Could not load configfs module: exiting!
Apr 07 06:14:25 python-rtslib-fb-lp1916715-groovy systemd[1]: Started LSB: Start LIO targets.


new:
root at python-rtslib-fb-lp1916715-groovy-fixed:~# systemctl status rtslib-fb-targetctl.service
● rtslib-fb-targetctl.service - Restore LIO kernel target configuration
     Loaded: loaded (/lib/systemd/system/rtslib-fb-targetctl.service; enabled; vendor preset: enabled)
     Active: inactive (dead)

Apr 07 06:14:26 python-rtslib-fb-lp1916715-groovy-fixed systemd[1]:
Condition check resulted in Restore LIO kernel target configuration
being skipped.


=> better error message, no degradation



#2 VM with kernel&modules properly in place for LIO:


old:
ubuntu at g-1916715:~$ sudo apt install python3-rtslib-fb
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  python3-pyudev
The following NEW packages will be installed:
  python3-pyudev python3-rtslib-fb
0 upgraded, 2 newly installed, 0 to remove and 0 not upgraded.
Need to get 86.0 kB of archives.
After this operation, 639 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://archive.ubuntu.com/ubuntu groovy/main amd64 python3-pyudev all 0.21.0-3ubuntu1 [37.1 kB]
Get:2 http://archive.ubuntu.com/ubuntu groovy/main amd64 python3-rtslib-fb all 2.1.73-1ubuntu4 [48.9 kB]
Fetched 86.0 kB in 0s (546 kB/s)        
Selecting previously unselected package python3-pyudev.
(Reading database ... 73160 files and directories currently installed.)
Preparing to unpack .../python3-pyudev_0.21.0-3ubuntu1_all.deb ...
Unpacking python3-pyudev (0.21.0-3ubuntu1) ...
Selecting previously unselected package python3-rtslib-fb.
Preparing to unpack .../python3-rtslib-fb_2.1.73-1ubuntu4_all.deb ...
Unpacking python3-rtslib-fb (2.1.73-1ubuntu4) ...
Setting up python3-pyudev (0.21.0-3ubuntu1) ...
Setting up python3-rtslib-fb (2.1.73-1ubuntu4) ...
Job for rtslib-fb-targetctl.service failed because the control process exited with error code.
See "systemctl status rtslib-fb-targetctl.service" and "journalctl -xe" for details.
invoke-rc.d: initscript rtslib-fb-targetctl, action "start" failed.
● rtslib-fb-targetctl.service - LSB: Start LIO targets
     Loaded: loaded (/etc/init.d/rtslib-fb-targetctl; generated)
     Active: failed (Result: exit-code) since Wed 2021-04-07 06:25:13 UTC; 8ms ago
       Docs: man:systemd-sysv-generator(8)
    Process: 1327 ExecStart=/etc/init.d/rtslib-fb-targetctl start (code=exited, status=1/FAILURE)

Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     errors = RTSRoot().restore_from_file(restore_file=from_file)
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 88, in __init__
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     self._set_dbroot()
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 182, in _set_dbroot
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     raise RTSLibError("Cannot set dbroot to {}. Please check if this directory exists."
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]: rtslib_fb.utils.RTSLibError: Cannot set dbroot to /etc/rtslib-fb-target. Please check if this directory exists.
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1327]:    ...fail!
Apr 07 06:25:13 g-1916715 systemd[1]: rtslib-fb-targetctl.service: Control process exited, code=exited, status=1/FAILURE
Apr 07 06:25:13 g-1916715 systemd[1]: rtslib-fb-targetctl.service: Failed with result 'exit-code'.
Apr 07 06:25:13 g-1916715 systemd[1]: Failed to start LSB: Start LIO targets.
dpkg: error processing package python3-rtslib-fb (--configure):
 installed python3-rtslib-fb package post-installation script subprocess returned error exit status 1
Processing triggers for man-db (2.9.3-2) ...
Processing triggers for systemd (246.6-1ubuntu1.3) ...
Errors were encountered while processing:
 python3-rtslib-fb
E: Sub-process /usr/bin/dpkg returned an error code (1)
ubuntu at g-1916715:~$ systemctl status rtslib-fb-targetctl.service
● rtslib-fb-targetctl.service - LSB: Start LIO targets
     Loaded: loaded (/etc/init.d/rtslib-fb-targetctl; generated)
     Active: failed (Result: exit-code) since Wed 2021-04-07 06:25:13 UTC; 13s ago
       Docs: man:systemd-sysv-generator(8)

Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     errors = RTSRoot().restore_from_file(restore_file=from_file)
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 88, in __init__
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     self._set_dbroot()
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 182, in _set_dbroot
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]:     raise RTSLibError("Cannot set dbroot to {}. Please check if this directory exists."
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1339]: rtslib_fb.utils.RTSLibError: Cannot set dbroot to /etc/rtslib-fb-target. Please check if this directory exists.
Apr 07 06:25:13 g-1916715 rtslib-fb-targetctl[1327]:    ...fail!
Apr 07 06:25:13 g-1916715 systemd[1]: rtslib-fb-targetctl.service: Control process exited, code=exited, status=1/FAILURE
Apr 07 06:25:13 g-1916715 systemd[1]: rtslib-fb-targetctl.service: Failed with result 'exit-code'.
Apr 07 06:25:13 g-1916715 systemd[1]: Failed to start LSB: Start LIO targets.



new:
ubuntu at g-1916715-fixed:~$ sudo apt install python3-rtslib-fb
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  python3-pyudev
The following NEW packages will be installed:
  python3-pyudev python3-rtslib-fb
0 upgraded, 2 newly installed, 0 to remove and 20 not upgraded.
Need to get 86.2 kB of archives.
After this operation, 640 kB of additional disk space will be used.
Do you want to continue? [Y/n] Y
Get:1 http://archive.ubuntu.com/ubuntu groovy/main amd64 python3-pyudev all 0.21.0-3ubuntu1 [37.1 kB]
Get:2 http://archive.ubuntu.com/ubuntu groovy-proposed/main amd64 python3-rtslib-fb all 2.1.73-1ubuntu4.1 [49.2 kB]                                                                           
Fetched 86.2 kB in 31s (2808 B/s)                                                                                                                                                             
Selecting previously unselected package python3-pyudev.
(Reading database ... 73160 files and directories currently installed.)
Preparing to unpack .../python3-pyudev_0.21.0-3ubuntu1_all.deb ...
Unpacking python3-pyudev (0.21.0-3ubuntu1) ...
Selecting previously unselected package python3-rtslib-fb.
Preparing to unpack .../python3-rtslib-fb_2.1.73-1ubuntu4.1_all.deb ...
Unpacking python3-rtslib-fb (2.1.73-1ubuntu4.1) ...
Setting up python3-pyudev (0.21.0-3ubuntu1) ...
Setting up python3-rtslib-fb (2.1.73-1ubuntu4.1) ...
Created symlink /etc/systemd/system/multi-user.target.wants/rtslib-fb-targetctl.service → /lib/systemd/system/rtslib-fb-targetctl.service.
Processing triggers for man-db (2.9.3-2) ...
Processing triggers for systemd (246.6-1ubuntu1.3) ...
ubuntu at g-1916715-fixed:~$ systemctl status rtslib-fb-targetctl.service
● rtslib-fb-targetctl.service - Restore LIO kernel target configuration
     Loaded: loaded (/lib/systemd/system/rtslib-fb-targetctl.service; enabled; vendor preset: enabled)
     Active: active (exited) since Wed 2021-04-07 06:25:37 UTC; 4s ago
   Main PID: 1436 (code=exited, status=0/SUCCESS)
      Tasks: 0 (limit: 459)
     Memory: 0B
     CGroup: /system.slice/rtslib-fb-targetctl.service

Apr 07 06:25:37 g-1916715-fixed systemd[1]: Starting Restore LIO kernel target configuration...
Apr 07 06:25:37 g-1916715-fixed target[1436]: No saved config file at /etc/rtslib-fb-target/saveconfig.json, ok, exiting
Apr 07 06:25:37 g-1916715-fixed systemd[1]: Finished Restore LIO kernel target configuration.



All LGTM, setting verified tags

** Tags removed: verification-needed verification-needed-groovy
** Tags added: verification-done verification-done-groovy

-- 
You received this bug notification because you are a member of Ubuntu
OpenStack, which is subscribed to python-rtslib-fb in Ubuntu.
https://bugs.launchpad.net/bugs/1916715

Title:
  fails on install due to systemd-service/sysv-service mismatch and lack
  of mkdir

Status in python-rtslib-fb package in Ubuntu:
  Fix Released
Status in python-rtslib-fb source package in Groovy:
  Fix Committed

Bug description:
  [Impact]
  ========

  The python3-rtslib-fb package fails to install.

  On install:

  Setting up python3-rtslib-fb (2.1.74-0ubuntu1) ...
  Job for rtslib-fb-targetctl.service failed because the control process exited with error code.
  See "systemctl status rtslib-fb-targetctl.service" and "journalctl -xe" for details.
  invoke-rc.d: initscript rtslib-fb-targetctl, action "start" failed.
  ● rtslib-fb-targetctl.service - LSB: Start LIO targets
       Loaded: loaded (]8;;file://autopkgtest/etc/init.d/rtslib-fb-targetctl/etc/init.d/rtslib-fb-targetctl]8;;; generated)
       Active: failed (Result: exit-code) since Tue 2021-02-23 18:03:16 UTC; 10ms ago
         Docs: ]8;;man:systemd-sysv-generator(8)man:systemd-sysv-generator(8)]8;;
      Process: 3296 ExecStart=/etc/init.d/rtslib-fb-targetctl start (code=exited, status=1/FAILURE)

  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]:     errors = RTSRoot().restore_from_file(restore_file=from_file)
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 88, in __init__
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]:     self._set_dbroot()
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]:   File "/usr/lib/python3/dist-packages/rtslib_fb/root.py", line 182, in _set_dbroot
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]:     raise RTSLibError("Cannot set dbroot to {}. Please check if this directory exists."
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3308]: rtslib_fb.utils.RTSLibError: Cannot set dbroot to /etc/rtslib-fb-target. Please check if this directory exists.
  Feb 23 18:03:16 autopkgtest rtslib-fb-targetctl[3296]:    ...fail!
  Feb 23 18:03:16 autopkgtest systemd[1]: rtslib-fb-targetctl.service: Control process exited, code=exited, status=1/FAILURE
  Feb 23 18:03:16 autopkgtest systemd[1]: rtslib-fb-targetctl.service: Failed with result 'exit-code'.
  Feb 23 18:03:16 autopkgtest systemd[1]: Failed to start LSB: Start LIO targets.
  dpkg: error processing package python3-rtslib-fb (--configure):
   installed python3-rtslib-fb package post-installation script subprocess returned error exit status 1

  [Test Plan]
  ===========

  To reproduce this bug, simply do the following:

  $ lxc launch ubuntu-daily:groovy python-rtslib-fb-lp1916715-groovy

  $ lxc shell python-rtslib-fb-lp1916715-groovy

  [or shoot up a VM running Groovy]

  # apt update && apt upgrade && apt install linux-modules-
  extra-5.8.0-44-generic

  # reboot

  # apt install python3-rtslib-fb

  ...and this should fail to install.

  To make sure that this bug is indeed fixed, install the patched
  version of this package and that should install fine.

  Furthermore, check systemctl status rtslib-fb-targetctl.service and
  that should not report any problems.

  
  [Where problems could occur]
  ============================

  If someone has manually fixed the old service (manual mkdir, enable
  it, ...) or any such thing, then the fix might cause the update to
  behave a bit differently.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/python-rtslib-fb/+bug/1916715/+subscriptions



More information about the Ubuntu-openstack-bugs mailing list