1 ********************************************************
2 Recipe for getting/building/running Xen/ia64 with pv_ops
3 ********************************************************
4 This recipe describes how to get xen-ia64 source and build it,
5 and run domU with pv_ops.
12 it (aka "hg") is an open-source source code
13 management software. See the below.
14 http://www.selenic.com/mercurial/wiki/
18 Getting and Building Xen and Dom0
19 =================================
29 # hg clone http://xenbits.xensource.com/ext/ia64/xen-unstable.hg
31 # hg clone http://xenbits.xensource.com/ext/ia64/linux-2.6.18-xen.hg
35 3. # make install-tools
37 4. copy kernels and xen::
39 # cp xen/xen.gz /boot/efi/efi/redhat/
40 # cp build-linux-2.6.18-xen_ia64/vmlinux.gz \
41 /boot/efi/efi/redhat/vmlinuz-2.6.18.8-xen
43 5. make initrd for Dom0/DomU::
45 # make -C linux-2.6.18-xen.hg ARCH=ia64 modules_install \
46 O=$(pwd)/build-linux-2.6.18-xen_ia64
47 # mkinitrd -f /boot/efi/efi/redhat/initrd-2.6.18.8-xen.img \
48 2.6.18.8-xen --builtin mptspi --builtin mptbase \
49 --builtin mptscsih --builtin uhci-hcd --builtin ohci-hcd \
52 Making a disk image for guest OS
53 ================================
57 # dd if=/dev/zero of=/root/rhel5.img bs=1M seek=4096 count=0
58 # mke2fs -F -j /root/rhel5.img
59 # mount -o loop /root/rhel5.img /mnt
60 # cp -ax /{dev,var,etc,usr,bin,sbin,lib} /mnt
61 # mkdir /mnt/{root,proc,sys,home,tmp}
63 Note: You may miss some device files. If so, please create them
64 with mknod. Or you can use tar instead of cp.
66 2. modify DomU's fstab::
69 /dev/xvda1 / ext3 defaults 1 1
70 none /dev/pts devpts gid=5,mode=620 0 0
71 none /dev/shm tmpfs defaults 0 0
72 none /proc proc defaults 0 0
73 none /sys sysfs defaults 0 0
77 set runlevel to 3 to avoid X trying to start::
82 Start a getty on the hvc0 console::
84 X0:2345:respawn:/sbin/mingetty hvc0
86 tty1-6 mingetty can be commented out
88 4. add hvc0 into /etc/securetty::
90 # vi /mnt/etc/securetty (add hvc0)
96 FYI, virt-manager can also make a disk image for guest OS.
97 It's GUI tools and easy to make it.
103 elilo of RHEL5 can boot Xen and Dom0.
104 If you use old elilo (e.g RHEL4), please download from the below
105 http://elilo.sourceforge.net/cgi-bin/blosxom
106 and copy into /boot/efi/efi/redhat/::
108 # cp elilo-3.6-ia64.efi /boot/efi/efi/redhat/elilo.efi
110 2. modify elilo.conf (like the below)::
112 # vi /boot/efi/efi/redhat/elilo.conf
118 image=vmlinuz-2.6.18.8-xen
121 initrd=initrd-2.6.18.8-xen.img
123 append=" -- rhgb root=/dev/sda2"
125 The append options before "--" are for xen hypervisor,
126 the options after "--" are for dom0.
128 FYI, your machine may need console options like
129 "com1=19200,8n1 console=vga,com1". For example,
130 append="com1=19200,8n1 console=vga,com1 -- rhgb console=tty0 \
131 console=ttyS0 root=/dev/sda2"
133 Getting and Building domU with pv_ops
134 =====================================
138 # git clone http://people.valinux.co.jp/~yamahata/xen-ia64/linux-2.6-xen-ia64.git/
140 2. git branch (if necessary)::
142 # cd linux-2.6-xen-ia64/
143 # git checkout -b your_branch origin/xen-ia64-domu-minimal-2008may19
146 The current branch is xen-ia64-domu-minimal-2008may19.
147 But you would find the new branch. You can see with
148 "git branch -r" to get the branch lists.
150 http://people.valinux.co.jp/~yamahata/xen-ia64/for_eagl/linux-2.6-ia64-pv-ops.git/
156 git://git.kernel.org/pub/scm/linux/kernel/git/aegl/linux-2.6 test)
158 3. copy .config for pv_ops of domU::
160 # cp arch/ia64/configs/xen_domu_wip_defconfig .config
162 4. make kernel with pv_ops::
167 5. install the kernel and initrd::
169 # cp vmlinux.gz /boot/efi/efi/redhat/vmlinuz-2.6-pv_ops-xenU
170 # make modules_install
171 # mkinitrd -f /boot/efi/efi/redhat/initrd-2.6-pv_ops-xenU.img \
172 2.6.26-rc3xen-ia64-08941-g1b12161 --builtin mptspi \
173 --builtin mptbase --builtin mptscsih --builtin uhci-hcd \
174 --builtin ohci-hcd --builtin ehci-hcd
176 Boot DomainU with pv_ops
177 ========================
179 1. make config of DomU::
182 kernel = "/boot/efi/efi/redhat/vmlinuz-2.6-pv_ops-xenU"
183 ramdisk = "/boot/efi/efi/redhat/initrd-2.6-pv_ops-xenU.img"
187 disk = [ 'file:/root/rhel5.img,xvda1,w' ]
188 root = "/dev/xvda1 ro"
189 extra= "rhgb console=hvc0"
191 2. After boot xen and dom0, start xend::
193 # /etc/init.d/xend start
195 ( In the debugging case, `# XEND_DEBUG=1 xend trace_start` )
203 - Wiki of Xen/IA64 upstream merge
204 http://wiki.xensource.com/xenwiki/XenIA64/UpstreamMerge
206 Written by Akio Takebe <takebe_akio@jp.fujitsu.com> on 28 May 2008