Re: Install a new guest remotely?

Daniel P. Berrange
2010-01-11T16:28:10Z

On Mon, Jan 11, 2010 at 10:20:02AM -0600, Neil Aggarwal wrote:
> Hello:
>
> > is a pain I'm using virt-install but I need X installed, we do not
> > install X on our servers at all, and will rather not to. So can I do
>
> Our KVM servers are remote and do not have X installed.
>
> When we install a guest, we tell it to use vnc
> by adding --vnc --noautoconsole to the virt-install
> command.

Yep, that is the best way to run virt-install on a head-less machine

> Then use virsh vncdisplay to get the port on the server
> to connect your VNC viewer. We use an SSH tunnel
> for the connection to ensure security.

You can also use "virt-viewer" to automate that bit of the process

virt-viewer --connect qemu+ssh://root@servername/system GUESTNAME

and virt-viewer will connect to libvirt on the remote host, query the
VNC port and setup an SSH tunnel for the VNC connection. It is
essentially a VNC client that knows about libvirt. It can do TLS or
SASL security instead of SSH tunnels too if desired

Regards,
Daniel
--
|: Red Hat, Engineering, London -o- http://people.redhat.com/berrange/ :|
|: http://libvirt.org -o- http://virt-manager.org -o- http://ovirt.org :|
|: http://autobuild.org -o- http://search.cpan.org/~danberr/ :|
|: GnuPG: 7D3B9505 -o- F3C9 553F A1DA 4AC2 5648 23C1 B3DF F742 7D3B 9505 :|