[Users] I accidentally the whole database. Or: Can I re-import a running vm into the engine-db?

Omer Frenkel ofrenkel at redhat.com
Tue Jun 4 03:30:42 EDT 2013



----- Original Message -----
> From: "Sven Lankes" <sven at lank.es>
> To: users at ovirt.org
> Sent: Tuesday, June 4, 2013 10:08:14 AM
> Subject: [Users] I accidentally the whole database. Or: Can I re-import a running vm into the engine-db?
> 
> Hi,
> 
> I have a ovirt "cluster" with one manamgement node and a single
> virtualization node.
> 
> After fiddling with the database manually, I had to restore a database
> backup. The database backup was from a time when the host hat 7 virtual
> machines - it now has 9.
> 
> So there are now two machines "missing" from the web-interface. They're
> still running on the node itself but ovirt-engine keeps logging:
> 
> [org.ovirt.engine.core.vdsbroker.VdsUpdateRunTimeInfo]
> (DefaultQuartzScheduler_Worker-8) VDS::UpdateVmRunTimeInfo Error: found VM
> on a VDS that is not in the database!
> 
> Is there a way to "re-import" the machine into the database so it can
> be managed from the web-interface again?
> 

well im not sure if there is a tool that does it automatically, 
but you can try the following (never tried this before, but should work):
on the host that run the vms:
* run vdsClient 0 getAllVmStats (or vdsClient -s 0 getAllVmStats if you are using secure connection)
* find in the result the vm id (first line) and the image id for each disk of the vms
* find under /rhev/data-center/{dc-id}/mastersd/master/vms/{vm-d}/ the ovf file which contains the vm info
* find the vm disk images on the storage domains
* use ovirt-image-uploader to upload the vm to an export domain (you need to look how exactly to do this one.. :) )
* import the vm.

> --
> sven === jabber/xmpp: sven at lankes.net
> _______________________________________________
> Users mailing list
> Users at ovirt.org
> http://lists.ovirt.org/mailman/listinfo/users
> 


More information about the Users mailing list