Activity log for bug #1490611

Date Who What changed Old value New value Message
2015-08-31 15:29:00 Stephen Kent bug added bug
2015-08-31 22:56:07 willmo bug added subscriber willmo
2015-09-02 19:46:49 Stephen A. Zarkos bug added subscriber Stephen A. Zarkos
2016-01-13 06:41:05 Jan qemu: status New Fix Released
2016-02-16 00:28:33 Cole Mickens bug added subscriber Kevin Wolf
2016-02-16 00:53:19 Cole Mickens bug added subscriber Cole Mickens
2016-02-16 09:07:39 Kevin Wolf bug added subscriber Jeff Cody
2016-02-16 09:08:40 Kevin Wolf bug added subscriber Max Reitz
2016-06-28 15:52:28 Serge Hallyn bug task added qemu (Ubuntu)
2016-06-28 15:57:17 Launchpad Janitor qemu (Ubuntu): status New Confirmed
2016-06-28 15:57:35 Serge Hallyn nominated for series Ubuntu Xenial
2016-06-28 15:57:35 Serge Hallyn bug task added qemu (Ubuntu Xenial)
2016-07-01 14:02:27 Jon Grimm bug added subscriber Ubuntu Server Team
2016-07-01 14:02:34 Jon Grimm bug added subscriber Jon Grimm
2016-07-14 18:02:57 Nish Aravamudan qemu (Ubuntu): status Confirmed Fix Released
2016-07-14 18:03:43 Nish Aravamudan qemu (Ubuntu Xenial): assignee Nish Aravamudan (nacc)
2016-07-14 18:33:15 Nish Aravamudan attachment added attachment https://bugs.launchpad.net/bugs/1490611/+attachment/4700967/+files/attachment
2016-07-15 22:20:55 Nish Aravamudan qemu (Ubuntu Xenial): status New In Progress
2016-08-02 19:41:57 Nish Aravamudan bug added subscriber Ubuntu Sponsors Team
2016-08-02 20:17:55 Nish Aravamudan description Starting with a raw disk image, using "qemu-img convert" to convert from raw to VHD results in the output VHD file's virtual size being aligned to the nearest 516096 bytes (16 heads x 63 sectors per head x 512 bytes per sector), instead of preserving the input file's size as the output VHD's virtual disk size. Microsoft Azure requires that disk images (VHDs) submitted for upload have virtual sizes aligned to a megabyte boundary. (Ex. 4096MB, 4097MB, 4098MB, etc. are OK, 4096.5MB is rejected with an error.) This is reflected in Microsoft's documentation: https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-linux-create-upload-vhd-generic/ This is reproducible with the following set of commands (including the Azure command line tools from https://github.com/Azure/azure-xplat-cli). For the following example, I used qemu version 2.2.1: $ dd if=/dev/zero of=source-disk.img bs=1M count=4096 $ stat source-disk.img File: ‘source-disk.img’ Size: 4294967296 Blocks: 798656 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247963 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:48:02.613988480 -0700 Modify: 2015-08-18 09:48:02.825985646 -0700 Change: 2015-08-18 09:48:02.825985646 -0700 Birth: - $ qemu-img convert -f raw -o subformat=fixed -O vpc source-disk.img dest-disk.vhd $ stat dest-disk.vhd File: ‘dest-disk.vhd’ Size: 4296499712 Blocks: 535216 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247964 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:50:22.252077624 -0700 Modify: 2015-08-18 09:49:24.424868868 -0700 Change: 2015-08-18 09:49:24.424868868 -0700 Birth: - $ azure vm image create testimage1 dest-disk.vhd -o linux -l "West US" info: Executing command vm image create + Retrieving storage accounts info: VHD size : 4097 MB info: Uploading 4195800.5 KB Requested:100.0% Completed:100.0% Running: 0 Time: 1m 0s Speed: 6744 KB/s info: https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd was uploaded successfully error: The VHD https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd has an unsupported virtual size of 4296499200 bytes. The size must be a whole number (in MBs). info: Error information has been recorded to /home/smkent/.azure/azure.err error: vm image create command failed I also ran the above commands using qemu 2.4.0, which resulted in the same error as the conversion behavior is the same. However, qemu 2.1.1 and earlier (including qemu 2.0.0 installed by Ubuntu 14.04) does not pad the virtual disk size during conversion. Using qemu-img convert from qemu versions <=2.1.1 results in a VHD that is exactly the size of the raw input file plus 512 bytes (for the VHD footer). Those qemu versions do not attempt to realign the disk. As a result, Azure accepts VHD files created using those versions of qemu-img convert for upload. Is there a reason why newer qemu realigns the converted VHD file? It would be useful if an option were added to disable this feature, as current versions of qemu cannot be used to create VHD files for Azure using Microsoft's official instructions. [Impact] * Starting with a raw disk image, using "qemu-img convert" to convert from raw to VHD results in the output VHD file's virtual size being aligned to the nearest 516096 bytes (16 heads x 63 sectors per head x 512 bytes per sector), instead of preserving the input file's size as the output VHD's virtual disk size. * Microsoft Azure requires that disk images (VHDs) submitted for upload have virtual sizes aligned to a megabyte boundary. (Ex. 4096MB, 4097MB, 4098MB, etc. are OK, 4096.5MB is rejected with an error.) This is reflected in Microsoft's documentation: https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-linux-create-upload-vhd-generic/ * The fix for this bug is a backport from upstream. http://git.qemu.org/?p=qemu.git;a=commitdiff;h=fb9245c2610932d33ce14 [Test Case] * This is reproducible with the following set of commands (including the Azure command line tools from https://github.com/Azure/azure-xplat-cli). For the following example, I used qemu version 2.2.1: $ dd if=/dev/zero of=source-disk.img bs=1M count=4096 $ stat source-disk.img   File: ‘source-disk.img’   Size: 4294967296 Blocks: 798656 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247963 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:48:02.613988480 -0700 Modify: 2015-08-18 09:48:02.825985646 -0700 Change: 2015-08-18 09:48:02.825985646 -0700  Birth: - $ qemu-img convert -f raw -o subformat=fixed -O vpc source-disk.img dest-disk.vhd $ stat dest-disk.vhd   File: ‘dest-disk.vhd’   Size: 4296499712 Blocks: 535216 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247964 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:50:22.252077624 -0700 Modify: 2015-08-18 09:49:24.424868868 -0700 Change: 2015-08-18 09:49:24.424868868 -0700  Birth: - $ azure vm image create testimage1 dest-disk.vhd -o linux -l "West US" info: Executing command vm image create + Retrieving storage accounts info: VHD size : 4097 MB info: Uploading 4195800.5 KB Requested:100.0% Completed:100.0% Running: 0 Time: 1m 0s Speed: 6744 KB/s info: https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd was uploaded successfully error: The VHD https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd has an unsupported virtual size of 4296499200 bytes. The size must be a whole number (in MBs). info: Error information has been recorded to /home/smkent/.azure/azure.err error: vm image create command failed * A fixed qemu-img will not result in an error during azure image creation. [Regression Potential] * The upstream fix introduces a qemu-img option (-o force_size) which is unset by default. The regression potential is very low, as a result. ... I also ran the above commands using qemu 2.4.0, which resulted in the same error as the conversion behavior is the same. However, qemu 2.1.1 and earlier (including qemu 2.0.0 installed by Ubuntu 14.04) does not pad the virtual disk size during conversion. Using qemu-img convert from qemu versions <=2.1.1 results in a VHD that is exactly the size of the raw input file plus 512 bytes (for the VHD footer). Those qemu versions do not attempt to realign the disk. As a result, Azure accepts VHD files created using those versions of qemu-img convert for upload. Is there a reason why newer qemu realigns the converted VHD file? It would be useful if an option were added to disable this feature, as current versions of qemu cannot be used to create VHD files for Azure using Microsoft's official instructions.
2016-08-03 10:43:06 Simon Déziel bug added subscriber Simon Déziel
2016-08-04 04:33:03 Mathew Hodson qemu (Ubuntu): importance Undecided Medium
2016-08-04 04:33:05 Mathew Hodson qemu (Ubuntu Xenial): importance Undecided Medium
2016-08-04 10:27:19 Robie Basak removed subscriber Ubuntu Sponsors Team
2016-08-04 15:21:12 Nish Aravamudan description [Impact] * Starting with a raw disk image, using "qemu-img convert" to convert from raw to VHD results in the output VHD file's virtual size being aligned to the nearest 516096 bytes (16 heads x 63 sectors per head x 512 bytes per sector), instead of preserving the input file's size as the output VHD's virtual disk size. * Microsoft Azure requires that disk images (VHDs) submitted for upload have virtual sizes aligned to a megabyte boundary. (Ex. 4096MB, 4097MB, 4098MB, etc. are OK, 4096.5MB is rejected with an error.) This is reflected in Microsoft's documentation: https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-linux-create-upload-vhd-generic/ * The fix for this bug is a backport from upstream. http://git.qemu.org/?p=qemu.git;a=commitdiff;h=fb9245c2610932d33ce14 [Test Case] * This is reproducible with the following set of commands (including the Azure command line tools from https://github.com/Azure/azure-xplat-cli). For the following example, I used qemu version 2.2.1: $ dd if=/dev/zero of=source-disk.img bs=1M count=4096 $ stat source-disk.img   File: ‘source-disk.img’   Size: 4294967296 Blocks: 798656 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247963 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:48:02.613988480 -0700 Modify: 2015-08-18 09:48:02.825985646 -0700 Change: 2015-08-18 09:48:02.825985646 -0700  Birth: - $ qemu-img convert -f raw -o subformat=fixed -O vpc source-disk.img dest-disk.vhd $ stat dest-disk.vhd   File: ‘dest-disk.vhd’   Size: 4296499712 Blocks: 535216 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247964 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:50:22.252077624 -0700 Modify: 2015-08-18 09:49:24.424868868 -0700 Change: 2015-08-18 09:49:24.424868868 -0700  Birth: - $ azure vm image create testimage1 dest-disk.vhd -o linux -l "West US" info: Executing command vm image create + Retrieving storage accounts info: VHD size : 4097 MB info: Uploading 4195800.5 KB Requested:100.0% Completed:100.0% Running: 0 Time: 1m 0s Speed: 6744 KB/s info: https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd was uploaded successfully error: The VHD https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd has an unsupported virtual size of 4296499200 bytes. The size must be a whole number (in MBs). info: Error information has been recorded to /home/smkent/.azure/azure.err error: vm image create command failed * A fixed qemu-img will not result in an error during azure image creation. [Regression Potential] * The upstream fix introduces a qemu-img option (-o force_size) which is unset by default. The regression potential is very low, as a result. ... I also ran the above commands using qemu 2.4.0, which resulted in the same error as the conversion behavior is the same. However, qemu 2.1.1 and earlier (including qemu 2.0.0 installed by Ubuntu 14.04) does not pad the virtual disk size during conversion. Using qemu-img convert from qemu versions <=2.1.1 results in a VHD that is exactly the size of the raw input file plus 512 bytes (for the VHD footer). Those qemu versions do not attempt to realign the disk. As a result, Azure accepts VHD files created using those versions of qemu-img convert for upload. Is there a reason why newer qemu realigns the converted VHD file? It would be useful if an option were added to disable this feature, as current versions of qemu cannot be used to create VHD files for Azure using Microsoft's official instructions. [Impact]  * Starting with a raw disk image, using "qemu-img convert" to convert from raw to VHD results in the output VHD file's virtual size being aligned to the nearest 516096 bytes (16 heads x 63 sectors per head x 512 bytes per sector), instead of preserving the input file's size as the output VHD's virtual disk size.  * Microsoft Azure requires that disk images (VHDs) submitted for upload have virtual sizes aligned to a megabyte boundary. (Ex. 4096MB, 4097MB, 4098MB, etc. are OK, 4096.5MB is rejected with an error.) This is reflected in Microsoft's documentation: https://azure.microsoft.com/en-us/documentation/articles/virtual-machines-linux-create-upload-vhd-generic/  * The fix for this bug is a backport from upstream. http://git.qemu.org/?p=qemu.git;a=commitdiff;h=fb9245c2610932d33ce14 [Test Case]  * This is reproducible with the following set of commands (including the Azure command line tools from https://github.com/Azure/azure-xplat-cli). For the following example, I used qemu version 2.2.1: $ dd if=/dev/zero of=source-disk.img bs=1M count=4096 $ stat source-disk.img   File: ‘source-disk.img’   Size: 4294967296 Blocks: 798656 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247963 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:48:02.613988480 -0700 Modify: 2015-08-18 09:48:02.825985646 -0700 Change: 2015-08-18 09:48:02.825985646 -0700  Birth: - $ qemu-img convert -f raw -o subformat=fixed -O vpc source-disk.img dest-disk.vhd $ stat dest-disk.vhd   File: ‘dest-disk.vhd’   Size: 4296499712 Blocks: 535216 IO Block: 4096 regular file Device: fc01h/64513d Inode: 13247964 Links: 1 Access: (0644/-rw-r--r--) Uid: ( 1000/ smkent) Gid: ( 1000/ smkent) Access: 2015-08-18 09:50:22.252077624 -0700 Modify: 2015-08-18 09:49:24.424868868 -0700 Change: 2015-08-18 09:49:24.424868868 -0700  Birth: - $ azure vm image create testimage1 dest-disk.vhd -o linux -l "West US" info: Executing command vm image create + Retrieving storage accounts info: VHD size : 4097 MB info: Uploading 4195800.5 KB Requested:100.0% Completed:100.0% Running: 0 Time: 1m 0s Speed: 6744 KB/s info: https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd was uploaded successfully error: The VHD https://[redacted].blob.core.windows.net/vm-images/dest-disk.vhd has an unsupported virtual size of 4296499200 bytes. The size must be a whole number (in MBs). info: Error information has been recorded to /home/smkent/.azure/azure.err error: vm image create command failed  * A fixed qemu-img will not result in an error during azure image creation. It will require passing -o force_size, which will leverage the backported functionality. [Regression Potential]  * The upstream fix introduces a qemu-img option (-o force_size) which is unset by default. The regression potential is very low, as a result. ... I also ran the above commands using qemu 2.4.0, which resulted in the same error as the conversion behavior is the same. However, qemu 2.1.1 and earlier (including qemu 2.0.0 installed by Ubuntu 14.04) does not pad the virtual disk size during conversion. Using qemu-img convert from qemu versions <=2.1.1 results in a VHD that is exactly the size of the raw input file plus 512 bytes (for the VHD footer). Those qemu versions do not attempt to realign the disk. As a result, Azure accepts VHD files created using those versions of qemu-img convert for upload. Is there a reason why newer qemu realigns the converted VHD file? It would be useful if an option were added to disable this feature, as current versions of qemu cannot be used to create VHD files for Azure using Microsoft's official instructions.
2016-08-04 21:15:20 Robie Basak qemu (Ubuntu Xenial): status In Progress Triaged
2016-08-04 21:21:33 Nish Aravamudan attachment added attachment https://bugs.launchpad.net/bugs/1490611/+attachment/4714298/+files/attachment
2016-08-05 09:02:31 Robie Basak qemu (Ubuntu Xenial): status Triaged In Progress
2016-08-19 22:44:05 Nish Aravamudan attachment added attachment https://bugs.launchpad.net/bugs/1490611/+attachment/4724312/+files/attachment
2016-08-24 23:36:27 Nish Aravamudan qemu (Ubuntu Xenial): assignee Nish Aravamudan (nacc)
2016-08-24 23:36:51 Nish Aravamudan qemu (Ubuntu Xenial): assignee Nish Aravamudan (nacc)
2017-02-17 22:26:47 Nish Aravamudan qemu (Ubuntu Xenial): assignee Nish Aravamudan (nacc)
2017-02-17 22:27:08 Nish Aravamudan qemu (Ubuntu Xenial): assignee ChristianEhrhardt (paelzer)
2017-03-06 15:51:25 Christian Ehrhardt  qemu (Ubuntu Xenial): status In Progress Fix Committed
2017-03-08 06:56:45 Christian Ehrhardt  bug added subscriber ChristianEhrhardt
2017-03-23 20:34:01 Brian Murray bug added subscriber Ubuntu Stable Release Updates Team
2017-03-23 20:34:04 Brian Murray bug added subscriber SRU Verification
2017-03-23 20:34:12 Brian Murray tags verification-needed
2017-03-24 07:30:12 Christian Ehrhardt  tags verification-needed verification-done
2017-03-31 05:01:01 Steve Langasek qemu (Ubuntu Xenial): importance Medium Wishlist
2017-03-31 05:02:56 Launchpad Janitor qemu (Ubuntu Xenial): status Fix Committed Fix Released
2017-03-31 05:03:03 Steve Langasek removed subscriber Ubuntu Stable Release Updates Team
2017-11-20 01:26:05 James Thomas Moon bug added subscriber James Thomas Moon