Linux guest images on Hyper-V fail to access local storage when using resized differencing VHDX disks

Bug #1370531 reported by Alessandro Pilotti
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Lucian Petrut

Bug Description

Description of the issue

Create a differencing disk of a Linux image VHDX (any Linux distro with LIS), resizing it in the process (without resizing the base disk)
Create and boot a VM with the disk attached on the IDE controller

During boot the hv_storvsc module will start logging repeatedly the following message:

hv_storvsc vmbus_0_1: cmd 0x28 scsi status 0x2 srb status 0x4

(along with various I/O errors on sda1).

The machine manages to boot eventually after a long delay.

The following PowerShell script can be used to reproduce the issue:
http://paste.openstack.org/raw/110766/

Tested on: Hyper-V 2012 R2 and with various Linux guests.

Workaround:

Apply the same technique used for VHD disks, where a copy of the base image is resized before the differencing one is created.

Tags: hyper-v
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/122195

Changed in nova:
assignee: nobody → Petrut Lucian (petrutlucian94)
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/122195
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=1f26df24a63624545cfe67745af53623947a6d28
Submitter: Jenkins
Branch: master

commit 1f26df24a63624545cfe67745af53623947a6d28
Author: Lucian Petrut <email address hidden>
Date: Thu Sep 18 11:55:56 2014 +0300

    Fixes differencing VHDX images issue on Hyper-V

    When using differencing vhdx images, one will be created pointing
    to the base image when a VM is spawned. This image will be created
    having the according flavor size.

    In this case, due to a Win32 API issue, the image is not generated
    properly.

    Simply creating the root image with no size specified and resizing
    it afterwards fixes the issue.

    Change-Id: I7bb46a63d4c2a06ed6f63c839461cbbc1abffa65
    Closes-Bug: #1370531

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → kilo-1
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: kilo-1 → 2015.1.0
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.