I'm running Oneric as the host, would like to create several virtual machines. Both the host and the guests will be headless - there is no display connected, and I'd like to connect to them via ssh.
Looks like kvm is the official ubuntu recommended way, so I'm following the documentation: http://help.ubuntu.com/community/KVM/CreateGuests
Here's my ubuntu-vm-builder command:
sudo ubuntu-vm-builder kvm oneiric \ --domain xpstage --dest xpstage --hostname xpstage \ --arch i386 --mem 1024 \ --user myusername --pass mypassword \ --bridge virbr0 --ip 192.168.122.2 --dns 126.96.36.199 \ --components main,universe,restricted \ --addpkg acpid --addpkg vim --addpkg openssh-server --addpkg avahi-daemon \ --libvirt qemu:///system ;
The guest appears to build just fine, but I can't reach it.
times out. My bridge network is setup:
virbr0 Link encap:Ethernet HWaddr 00:00:00:00:00:00 inet addr:192.168.122.1 Bcast:192.168.122.255 Mask:255.255.255.0 UP BROADCAST MULTICAST MTU:1500 Metric:1 RX packets:673 errors:0 dropped:0 overruns:0 frame:0 TX packets:21 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:60839 (60.8 KB) TX bytes:882 (882.0 B)
So I'm not sure what I'm doing wrong there.
Having failed with ssh I tried to console into it, but
virsh console xpstage
returns immediately, so I added a pty section to the configuration:
virsh edit xpstage
After adding the pty
virsh console xpstage connects, but doesn't display anything and key presses don't do anything.
I then tried setting up a Serial Console, but upstart doesn't like that:
start: Unknown job: ttyS0 .
Can some kind soul please guide me to how to setup a headless KVM guest on Oneric that I can connect to?