[virt-tools-list] How to determine if installation is successful?
Cole Robinson
crobinso at redhat.com
Tue Mar 8 15:16:48 UTC 2011
On 03/07/2011 09:09 PM, Kay Williams wrote:
> Hello,
>
> I am writing a python script to automate the installation of new virtual machines using virt-install. The question I have is how to determine when an installation has completed successfully. In our particular case, we are installing RHEL and CentOS 5 and 6 systems. If we happen to provide invalid information for the virt-install "extra-args" parameter, or in the kickstart, the anaconda install stops and waits for user input. If the user chooses to halt the installation by sending a CTRL+ALT+DELETE, control returns to virt-install, which provides an misleading message that installation was complete along with a misleading error code "0" (success).
>
> Can anyone suggest a good way to determine if a vm installation is successful?
>
There isn't a whole lot we can easily do from virt-install to ensure
that the install completed successfully.
My recommendation would be to try and use guestfish to poke into the
disk image and look for say /etc/redhat-release, or add some magic at
the end of your kickstart to call out another machine to verify the
install completed.
- Cole
More information about the virt-tools-list
mailing list