FAQ: PXE booting NexentaStor

PXE-Boot Installation of NexentaStor

The Preboot eXecution Environment (PXE, pronounced pixie) is used to boot computers using a network interface, with a bootable image located at a remote specified location. PXE employs a combination of DHCP and TFTP, to locate the bootable image, and boot from it. For general information and further references, see for instance wikipedia article Preboot Execution Environment.

Requirements:

1. Bootable ISO image (NexentaStor v.2.2.1 or later, or NexentaCorePlatform 3 Alpha2 or later)
2. NFS Server (note: do not use NFSv4 on a Linux based system)
3. PXE-Boot Server (DHCP server and TFTP server)

The procedure described in this article applies to both NexentaStor(tm) and NexentaCorePlatform(tm)

Example:
In this example NFS Server has IP address 10.1.1.2, and on this server there is a shared path for our PXE installation:

10.1.1.2:/export/images/NexentaOS

Let's say, a PXE Boot Server has IP address = IP 10.1.1.1. The PXE Boot Server runs both DHCP and TFTP.

In our PXE based installations, we have used ISC DHCP (Internet System Consortium DHCP – www.isc.org) and HPA-TFTP, with TFTP root directory TFTP-ROOT-DIR = /var/lib/tftpboot.

The steps:

1. Burn the NexentaStor ISO on a CD and mount the latter (or mount the ISO image itself), and then copy all files and directories from the ISO to a shared folder on NFS Server.

2. Copy kernel, miniroot and loader from the ISO to TFTP Server, as follows:

- kernel dir: ISO:/platform/i86pc/kernel    =>>    TFTP-ROOT-DIR/nexenta_os/
- miniroot: ISO:/platform/i86pc/miniroot    =>>    TFTP-ROOT-DIR/nexenta_os/
- loader: ISO:/boot/grub/pxeloader        =>>     TFTP-ROOT-DIR/boot/grub/


3. Prepare a boot loader menu. The menu is a simple text file called menu.lst, with the following content:

default 0
timeout 10
title Nexenta PXE Instalation
kernel$ /nexenta_os/platform/i86pc/kernel/$ISADIR/unix
-B iso_nfs_path=10.1.1.2:/export/images/NexentaOS
module$ /nexenta_os/platform/i86pc/miniroot

(note: the kernel$ line above must be a single line in your menu.lst)

Copy menu.lst =>>     TFTP-ROOT-DIR/boot/grub/

4. Configure DHCP Server via its configuration file /etc/dhcp3/dhcpd.conf

ddns-update-style none;
authoritative;
option grubmenu code 150 = text;
# option domain-name-servers 192.168.1.1; <<< optional
default-lease-time 604800;
max-lease-time 864001;

subnet 10.1.1.0 netmask 255.255.255.0 {
range 10.1.1.3 10.1.1.200;
option subnet-mask 255.255.255.0;
# option broadcast-address 10.1.0.255; <<< optional
option routers 10.1.1.254;
filename "/boot/grub/pxegrub"; #<<<<<<< our loader file on TFTP Server (see step 2)
option grubmenu "/boot/grub/menu.lst";#<<<<<<< our menu.lst file on TFTP Server (see step 3)
next-server 10.1.1.1; #<<<<<<< IP address our TFTP Server
}


Restart DHCP Server for enable the changes.

5. Enable PXE Boot on the Computers to be installed.

6. Wait for Nexenta Installer to come up, and follow the Installer's instructions.