yahoo-eng-team team mailing list archive
-
yahoo-eng-team team
-
Mailing list archive
-
Message #53003
[Bug 1597669] [NEW] [libvirt] disk.config.rescue is not used when rescuing an instance
Public bug reported:
Description
===========
I931421ea688641e2ceb212c6dc099639c53433f2 introduced a callback to
_create_configdrive from _create_domain that recreates the config disk
of an instance during a rescue.
However neither the original or this recreated config disk are used by
the instance during the resulting rescue.
Steps to reproduce
==================
$ nova boot --image cirros-0.3.4-x86_64-uec --flavor 1 test-config-rescue
[..]
$ nova rescue test-config-rescue
[..]
$ nova list
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| ID | Name | Status | Task State | Power State | Networks |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| 5ef76bd4-4e4f-46dd-88f6-dcd212e54802 | test-config-rescue | RESCUE | - | Running | private=10.0.0.2 |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
$ ll ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/
total 28556
-rw-------. 1 qemu qemu 16939 Jun 30 04:39 console.log
-rw-r--r--. 1 qemu qemu 10682368 Jun 30 04:39 disk
-rw-rw-r--. 1 qemu qemu 432128 Jun 30 04:38 disk.config
-rw-rw-r--. 1 stack libvirtd 432128 Jun 30 04:39 disk.config.rescue
-rw-r--r--. 1 stack libvirtd 534 Jun 30 04:39 disk.info
-rw-r--r--. 1 qemu qemu 197120 Jun 30 04:39 disk.rescue
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:38 kernel
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:39 kernel.rescue
-rw-rw-r--. 1 stack libvirtd 3146 Jun 30 04:39 libvirt.xml
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:38 ramdisk
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:39 ramdisk.rescue
-rw-rw-r--. 1 stack libvirtd 4569 Jun 30 04:39 unrescue.xml
$ grep config ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/libvirt.xml
<nova:name>test-config-rescue</nova:name>
$ sudo virsh domblklist 5ef76bd4-4e4f-46dd-88f6-dcd212e54802
Target Source
------------------------------------------------
vda /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.rescue
vdb /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk
$ nova unrescue test-config-rescue
$ nova list
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| ID | Name | Status | Task State | Power State | Networks |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| 5ef76bd4-4e4f-46dd-88f6-dcd212e54802 | test-config-rescue | ACTIVE | - | Running | private=10.0.0.2 |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
$ ll ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/
total 19604
-rw-------. 1 qemu qemu 20403 Jun 30 04:48 console.log
-rw-r--r--. 1 qemu qemu 10878976 Jun 30 04:47 disk
-rw-rw-r--. 1 qemu qemu 432128 Jun 30 04:38 disk.config
-rw-r--r--. 1 stack libvirtd 534 Jun 30 04:39 disk.info
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:38 kernel
-rw-rw-r--. 1 stack libvirtd 4569 Jun 30 04:47 libvirt.xml
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:38 ramdisk
$ grep config ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/libvirt.xml
<nova:name>test-config-rescue</nova:name>
<source file='/opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.config'/>
$ sudo virsh domblklist 5ef76bd4-4e4f-46dd-88f6-dcd212e54802
Target Source
------------------------------------------------
vda /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk
hdd /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.config
Expected result
===============
disk.config.rescue attached to the rescued instance.
Actual result
=============
No config disks are attached to the rescued instance. Only the rescue disk and original root disk are attached.
Environment
===========
1. Exact version of OpenStack you are running. See the following
list for all releases: http://docs.openstack.org/releases/
$ pwd
/opt/stack/nova
$ git rev-parse HEAD
23153952a979c93a414705744b0f8ba4bde18f75
2. Which hypervisor did you use?
libvirt + kvm
2. Which storage type did you use?
(For example: Ceph, LVM, GPFS, ...)
What's the version of that?
N/A
3. Which networking type did you use?
(For example: nova-network, Neutron with OpenVSwitch, ...)
N/A
Logs & Configs
==============
** Affects: nova
Importance: Undecided
Status: New
--
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Compute (nova).
https://bugs.launchpad.net/bugs/1597669
Title:
[libvirt] disk.config.rescue is not used when rescuing an instance
Status in OpenStack Compute (nova):
New
Bug description:
Description
===========
I931421ea688641e2ceb212c6dc099639c53433f2 introduced a callback to
_create_configdrive from _create_domain that recreates the config disk
of an instance during a rescue.
However neither the original or this recreated config disk are used by
the instance during the resulting rescue.
Steps to reproduce
==================
$ nova boot --image cirros-0.3.4-x86_64-uec --flavor 1 test-config-rescue
[..]
$ nova rescue test-config-rescue
[..]
$ nova list
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| ID | Name | Status | Task State | Power State | Networks |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| 5ef76bd4-4e4f-46dd-88f6-dcd212e54802 | test-config-rescue | RESCUE | - | Running | private=10.0.0.2 |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
$ ll ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/
total 28556
-rw-------. 1 qemu qemu 16939 Jun 30 04:39 console.log
-rw-r--r--. 1 qemu qemu 10682368 Jun 30 04:39 disk
-rw-rw-r--. 1 qemu qemu 432128 Jun 30 04:38 disk.config
-rw-rw-r--. 1 stack libvirtd 432128 Jun 30 04:39 disk.config.rescue
-rw-r--r--. 1 stack libvirtd 534 Jun 30 04:39 disk.info
-rw-r--r--. 1 qemu qemu 197120 Jun 30 04:39 disk.rescue
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:38 kernel
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:39 kernel.rescue
-rw-rw-r--. 1 stack libvirtd 3146 Jun 30 04:39 libvirt.xml
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:38 ramdisk
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:39 ramdisk.rescue
-rw-rw-r--. 1 stack libvirtd 4569 Jun 30 04:39 unrescue.xml
$ grep config ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/libvirt.xml
<nova:name>test-config-rescue</nova:name>
$ sudo virsh domblklist 5ef76bd4-4e4f-46dd-88f6-dcd212e54802
Target Source
------------------------------------------------
vda /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.rescue
vdb /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk
$ nova unrescue test-config-rescue
$ nova list
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| ID | Name | Status | Task State | Power State | Networks |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
| 5ef76bd4-4e4f-46dd-88f6-dcd212e54802 | test-config-rescue | ACTIVE | - | Running | private=10.0.0.2 |
+--------------------------------------+--------------------+--------+------------+-------------+------------------+
$ ll ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/
total 19604
-rw-------. 1 qemu qemu 20403 Jun 30 04:48 console.log
-rw-r--r--. 1 qemu qemu 10878976 Jun 30 04:47 disk
-rw-rw-r--. 1 qemu qemu 432128 Jun 30 04:38 disk.config
-rw-r--r--. 1 stack libvirtd 534 Jun 30 04:39 disk.info
-rw-rw-r--. 1 qemu qemu 4979632 Jun 30 04:38 kernel
-rw-rw-r--. 1 stack libvirtd 4569 Jun 30 04:47 libvirt.xml
-rw-rw-r--. 1 qemu qemu 3740163 Jun 30 04:38 ramdisk
$ grep config ../data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/libvirt.xml
<nova:name>test-config-rescue</nova:name>
<source file='/opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.config'/>
$ sudo virsh domblklist 5ef76bd4-4e4f-46dd-88f6-dcd212e54802
Target Source
------------------------------------------------
vda /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk
hdd /opt/stack/data/nova/instances/5ef76bd4-4e4f-46dd-88f6-dcd212e54802/disk.config
Expected result
===============
disk.config.rescue attached to the rescued instance.
Actual result
=============
No config disks are attached to the rescued instance. Only the rescue disk and original root disk are attached.
Environment
===========
1. Exact version of OpenStack you are running. See the following
list for all releases: http://docs.openstack.org/releases/
$ pwd
/opt/stack/nova
$ git rev-parse HEAD
23153952a979c93a414705744b0f8ba4bde18f75
2. Which hypervisor did you use?
libvirt + kvm
2. Which storage type did you use?
(For example: Ceph, LVM, GPFS, ...)
What's the version of that?
N/A
3. Which networking type did you use?
(For example: nova-network, Neutron with OpenVSwitch, ...)
N/A
Logs & Configs
==============
To manage notifications about this bug go to:
https://bugs.launchpad.net/nova/+bug/1597669/+subscriptions
Follow ups