Difference between revisions of "Setting up a xen server"
(→4gb seg fixup messages: : I figured it out!) |
(updated) |
||
Line 1: | Line 1: | ||
oh, have fun. | oh, have fun. | ||
− | == to | + | == to screate the parent server == |
install the freegeek-xen-server which includes some custom hooks for xen at | install the freegeek-xen-server which includes some custom hooks for xen at | ||
freegeek. | freegeek. | ||
− | apt-get install freegeek-xen-server | + | apt-get install freegeek-xen-server lvm2 |
symlink the kernel and initrd images, otherwise we'll have to manually update | symlink the kernel and initrd images, otherwise we'll have to manually update | ||
Line 22: | Line 22: | ||
dist = etch | dist = etch | ||
passwd = 1 | passwd = 1 | ||
− | mirror = http:// | + | mirror = http://debian.osuosl.org/debian/ |
modify /etc/xen/xend-config.sxp: | modify /etc/xen/xend-config.sxp: | ||
Line 29: | Line 29: | ||
;Controlling the amount of memory dom0 uses | ;Controlling the amount of memory dom0 uses | ||
− | * In /boot/grub/menu.lst add to the line # xenhopt=dom0_mem=256M then run | + | * In /boot/grub/menu.lst add to the line # xenhopt=dom0_mem=256M then run update-grub |
== to create an instance on the parent server == | == to create an instance on the parent server == |
Revision as of 11:49, 5 August 2008
oh, have fun.
to screate the parent server
install the freegeek-xen-server which includes some custom hooks for xen at freegeek.
apt-get install freegeek-xen-server lvm2
symlink the kernel and initrd images, otherwise we'll have to manually update each xen instance's configuration file on upgrade:
ln -s /boot/vmlinuz-MOST-RECENT-VERSION /boot/vmlinuz-xen ln -s /boot/initrd.img-MOST-RECENT-VERSION /boot/initrd.img-xen
edit /etc/xen-tools/xen-tools.conf:
kernel = /boot/vmlinuz-xen initrd = /boot/initrd.img-xen debootstrap = 1 lvm = vg dist = etch passwd = 1 mirror = http://debian.osuosl.org/debian/
modify /etc/xen/xend-config.sxp:
(network-script freegeek-network-script)
- Controlling the amount of memory dom0 uses
- In /boot/grub/menu.lst add to the line # xenhopt=dom0_mem=256M then run update-grub
to create an instance on the parent server
Create new xen instances with:
xen-create-image --hostname SERVERNAME --ip 192.168.?.? --netmask 255.255.255.0 --gateway 192.168.?.1
Make sure SERVERNAME and the chosen ip address don't exist already.
Prepare to wait awhile while this all installs. Kill your time by editing the appropriate dns files and the purpose file in the ass svn project, check your work, and then commit the changes. Then ssh into dns1 and:
cd /var/cache/bind svn update /etc/init.d/bind9 reload sudo /etc/init.d/bind9 reload
Continue waiting for your install to happen. Go help out at the Front Desk or something.
It will ask for a root password. Have one prepared and ready to go.
Your configuration file will be in:
/etc/xen/NAME.cfg
Check to see that it is there.
To start the xen instance:
xm create /etc/xen/NAME.cfg
To list the running xen instances and how much resources they're using:
xm list
To get to a login screen on the vm, either ssh in, or:
xm console NAME
To get out of the instance, the secret keystroke is Ctrl-].
log into the xen instance (either with ssh or xm console), and ensure the freegeek-xen-instance package is installed:
apt-get install freegeek-xen-instance
problems
4gb seg fixup messages
Try installing libc6-xen (and rebooting)
If that fails, then do this: (and reboot)
echo 'hwcap 0 nosegneg' > /etc/ld.so.conf.d/libc6-xen.conf && ldconfig