yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #87373
[Bug 1946457] [NEW] Functional test fails with a: "Unknown file format 'qcow'" error on Centos8
Public bug reported:
This issue was discovered on tests with FIPS enabled[1], but without FIPS the same issue happens.
When running glance functional tests on a Centos8 server, the following issue happens:
{1} glance.tests.functional.v2.test_images.TestImages.test_image_upload_qcow_virtual_size_calculation [5.522514s] ... FAILED
Captured traceback:
~~~~~~~~~~~~~~~~~~~
Traceback (most recent call last):
File "/home/zuul/src/opendev.org/openstack/glance/glance/tests/functional/v2/test_images.py", line 931, in test_image_upload_qcow_virtual_size_calculation
fn = self._create_qcow(128 * units.Mi)
File "/home/zuul/src/opendev.org/openstack/glance/glance/tests/functional/v2/test_images.py", line 914, in _create_qcow
shell=True)
File "/usr/lib64/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/usr/lib64/python3.6/subprocess.py", line 438, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command 'qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728' returned non-zero exit status 127.
~~~
Trying to run this command manually on a Centos8 server with qemu-img installed (qemu-img-15:4.2.0-48): qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
Initially it fails due to a gcrypt issue:
~~~
$ qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
qemu-img: Unable to initialize gcrypt
~~~
There is a bug for this that[2] and the solution is to update the libgcrypt package. Previously I had 'libgcrypt-1.8.3-4' and updated to: 'libgcrypt-1.8.5-4'.
After this, I got the "Unknown file format 'qcow'" error:
~~~
$ qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
qemu-img: /tmp/glance-unittest-images-5flalm7e.qcow: Unknown file format 'qcow'
$ qemu-img create -f qcow2 /tmp/glance-unittest-images-5flalm7e.qcow 134217728
Formatting '/tmp/glance-unittest-images-5flalm7e.qcow', fmt=qcow2 size=134217728 cluster_size=65536 lazy_refcounts=off refcount_bits=16
~~~
Looking at our documentation I believe we don't support qcow format anymore[3], so should we still keep this test? Or maybe, change it to use qcow2 instead of qcow?
I believe that the reason we didn't see this issue on the CI's, is because they are testing on a Ubuntu server (At least for the patch I analysed).
[1]
https://zuul.opendev.org/t/openstack/build/4f3a50281bc44ada9fb68ac24236cf1c/console
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1828681
[3] https://docs.openstack.org/glance/train/user/formats.html#disk-
format
** Affects: glance
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to Glance.
https://bugs.launchpad.net/bugs/1946457
Title:
Functional test fails with a: "Unknown file format 'qcow'" error on
Centos8
Status in Glance:
New
Bug description:
This issue was discovered on tests with FIPS enabled[1], but without FIPS the same issue happens.
When running glance functional tests on a Centos8 server, the following issue happens:
{1} glance.tests.functional.v2.test_images.TestImages.test_image_upload_qcow_virtual_size_calculation [5.522514s] ... FAILED
Captured traceback:
~~~~~~~~~~~~~~~~~~~
Traceback (most recent call last):
File "/home/zuul/src/opendev.org/openstack/glance/glance/tests/functional/v2/test_images.py", line 931, in test_image_upload_qcow_virtual_size_calculation
fn = self._create_qcow(128 * units.Mi)
File "/home/zuul/src/opendev.org/openstack/glance/glance/tests/functional/v2/test_images.py", line 914, in _create_qcow
shell=True)
File "/usr/lib64/python3.6/subprocess.py", line 356, in check_output
**kwargs).stdout
File "/usr/lib64/python3.6/subprocess.py", line 438, in run
output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command 'qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728' returned non-zero exit status 127.
~~~
Trying to run this command manually on a Centos8 server with qemu-img installed (qemu-img-15:4.2.0-48): qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
Initially it fails due to a gcrypt issue:
~~~
$ qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
qemu-img: Unable to initialize gcrypt
~~~
There is a bug for this that[2] and the solution is to update the libgcrypt package. Previously I had 'libgcrypt-1.8.3-4' and updated to: 'libgcrypt-1.8.5-4'.
After this, I got the "Unknown file format 'qcow'" error:
~~~
$ qemu-img create -f qcow /tmp/glance-unittest-images-5flalm7e.qcow 134217728
qemu-img: /tmp/glance-unittest-images-5flalm7e.qcow: Unknown file format 'qcow'
$ qemu-img create -f qcow2 /tmp/glance-unittest-images-5flalm7e.qcow 134217728
Formatting '/tmp/glance-unittest-images-5flalm7e.qcow', fmt=qcow2 size=134217728 cluster_size=65536 lazy_refcounts=off refcount_bits=16
~~~
Looking at our documentation I believe we don't support qcow format anymore[3], so should we still keep this test? Or maybe, change it to use qcow2 instead of qcow?
I believe that the reason we didn't see this issue on the CI's, is because they are testing on a Ubuntu server (At least for the patch I analysed).
[1]
https://zuul.opendev.org/t/openstack/build/4f3a50281bc44ada9fb68ac24236cf1c/console
[2] https://bugzilla.redhat.com/show_bug.cgi?id=1828681
[3] https://docs.openstack.org/glance/train/user/formats.html#disk-
format
To manage notifications about this bug go to:
https://bugs.launchpad.net/glance/+bug/1946457/+subscriptions
Follow ups