[Openstack] nova-compute not starting

Razique Mahroua razique.mahroua at gmail.com
Thu Dec 13 14:51:45 UTC 2012


Why not hehe, though I must admit it's easier, yes you can have a simpler template :)
just copy a libvirt.xml and update the instance name.
You could even come up with a small bash script
./recover.sh $instance-name that would perform the following steps :

• Retrieve the instance name and put it into the <name></name> brackets
• Run "virsh define "
• Restart nova-compute

voila :)

Razique Mahroua - Nuage & Co
razique.mahroua at gmail.com
Tel : +33 9 72 37 94 15



Le 13 déc. 2012 à 15:32, Gui Maluf <guimalufb at gmail.com> a écrit :

> anytime this happend with me I do the following.
> 
> create a lost_instance.xml with the content below(I think it's possible to create a simpler file, with less content) just to register a VM with libvirt. Make sure to change the <name></name> tag. In your case
> 
> 
> <domain type='kvm'>
>   <name>instance-0000002a</name>
>   <memory unit='KiB'>4194304</memory>
>   <currentMemory unit='KiB'>4194304</currentMemory>
>   <vcpu placement='static'>4</vcpu>
>   <os>
>     <type arch='x86_64' machine='pc-1.0'>hvm</type>
>     <boot dev='hd'/>
>   </os>
>   <features>
>     <acpi/>
>     <apic/>
>     <pae/>
>   </features>
>   <clock offset='utc'/>
>   <on_poweroff>destroy</on_poweroff>
>   <on_reboot>restart</on_reboot>
>   <on_crash>restart</on_crash>
>   <devices>
>     <emulator>/usr/bin/kvm</emulator>
>     <controller type='ide' index='0'>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x1'/>
>     </controller>
>     <controller type='usb' index='0'>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x01' function='0x2'/>
>     </controller>
>     <serial type='pty'>
>       <target port='0'/>
>     </serial>
>     <console type='pty'>
>       <target type='serial' port='0'/>
>     </console>
>     <input type='mouse' bus='ps2'/>
>     <graphics type='vnc' port='-1' autoport='yes'/>
>     <video>
>       <model type='cirrus' vram='9216' heads='1'/>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
>     </video>
>     <memballoon model='virtio'>
>       <address type='pci' domain='0x0000' bus='0x00' slot='0x04' function='0x0'/>
>     </memballoon>
>   </devices>
> </domain>
> 
> 
> save and exit
> 
> and then
> # virsh define lost_instance.xml
> # service nova-compute restart
> 
> it's easier then mess with the database.
> 
> 
> 
> On Thu, Dec 13, 2012 at 8:56 AM, Razique Mahroua <razique.mahroua at gmail.com> wrote:
> I think the instance ID is the database ID (base 8) encoded in base 16.  0x2A = ID 52 into the database.
> Did you updated the ID 52 ?
> 
> I may be wrong ^^
> 
> Razique Mahroua - Nuage & Co
> razique.mahroua at gmail.com
> Tel : +33 9 72 37 94 15
> 
> <NUAGECO-LOGO-Fblan_petit.jpg>
> 
> Le 13 déc. 2012 à 11:51, Joe Warren-Meeks <joe.warren.meeks at gmail.com> a écrit :
> 
>> It turned out to be that last one. What I don't understand is where openstack found the instance id from. That doesn't exist in the database, or anywhere on the file system I could find.
>> 
>> Kind regards
>> 
>>  -- joe.
>> 
>> 
>> On 13 December 2012 10:27, Razique Mahroua <razique.mahroua at gmail.com> wrote:
>> Hey Joe, 
>> yes, several solutions there
>> First, check if the domain exists by running
>> $ virsh list --all (supposing you use libvirt)
>> 
>> check /var/lib/nova/instances/instance-0000002a
>> if the dir. exists $cd into it and run "virsh define libvirt.xml"
>> then restart nova-compute
>> 
>> If the dir. doesn't exist, you may want to update the nova database,  figure out your instance entry within the "instances" table and update the field "deleted" to 1
>> 
>> Regards,
>> Razique Mahroua - Nuage & Co
>> razique.mahroua at gmail.com
>> Tel : +33 9 72 37 94 15
>> 
>> <NUAGECO-LOGO-Fblan_petit.jpg>
>> 
>> Le 12 déc. 2012 à 17:07, Joe Warren-Meeks <joe.warren.meeks at gmail.com> a écrit :
>> 
>>> Hi guys,
>>> 
>>> You think you have Openstack working, then you cough and it all breaks.
>>> 
>>> I'm getting the following error when trying to start nova-compute after a reboot of the compute node (to install non-related patches)
>>> 
>>> libvirtError: Domain not found: no domain with matching name 'instance-0000002a'
>>> 
>>> Now, I've dumped all the DBs to disk and grepped through it for '00002a' and grep -R'ed /etc/ and /var/
>>> 
>>> I can't find any reference to that anywhere, but it is causing nova-compute to fail to start.
>>> 
>>> Anyone know how to fix that? If not, anyone know a cloud platform that isn't made from very thin glass, pre-shattered for your pleasure?
>>> 
>>>  -- joe.
>>> 
>>> _______________________________________________
>>> Mailing list: https://launchpad.net/~openstack
>>> Post to     : openstack at lists.launchpad.net
>>> Unsubscribe : https://launchpad.net/~openstack
>>> More help   : https://help.launchpad.net/ListHelp
>> 
>> 
> 
> 
> _______________________________________________
> Mailing list: https://launchpad.net/~openstack
> Post to     : openstack at lists.launchpad.net
> Unsubscribe : https://launchpad.net/~openstack
> More help   : https://help.launchpad.net/ListHelp
> 
> 
> 
> 
> -- 
> guilherme \n
> \t maluf
> 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20121213/364ac51e/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: NUAGECO-LOGO-Fblan_petit.jpg
Type: image/jpeg
Size: 10122 bytes
Desc: not available
URL: <http://lists.openstack.org/pipermail/openstack/attachments/20121213/364ac51e/attachment.jpg>


More information about the Openstack mailing list