Diff for /wikisrc/tutorials/how_to_set_up_a_guest_os_using_xen3.mdwn between versions 1.2 and 1.3

version 1.2, 2012/02/05 07:14:36 version 1.3, 2013/04/16 06:54:41
Line 101  And copy it into / directory, like this: Line 101  And copy it into / directory, like this:
     # cp /usr/pkg/xen3-kernel/xen.gz /      # cp /usr/pkg/xen3-kernel/xen.gz /
           
   
 Finally, decompress it so that all versions of GRUB can read it:  
   
       
     # gunzip /xen.gz  
       
   
 ##  Xen DOM0 kernel  ##  Xen DOM0 kernel
   
 Lastly, we need a XEN-enabled kernel for our DOM0 domain. There are two  Lastly, we need a XEN-enabled kernel for our DOM0 domain. There are two
Line 132  copy and move it into the root directory Line 126  copy and move it into the root directory
     # cp netbsd-XEN3_DOM0.gz /      # cp netbsd-XEN3_DOM0.gz /
           
   
 Now decompress it to avoid any issues GRUB or Xen might have with gzipped  
 kernels  
   
       
     # gunzip /netbsd-XEN3_DOM0.gz  
       
   
 ##  Building it from source  ##  Building it from source
   
 Building a kernel from source is out of the scope of this section. Please  Building a kernel from source is out of the scope of this section. Please
Line 150  version, copy or move netbsd-XEN3_DOM0 i Line 137  version, copy or move netbsd-XEN3_DOM0 i
   
 #  Selecting a bootloader  #  Selecting a bootloader
   
 In NetBSD 5.0 the native boot loader, /boot, can load Xen directly. For  In NetBSD 5.0 the native boot loader, /boot, can load Xen directly.
 earlier versions of NetBSD you will need to use Grub. The NetBSD 5.0  The NetBSD 5.0 bootloader can be easily dropped into a NetBSD 4.x system by coping them into
 bootloader can be easily dropped into a NetBSD 4.x system by coping them into  
 /boot and running installboot(8) properly.  /boot and running installboot(8) properly.
   
 ##  Updating /boot  ##  Updating /boot
Line 196  for dom0' option and make sure you see X Line 182  for dom0' option and make sure you see X
 NetBSD kernel messages. Once you're satisfied it is working you can change the  NetBSD kernel messages. Once you're satisfied it is working you can change the
 "default=1" line to "default=5" to automatically boot Xen on reboot.  "default=1" line to "default=5" to automatically boot Xen on reboot.
   
 #  Setting up Grub  
   
 Before installing and configuring XEN3, we need to install grub, the  
 bootloader required to boot our XEN-enabled system.  
   
 To install it, use its package provided in pkgsrc ([sysutils/grub](http://pkgsrc.se/sysutils/grub)):  
   
       
     # cd /usr/pkgsrc/sysutils/grub  
     # make install  
       
   
 Building grub may take a while.  
   
 When installation is finished, you can proceed to grub's configuration in the  
 _/grub_ directory.  
   
 ##  GRUB configuration  
   
 First, create `/grub` (if it is not present), and copy paste the menu.lst file  
 below used by grub to read its configuration:  
   
       
     # mkdir /grub  
     # vi /grub/menu.lst  
       
   
 This typical _/grub/menu.lst_ file should have following content:  
   
       
       
     #Grub config file for NetBSD/xen. Copy as /grub/menu.lst and run  
     # grub-install /dev/rwd0d (assuming your boot device is wd0).  
     #  
     # The default entry to load will be the first one  
     default=0  
       
     # boot after 10s the default entry if the user didn't hit keyboard  
     timeout=10  
       
     # Same as above, but using VGA console  
     # We can use console=tty0 (Linux syntax) or console=pc (NetBSD syntax)  
     title Xen 3.0 / NetBSD (hda0, vga)  
       root(hd0,0)  
       kernel (hd0,a)/xen dom0_mem=514624  
       module (hd0,a)/netbsd-XEN3_DOM0 bootdev=/dev/wd0a ro console=tty0   
       
     #Load a regular NetBSD/i386 kernel. Can be useful if you end up with a  
     #nonworking /xen.gz  
     title NetBSD 4.0  
       root (hd0,a)  
       kernel --type=netbsd /netbsd  
       
     #Load the NetBSD bootloader, letting it load the NetBSD/i386 kernel.  
     #May be better than the above, as grub can't pass all required infos  
     #to the NetBSD/i386 kernel (e.g. console, root device, ...)  
     title NetBSD via chain  
     root        (hd0,a)  
     chainloader +1  
       
     # end of grub config file.  
       
   
 Notice that the statement **dom0_mem** is allocating half a gig to Xen. If you  
 have a box with 4Gb of RAM you probably want to change that to something  
 larger. A smaller number might be wise on systems with less RAM, etc...  
   
 #  Setting up DOM0  #  Setting up DOM0
   
 ##  Creating xen devices  ##  Creating xen devices

Removed from v.1.2  
changed lines
  Added in v.1.3


CVSweb for NetBSD wikisrc <wikimaster@NetBSD.org> software: FreeBSD-CVSweb