[et-mgmt-tools] How to specify the IP VNC listens on when using virt-install remotely over SSH

Daniel P. Berrange berrange at redhat.com
Tue Nov 18 10:56:31 UTC 2008

On Tue, Nov 18, 2008 at 10:50:35AM +0000, Stephan wrote:
> Hi,
> I'm trying to install a virtual machine from a .iso DVD image but am having
> problems, as VNC is listening on only and this is a headless
> server.
> Just as a bit of background information, I'm doing this via SSH on a Dell
> Poweredge server which has Ubuntu Server 8.10 on and libvirt
> 0.4.4-3ubuntu3. So far I've successfully virtualised Ubuntu using the
> Ubuntu vm-builder and can connect to the screens via VNC.
> The command I'm using to install from .iso images is:
> sudo virt-install --hvm --accelerate --os-type=linux --bridge=br0 --ram=256
> --vcpus=4 --check-cpu --name=centos1 --file-size=4 --vnc
> --file=/home/stephan/centos1 --location=/home/picseltech/centos.iso
> This is fine, it starts off the install and tells me I can connect via VNC
> to finish it off. However, unfortunately the VNC connection is only
> accessible through and I'm doing this remotel

NB, if you're connecting via SSH, then there is not any need to actually
make it listen on a public interface. virt-viewer will automatically
tunnel VNC connection over SSH too, eg

eg, if you're using QEMU/KVM, then 

 virt-viewer --connect qemu+ssh://root@somehostname/system centos1

Will connect to VNC remotely over SSH.

> Is there a way to specify the VNC listening IP address for the new virtual
> machine?
> In /etc/libvirt/qemu.conf I put vnc_listen = "" , but it doesn't
> pick that up.

Did you remember to restart the libvirtd daemon after making this change ?
This is the recommended way to make it listen on a public interface.

|: 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 :|

More information about the et-mgmt-tools mailing list