[virt-tools-list] virtual machine start detection

Cole Robinson crobinso at redhat.com
Tue Sep 16 11:23:57 UTC 2014


On 09/16/2014 07:02 AM, Farkas Levente wrote:
> isn't there anybody who can have any useful tip?
> 
> On Mon, Sep 1, 2014 at 11:24 AM, Farkas Levente <lfarkas at lfarkas.org
> <mailto:lfarkas at lfarkas.org>> wrote:
> 
>     hi,
>     we'd like to automatically install our test system and we'd like to
>     detect somehow when the virtual machines (installed by kickstart script)
>     finish it's
>     installation (ie. the machines installed and rebooted). do you know any
>     good way for detect this?
>     thanks in advance.
>     regards.

You can do virt-install --wait -1, when the VM reboots after install,
virt-install will exit. So just watch for successful completion of virt-install.

It won't tell you that the VM successfully booted into the OS, just that the
VM shutdown, and then re-powered-on successfully. If you need some indication
that the OS booted correctly, you'll need to come up with some extra solution,
maybe having the guest ping an external machine, or ssh into the guest, or
maybe query a qemu guest agent command via virsh.

- Cole




More information about the virt-tools-list mailing list