Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Part 1. Creating a Centos HVM domU with working PV drivers
- #=======================================================================
- start with standard Centos 5.3 x86_64 HVM install.
- - my HVM domU config file :
- #=================================================
- memory = 500
- vif = [ 'mac=00:16:3E:49:CA:65, bridge=br6' ]
- disk = [
- 'phy:/dev/rootVG/testlv,hda,w',
- 'file:/data/iso/centos.iso,hdc:cdrom,r',
- ]
- boot="cd"
- device_model = '/usr/lib64/xen/bin/qemu-dm'
- kernel = "/usr/lib/xen/boot/hvmloader"
- builder='hvm'
- sdl=0
- vnc=1
- vnclisten="0.0.0.0"
- #vncunused=0
- vncpasswd=''
- #stdvga=0
- serial='pty'
- #localtime=1
- usbdevice='tablet'
- acpi=1
- apic=1
- pae=1
- vcpus=1
- #=================================================
- Note boot="cd". With this config if you're using "fresh" LVM or image file, the harddisk will be unbootable initally and it will boot from CD. After installation it will automatically boot from harddisk.
- - if you want serial text console (like I do), on DVD installation splash screen start installation with
- linux text console=vga console=ttyS0
- - during package selection, unselect "desktop GNOME" if you want text login like I do. Although not required, this will reduce resource needs (e.g. memory) and make subsequent setup easier.
- - proceed untill installation finished
- activate PV drivers
- - edit /boot/grub/menu.lst so it looks like this (note ide0=noprobe)
- #=================================================
- default=0
- timeout=5
- serial --unit=0 --speed=9600
- terminal --timeout=5 serial console
- title CentOS (2.6.18-128.el5)
- root (hd0,0)
- kernel /vmlinuz-2.6.18-128.el5 ro root=/dev/VolGroup00/LogVol00 console=ttyS0 ide0=noprobe
- initrd /initrd-2.6.18-128.el5.img
- #=================================================
- - edit /etc/modprobe.conf so it looks like this
- #=================================================
- #alias eth0 8139cp
- blacklist 8139cp
- blacklist 8139too
- alias scsi_hostadapter ata_piix
- # xen HVM
- alias eth0 xen-vnif
- alias scsi_hostadapter1 xen-vbd
- #=================================================
- -recreate initrd
- cd /boot
- mv initrd-2.6.18-128.el5.img initrd-2.6.18-128.el5.img.bak
- mkinitrd -v initrd-2.6.18-128.el5.img 2.6.18-128.el5
- - init 6
- - reconnect to domU console (with either "xm console" or vncviewer)
- - login, check whether xen-vbd activates correctly
- # ls -la /sys/class/net/eth0/device
- lrwxrwxrwx 1 root root 0 Apr 25 11:50 /sys/class/net/eth0/device -> ../../../devices/xen/vif-0
- # ls -la /sys/block/hda/device
- lrwxrwxrwx 1 root root 0 Apr 25 11:50 /sys/block/hda/device -> ../../devices/xen/vbd-768
- #=======================================================================
- End of part 1.
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement