Skip to contentSkip to conversation

Fast reboot from linux to Xen hypervisor with kexec

DISCUSSION fly.limin 2 participants 2 messages Nov 17, 2009

Subsystems (2)
lore
Share & tools
lore

fly.limin

author
#0 lore raw

Hi:
recently i am researching fast boot from linux kernel to Xen hypervisor, it means when linux is running on the real machine, i just want to switch to Xen hypervisor without going through bootloader. both linux and dom0 of Xen using the same filesystem. since we boot Xen with the following command in grub:

title Xen 3.1.0 / XenLinux 2.6.18
kernel /boot/xen-3.gz
module /boot/vmlinuz-2.6.18-xen ro root=LABEL=/ rhgb quiet module /boot/initrd-2.6.18-xen.img
it's different from linux, but i think there are something in common. so is there any suggestions for me!

2009-11-17

Min Li
School of Computer Science and Technology
Cluster and Grid Computing Lab
Services Computing Technology and System Lab
Huazhong University of Science and Technology
Wuhan, 430074, China
Tel: +86-139-8625-1431
Email: [email protected]

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec

#1 lore raw
Quoted 9 lines · fly.limin

Hi:
recently i am researching fast boot from linux kernel to Xen hypervisor, it means when linux is running on the real machine, i just want to switch to Xen hypervisor without going through bootloader. both linux and dom0 of Xen using the same filesystem. since we boot Xen with the following command in grub:

title Xen 3.1.0 / XenLinux 2.6.18
kernel /boot/xen-3.gz
module /boot/vmlinuz-2.6.18-xen ro root=LABEL=/ rhgb quiet module /boot/initrd-2.6.18-xen.img
it's different from linux, but i think there are something in common. so is there any suggestions for me!

Kexecing from Linux to Xen and vice-versa should work fine.

On x86 try something like this:

kexec -l -t multiboot-x86 \
	--append="$XEN_ARGS" \
	--module="/boot/vmlinuz-2.6.18-xen ro root=LABEL=/ rhgb quiet" \
	--module=/boot/initrd-2.6.18-xen.img \
	/boot/xen-3.gz

kexec -e

Or on ia64 try something like this:

kexec -l \
	--append="$XEN_ARGS -- ro root=LABEL=/ rhgb quiet" \
	--initrd=/tmp/initramfs_data.cpio \
	--vmm=/boot/xen-3.gz \
	/boot/vmlinuz-2.6.18-xen

Where $XEN_ARGS is any command line parameters that you want to provide to the hypervisor. In the case of the example you gave it would be empty in which case the --append line in my x86 example could be removed.

_______________________________________________
kexec mailing list
[email protected]
http://lists.infradead.org/mailman/listinfo/kexec