On Tue, Oct 12, 2004 at 02:55:41PM +0000, Mark A. Williamson wrote:
> Guys,
>
> Documentation is one of the main hurdles we'd like to get out of the way
> before releasing 2.0. Stephan and I are at this very minute grokking the
> docs to start bringing things up to date.
>
> We'd still like all the help we can get:
> * If you've written any howtos, we'd like to incorporate them into the main
> user manual.
> * If there's anything you'd really like to see in the docs then please tell
> us
> (if you can contribute the start of some text, that'd be even better!).
> * If you find any mistakes, please report them.
> * If you found there were any special steps involved in getting Xen working
> on
> your distro, beyond what the docs describe, please let us know. We'd like to
> cover any distro-specific quirks...
>
Here's some info how to install Debian 3.1 (sarge) for xen:
1) Set up Xen 2 and test it's working OK and you can run domains with it.
You can find help for this from the Xen Documentation.
2) Create disk images for root-fs and swap
dd if=/dev/zero of=/path/diskimage bs=1024k count=size_in_megabytes
dd if=/dev/zero of=/path/swapimage bs=1024k count=size_in_megabytes
If you're going to use this filesystem/diskimage only as a "template"
for
other vm diskimages, something like 300 MB should be enough.. (of
course it
depends what kind of packages you are planning to install to the
template)
3) Create filesystem and swap to the images
mkfs.ext3 /path/diskimage
mkswap /path/swapimage
4) Mount the diskimage for installation
mount -o loop /path/diskimage /mnt/disk
5) Install Debian using debootstrap
Make sure you have debootstrap installed on the host. If you are
running Debian sarge (3.1 / testing) or unstable you can install it by
running apt-get install debootstrap.
Install debian base to the diskimage:
debootstrap --arch i386 sarge /mnt/disk
http://ftp.<countrycode>.debian.org/debian
Or you can of course use any other Debian http/ftp mirror you want.
6) When debootstrap finishes (successfully) modify settings
chroot /mnt/disk /bin/bash
Edit the following files using vi or nano and make needed settings:
/etc/hostname
/etc/hosts
/etc/resolv.conf
/etc/network/interfaces
/etc/networks
Set up access to the services
/etc/hosts.deny
/etc/hosts.allow
/etc/inetd.conf
Add Debian mirror to:
/etc/apt/sources.list
And create fstab like this:
/dev/sda1 / ext3 errors=remount-ro 0 1
/dev/sda2 none swap sw 0 0
proc /proc proc defaults 0 0
logout
7) Umount the diskimage
umount /mnt/disk
8) Create Xen 2 configuration file for the new domain. You can use the
example-configurations coming with xen as a template.
Make sure you have the following set up:
disk = [ 'file:/path/diskimage,sda1,w', 'file:/path/swapimage,sda2,w' ]
root = "/dev/sda1 ro"
I used the default Xen Linux-2.4.27-XenU kernel for the domain.
9) Start the new domain
xm create -f domain_config_file
Check that the new domain is running:
xm list
10) Attach to the console of the new domain.
You should see something like this when starting the new domain:
"Started domain testdomain2, console on port 9626"
There you can see the ID of the console: 26. You can also
list the consoles with "xm consoles". (ID is the last two digits of
the portnumber.)
Attach to the console:
xm console 26
or by telnetting to the port 9626 of localhost.
11) Log in and run base-config
As a default there's no password for the root.
Check that everything looks OK, and the system started without
errors. Check that the swap is active, and the network settings are
correct.
Run /usr/sbin/base-config to set up the Debian settings.
Set up the password for root using passwd.
12) Done. You can exit the console by pressing ctrl + ]
If you need to create new domains, you can just copy the contents of
the "template"-image to the new disk images simply by mounting the template
and the new image, and using cp -a or tar and then modify the image-specific
settings (hostname, network settings, etc).
Hope this helps somebody. There might be errors in the text.. please feel
free to correct :)
Someone on the xen-devel list was also doing automatic debian-installation
script based on configuration templates.. Check that also.
-- Pasi Kärkkäinen
^
. .
Linux
/ - \
Choice.of.the
.Next.Generation.
-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/xen-devel
|