From PrgmrWiki
Revision as of 05:58, 24 March 2010 by Grobe0ba (talk | contribs) (Added DNS information.)

chris2's gentle guide to installing NetBSD in a prgmr DomU (January 2009)

Installing NetBSD as DomU is easy, but not trivial.

Boot your preconfigured system, jot down its IP address:

eth0      Link encap:Ethernet
          inet addr:64.62.205.XXX  Bcast:  Mask:

You will also need the IP address of a DNS server. You can copy the one from /etc/resolv.conf , or you can use a public DNS server, such as Google's Pulic DNS Servers.

The IP address for Google's Pulic DNS Server is

On stables, shutdown the instance.

On stables, create instance, in Grub, boot "Centos Rescue".

Wait for DHCP to time out.

Setup IP with

ifconfig eth0 up 64.62.205.XXX/26
route add -net gw eth0

Partition /dev/xvda, create a 32mb ext2 partition as partition 1, make a directory boot/, wget and extract there (stable versions should be similar):

(or newer)

Create a file boot/grub/menu.lst with this content:

timeout 5

title NetBSD run
        root (hd0,0)
        kernel /boot/netbsd-XEN3_DOMU

title NetBSD install
        root (hd0,0)
        kernel /boot/netbsd-INSTALL_XEN3_DOMU

Shutdown again.

Create instance. Boot first grub item, then pick "NetBSD install".

Install onto xbd0(!).

IMPORTANT: Change disklabel such that xbd0a starts after the end of the ext2 partition. Add a disklabel for the /boot partition, so you can update the kernels and adjust the menu.lst later. (You can find out its sectors by using fdisk /dev/xbd0). Here is an example disklabel setup for a 3072M disk with a 32M boot partition:

 We now have your BSD-disklabel partitions as:
 This is your last chance to change them.
    Start  MB   End  MB  Size  MB FS type    Newfs Mount Mount point
    --------- --------- --------- ---------- ----- ----- -----------
 a:        31      2912      2882 FFSv1      Yes   Yes   /
 b:      2913      3040       128 swap
 c:         0      3071      3072 NetBSD partition
 d:         0      3071      3072 Whole disk
 e:         0        30        31 Linux Ext2
 f:         0         0         0 unused
 g: Show all unused partitions
 h: Change input units (sectors/cylinders/MB)
>x: Partition sizes ok

Install by FTP, setup networking by the noted data. Adjust the FTP paths to the snapshot you use.

Reboot, now with "NetBSD run".


19:30, 3 February 2009 (UTC)