Managing VMWare ESX without VMWare's Windows Client Part 1
For a number of years since switching to a Mac the only need for Windows has been for the VMWare client for my home lab. This has worked reasonably well through the XP years, and survived a migration to Windows 7 even, but recently whatever Windows 10 ‘preload’ does has broken my Windows 7 VM’s while leaving them unable to upgrade to Windows 10 and finally the moment has arrived where I need to break free however painful.
VMWare Fusion Pro looks like a good way forward, but given that my next mobile device to replace my aging Macbook Pro is going to be an iPad and keyboard that doesn’t work as a way forward either. I needed something lightweight and command line.
Step forward the libvirt project and its tools - especially virsh. I do remember its inception many years ago as a way to unify management of the then iffy KVM, the likely at the time winner XEN, plus the other smaller players like lxc.
Installing virt-manager
# yum install virt-manager
Connecting to the ESX server… if like myself you don’t have a full SSL certificate authority setup you’ll need the ‘?no_verify=1’. Omit it in a production environment.
$ virsh -c esx://192.168.1.73/?no_verify=1
Enter username for 192.168.1.73 [root]:
Enter root's password for 192.168.1.73:
Welcome to virsh, the virtualisation interactive terminal.
Type: 'help' for help with commands
'quit' to quit
virsh #
Connecting to the ESX server… if like myself you don’t have a full SSL certificate authority setup you’ll need the ‘?no_verify=1’. Omit it in a production environment. First thing you’re likely to need is to see what VM’s you have. In virsh parlance - ‘domains’.
virsh # list --all
Id Name State
----------------------------------------------------
1 switch1 running
2 hopper running
3 dns1 running
- dns2 shut off
- ldap1 shut off
- - - - - - - - - - - -8< - - - - - - - - - - - - - -
- solweb2 shut off
- solwlserv1 shut off
- solwlserv2 shut off
- switch2 shut off
Next thing is you’ll need to start some of them...
virsh # start linc7web1
Domain linc7web1 started
...and of course, stop some of them.
virsh # shutdown linc7lb1
error: Failed to shutdown domain linc7lb1
error: internal error: HTTP response code 500 for call to 'ShutdownGuest'. Fault: ServerFaultCode - Cannot complete operation because VMware Tools is not running in this virtual machine.
If you see the above on a VM, install the vmware tools (e.g. yum install -y open-vm-tools).
virsh # shutdown linc7lb1
Domain linc7lb1 is being shutdown
No comments:
Post a Comment