[SRU] Package fails to build with missing 'systemctl'

Bug #1903724 reported by Chris MacNaughton
14
This bug affects 2 people
Affects Status Importance Assigned to Milestone
nova (Ubuntu)
Fix Released
Undecided
Unassigned
Focal
Fix Released
Undecided
Unassigned

Bug Description

[Impact]

Artful (OpenStack Train) through Focal (OpenStack Ussuri), the Nova package now fails to build with unit tests failing because they're missing the `systemctl` binary. An example traceback from the tests is included in the Other Info at the end.

This affects the ability to backport fixes or upstream point releases to the Nova package in Ubuntu.

[Test Case]

Reproducing this error is doable by building the package:

git clone lp:~ubuntu-openstack-dev/ubuntu/+source/nova
cd nova
git checkout stable/ussuri
gbp buildpackage -S -sa
pbuilder-dist focal build ../build-area/nova_*dsc

[Where problems could occur]

This upload doesn't change anything in the deployed software, merely in the build environment. With that caveat, building on an environment that cannot install systemctl could continue to leave this package unbuildable.

[Other Info]

Below is an example of one of the unit test failures that is resolved by adding systemctl as a build dependency.

nova.tests.unit.virt.libvirt.volume.test_quobyte.LibvirtQuobyteVolumeDriverTestCase.test_libvirt_quobyte_driver_already_mounted
-------------------------------------------------------------------------------------------------------------------------------
Captured traceback:
~~~~~~~~~~~~~~~~~~~
    Traceback (most recent call last):
      File "/usr/lib/python3/dist-packages/mock/mock.py", line 1330, in patched
    return func(*args, **keywargs)
      File "/build/nova-21.1.0/nova/tests/unit/virt/libvirt/volume/test_quobyte.py", line 419, in test_libvirt_quobyte_driver_already_mounted
    libvirt_driver.connect_volume(connection_info, mock.sentinel.instance)
      File "/usr/lib/python3/dist-packages/oslo_concurrency/lockutils.py", line 359, in inner
    return f(*args, **kwargs)
      File "/build/nova-21.1.0/nova/virt/libvirt/volume/quobyte.py", line 161, in connect_volume
    if is_systemd():
      File "/build/nova-21.1.0/nova/virt/libvirt/volume/quobyte.py", line 60, in is_systemd
    sysdout, sysderr = processutils.execute("systemctl",
      File "/usr/lib/python3/dist-packages/oslo_concurrency/processutils.py", line 383, in execute
    obj = subprocess.Popen(cmd,
      File "/usr/lib/python3/dist-packages/eventlet/green/subprocess.py", line 58, in __init__
    subprocess_orig.Popen.__init__(self, args, 0, *argss, **kwds)
      File "/usr/lib/python3.8/subprocess.py", line 854, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
      File "/usr/lib/python3.8/subprocess.py", line 1702, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
    FileNotFoundError: [Errno 2] No such file or directory: 'systemctl'

Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

Building this on versions prior to the stable/train or after the stable/ussuri version works so just targeting those two branches.

Changed in nova (Ubuntu):
status: New → Invalid
Changed in cloud-archive:
status: New → Invalid
Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

I was mistaken before, the Cloud Archive patches in the systemd dependency later so this just affects focal

no longer affects: cloud-archive
no longer affects: cloud-archive/train
Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Chris, or anyone else affected,

Accepted nova into focal-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/nova/2:21.1.0-0ubuntu2 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation on how to enable and use -proposed. Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, what testing has been performed on the package and change the tag from verification-needed-focal to verification-done-focal. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-focal. In either case, without details of your testing we will not be able to proceed.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance for helping!

N.B. The updated package will be released to -updates after the bug(s) fixed by this package have been verified and the package has been in -proposed for a minimum of 7 days.

Changed in nova (Ubuntu Focal):
status: New → Fix Committed
tags: added: verification-needed verification-needed-focal
Mathew Hodson (mhodson)
Changed in nova (Ubuntu):
status: Invalid → Fix Released
Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

As evidenced by the build log in the acceptance log, the Nova package builds successfully after this change in Focal.

tags: added: verification-done verification-done-focal
removed: verification-needed verification-needed-focal
Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

I think this upload will be superceded by an upstream point release that is being handled now.

Revision history for this message
Łukasz Zemczak (sil2100) wrote :

I see a new nova upstream release in the SRU queue. Seeing that LP: #1893263 is still not verified, should I accept the new upstream release and overwrite the existing SRU that's in progress?

Revision history for this message
Chris MacNaughton (chris.macnaughton) wrote :

Łukasz, I would appreciate that!

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package nova - 2:21.1.1-0ubuntu2

---------------
nova (2:21.1.1-0ubuntu2) focal; urgency=medium

  * d/p/lp1892361.patch: Update pci stat pools based on PCI device changes (LP: #1892361).

 -- Chris MacNaughton <email address hidden> Mon, 18 Jan 2021 15:25:16 +0000

Changed in nova (Ubuntu Focal):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.