Solaris x86 jumpstart on ISC DHCP
February 18th, 2008If you are using the Solaris dhcp server, stop now. Save yourself hours of time of trying to figure out pntadm, dhtadm, and just use ISC DHCP on Solaris. It’s very simple, painless, and you will be glad you did. The only problem I ran across was compiling the ISC dhcp straight off the website, it compiled fine, but I ran into issues where it wouldn’t see packets properly. So I just used the one off Blastwave instead. Here’s how to get a jumpstart going with ISC:
- CD setup
Copy the CD contents to an existing directory:
# /cdrom/Solaris_11/Tools/setup_install_server /jumpstart/solx86b81
Set the /jumpstart directory shared NFS:
# zfs set sharenfs=ro,anon=0 pool/jumpstart
- Jumpstart configuration
Create /jumpstart/configs/sysidcfg, /jumpstart/configs/any_machine and /jumpstart/configs/rules:
sysidcfg:
system_locale=C
timezone=US/Central
terminal=xterms
security_policy=NONE
root_password=yTUdfabsalkjfE
timeserver=localhost
network_interface=primary
{dhcp
protocol_ipv6=no}
name_service=NONE
nfs4_domain=dynamic
service_profile=limited_net
any_machine:
install_type initial_install
system_type standalone
partitioning default
cluster SUNWCXall
fdisk all solaris all
partitioning explicit
filesys rootdisk.s0 20000 /
filesys rootdisk.s1 20000 swap
filesys rootdisk.s7 free /zfs
rules:
any - - any_machine -
Run /jumpstart/configs/check to create the rules.ok file:
# /jumpstart/configs/check
- Client setup
Run the add_install_client tool, this creates everything in /tftpboot:
# /cdrom/Solaris_11/Tools/add_install_client -d -e 06:00:00:00:00:00 -s 192.168.0.177:/jumpstart/solx86crossbow -c 192.168.0.177:/jumpstart/configs -p 192.168.0.177:/jumpstart/configs -t /jumpstart/solx86crossbow/boot i86pc
-d : it will be a dhcp client
-e : mac address of client
-s : ip and directory of where cd is located
-c : ip and directory of where rules file is located
-p : ip and directory of where the sysidcfg is located
-t : path where the boot image is located
- ISC DHCP configuration
The ISC DHCP 4 off of the ISC website compiles fine and runs fine, but doesn’t see DHCP requests properly. This is due to the Solaris DLPI issue described here. There is a fix to uncomment a line in the code but then it doesn’t compile properly.
The ISC dhcp that comes out of Blastwave is version 3 and it works fine seeing requests and sending them.
- Configuration
Configuration of ISC DHCP is very simple and painless, especially if you are used to Solaris DHCP. Most of the options in the configuration file are self explanatory and you don’t even need to look up what they mean (if you are familiar with how DHCP works).
Here’s the dhcpd.conf for jumpstart (values will need to be changed depending on your network):
option domain-name-servers 192.168.0.1;
default-lease-time 1000;
max-lease-time 10000;
allow bootp;
allow booting;ddns-update-style none;
ignore unknown-clients;authoritative;
option space SUNW;
option SUNW.root-mount-options code 1 = text;
option SUNW.root-server-ip-address code 2 = ip-address;
option SUNW.root-server-hostname code 3 = text;
option SUNW.root-path-name code 4 = text;
option SUNW.swap-server-ip-address code 5 = ip-address;
option SUNW.swap-file-path code 6 = text;
option SUNW.boot-file-path code 7 = text;
option SUNW.posix-timezone-string code 8 = text;
option SUNW.boot-read-size code 9 = unsigned integer 16;
option SUNW.install-server-ip-address code 10 = ip-address;
option SUNW.install-server-hostname code 11 = text;
option SUNW.install-path code 12 = text;
option SUNW.sysid-config-file-server code 13 = text;
option SUNW.JumpStart-server code 14 = text;
option SUNW.terminal-name code 15 = text;
option SUNW.SbootURI code 16 = text;subnet 192.168.0.0 netmask 255.255.255.0 {
range 192.168.0.100 192.168.0.250;
option subnet-mask 255.255.255.0;
option broadcast-address 192.168.0.255;
option routers 192.168.0.1;
}group {
use-host-decl-names on;
vendor-option-space SUNW;filename “pxegrub.I86PC.Solaris_11-1″;
next-server 192.168.0.177;
option SUNW.JumpStart-server “192.168.0.177:/jumpstart”;host box {
hardware ethernet 00:e0:81:33:74:d4;
fixed-address 192.168.0.50;
option SUNW.sysid-config-file-server = “192.168.0.177:/jumpstart/configs/sysidcfg”;
}
}
The *filename* option may change between Solaris versions, so check your /tftpboot directory for the pxegrub image that exists in there.
- Starting ISC dhcp
ISC dhcpd has a few options and is run like:
# /opt/csw/sbin/dhcpd
interface0 If you run it without interface0 it will run on all interfaces.
-d : debug mode
-cf : alternate configuration file
-lf : alternate lease file
-p : port (default 67)
-f : run in foreground
-q : don’t print out copyright message
-t : test configuration for correct syntax
-T : test lease file syntax
When dhcpd is started, it reads two files at startup: the dhcpd.conf configuration file, and the leases file. The lease file holds all of the dhcp leases it gives out and by default is at /var/db/dhcpd.leases. For the Blastwave installation, it is at /var/opt/csw/dhcp/dhcpd.leases. You may need to create this file first before starting dhcpd. The pid file for the daemon is at /var/opt/csw/dhcp/dhcpd.pid.
For debugging, the best way to run it is:
# /opt/csw/sbin/dhcpd -d -f -cf /path/to/dhcpd.conf





















