Buildbot Setup for Virtual Machines - Ubuntu 14.04 "trusty"
Base install
qemu-img create -f qcow2 /kvm/vms/vm-trusty-amd64-serial.qcow2 20G
qemu-img create -f qcow2 /kvm/vms/vm-trusty-i386-serial.qcow2 20GStart each VM booting from the server install iso one at a time and perform the following install steps:
kvm -m 2048 -hda /kvm/vms/vm-trusty-amd64-serial.qcow2 \
-cdrom /kvm/iso/ubuntu/trusty-server-amd64.iso \
-boot d -smp 2 -cpu qemu64 \
-net nic,model=virtio \
-net user,hostfwd=tcp:127.0.0.1:2293-:22
kvm -m 2048 -hda /kvm/vms/vm-trusty-i386-serial.qcow2 \
-cdrom /kvm/iso/ubuntu/trusty-server-i386.iso \
-boot d -smp 2 -cpu qemu64 \
-net nic,model=virtio \
-net user,hostfwd=tcp:127.0.0.1:2294-:22Once running you can connect to the VNC server from your local host with:
vncviewer -via ${remote_host} localhostReplace ${remote-host} with the host the vm is running on.
Note: When you activate the install, vncviewer may disconnect with a complaint about the rect being too large. This is fine. Ubuntu has just resized the vnc screen. Simply reconnect.
During the install, pick default options for the most part, with the following notes:
Set the hostname to
ubuntu-trusty-amd64orubuntu-trusty-i386(depending on which architecture we're installing)do not encrypt the home directory
When prompted if the timezone is correct, answer "No" and when the list comes up, scroll to the bottom and choose "UTC"
When partitioning disks, choose "Guided - use entire disk" (we do not want LVM)
No automatic updates
Choose software to install: OpenSSH server
Reboot when prompted. It will fail, so just kill the kvm process with^Ctrl+C.
Now that the VM is installed, it's time to configure it. If you have the memory you can do the following simultaneously:
set
vimas the preferred editor
Enabling passwordless sudo:
edit /boot/grub/menu.lst:
create the
.sshdirectory and thesudogroup
copy the
authorized_keysfile up to the VMs
create the buildbot user on the amd64 VM
create the buildbot user on the x86 VM
copy the ttyS0 file to the VMs
Apply all OS updates
copy the ttyS0 file to its proper location and shut down the VM
VMs for building .debs
VMs for install testing.
See Buildbot Setup for Virtual Machines - General Principles for how to obtain my.seed and sources.append.
VMs for MySQL upgrade testing
VMs for MariaDB upgrade testing
Add Key to known_hosts
Do the following on each kvm host server (terrier, terrier2, i7, etc...) to add the VMs to known_hosts.
This page is licensed: CC BY-SA / Gnu FDL
Last updated
Was this helpful?

