WHAT'S HOT
Prev | Current Page 34 | Next

Prabhakar Chaganti

"Xen Virtualization: A Practical Handbook"


5. Create three files, one for holding the root file system,/, one for the /boot,
and the other for the swap.
~ dd if=/dev/zero of=/home/pchaganti/xen-images/ubuntu_feisty_domU.
img bs=1G count=6
~ dd if=/dev/zero of=/home/pchaganti/xen-images/ubuntu_feisty_swap_
domU.img bs=1G count=1
~ dd if=/dev/zero of=/home/pchaganti/xen-images/ubuntu_feisty_boot_
domU.img bs=1k count=1000
6. Create an ext3 filesystem on the root file image. This will be the image where
/ will be mounted.
~ /sbin/mkfs.ext3 /home/pchaganti/xen-
images/ubuntu_feisty_domU.img
7. Create an ext3 filesystem on the boot image file and create swap on the
swap file.
~ /sbin/mkfs.ext3 /home/pchaganti/xen-images/
ubuntu_feisty_boot_domU.img
~ /sbin/mkswap /home/pchaganti/xen-
images/ubuntu_feisty_swap_domU.img
We need to mount these files in a directory so that we can read and write
in them.
8. Create a directory called xen-mounts. We will create directories here for
mounting the various file images.
~ mkdir -p /home/pchaganti/xen-mounts/ubuntu_feisty_domU
9. Mount the file that will be used to store the root file system using a loop back.
# mount -o loop /home/pchaganti/xen-images/ubuntu_feisty_domU.img/
home/pchaganti /xen-mounts/ubuntu_feisty_domU
10. Run debootstrap. This will download and extract all the necessary files to the
above mounted directory.
~ /usr/sbin/debootstrap --arch i386 feisty /home/pchaganti/
xen-mount/ubuntu_feisty_domU http://archive.ubuntu.


Pages:
22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46