A place for Unix Thoughts and Ideas

bootp like setup for Solaris 11 auto installer

Jumpstarting to sparc servers with bootp on Solaris 10 was very simple and straight forward, especially for those who didn’t or couldn’t run DHCP on their server networks.

However with Solaris 11, if you want to use auto-installer, you will need to setup or configure DHCP to hand out addresses to your Solaris hosts.

Here is a straight forward method for managing a DHCP server that functions similar to Bootp, with it only handing out address to your Auto Install Clients.

What I will be demonstrating is installing and configuring the dhcp-server and adding a network with and then adding a permanent address entry for a specific MAC address.

1. Install DHCP server

on Solaris 11:

# pkg install pkg:/service/network/dhcp/isc-dhcp

The server can also be existing and/or on run on Solaris 10.

2. Configure the DHCP Server

I was fortunate to have no conflicting DHCP servers on my subnet, if there was and that server is not allowing enough time for my auto installer DHCP server to respond, I would have kindly ask the dhcp server admistrator to insert a delay in the server.

We will be booting a server that is on the network, we are going to configure the DHCP server to use local files. Note that the dhcp server seems to need the network entry in /etc/netmasks to be present. On Solaris 11 this file by default has no entries in it.

/usr/sbin/dhcpconfig -D -r SUNWfiles -p /var/dhcp
echo “” >> /etc/netmasks
dhcpconfig -N -m -t -g
pntadm -C

3. Add client entry.

When adding the mac address to the server you want to make sure that there is 12 characters in the mac address (2 chars for each part of the address).

If you copied and pasted it from ifconfig or the lom, you may have to a add a zero to 1 or more of the fields. Additionally you’ll want to have a 01 in front and make sure it is in all CAPs and has none of the colons.

The client I’m adding is name test-ai-client and has the mac address 0:50:56:B0:0:D6, I will be specifying this as 01005056B000D6

# installadm create-client -e 01005056B000D6 -n s11-sparc

No local DHCP configuration found. If not already configured,
the following should be added to the DHCP configuration:
Boot server IP :
Boot file : 01005056B000D6

Note: determined more than one IP address configured for use with AI.
Please ensure the above 'Boot server IP' is correct.

For my infrastructure my build scripts create a macro in the dhcp server for each client which is the hostname (test-ai-client):

#dhtadm -A -m test-ai-client -d ":Subnet="testdomain.com":DNSserv=" 
# dhtadm -P
Name                    Type            Value
test-ai-client          Macro           :Subnet= 			    Macro           :Subnet=
aidhcpserver            Macro           :Include=Locale:Timeserv="testdomain.com":DNSserv=
Locale                  Macro           :UTCoffst=0:

Now adding the dhcp entry:

# pntadm -A test-ai-client -c "test-ai-client" -s `hostname | cut -d. -f1` -m test-ai-client -f "PERMANENT+MANUAL" -h test-ai-client -i 01005056B000D6
pntadm: Warning - No hosts resource value found in DHCP configuration file.
Operation succeeded, but hosts table was not updated.
#  pntadm -P
Client ID       Flags   Client IP       Server IP       Lease Expiration                Macro           Comment

01005056B000D6  03      Forever                         test-ai-client  test-ai-client

Of note in the command is the -s option which set the server option for the entry, you’ll want it to be the local dhcp servername.

If you are booting a sparc host, you dhcp macro entry will look like:

# dhtadm -A -m "denpdapsunadm1" -d ":Subnet=\"\":DNSdmain=testdomain.com:DNSserv="
# dhtadm -P
Name                    Type            Value
test-ai-client          Macro           :Subnet="":DNSdmain=testdomain.com:DNSserv= 			    Macro           :Subnet=
aidhcpserver            Macro           :Include=Locale:Timeserv="testdomain.com":DNSserv=
Locale                  Macro           :UTCoffst=0:

Now this has been added to the server, you can now network boot your client server.

If you run into issues with your configuration not working, you can easily debug the dhcp server through the following:

svcadm disable dhcp-server

/usr/lib/inet/in.dhcpd -dv


4 responses to “bootp like setup for Solaris 11 auto installer

  1. bradhudsonjr May 14, 2012 at 6:37 pm

    While the documentation says you ‘need’ DHCP, if you are installing SPARC systems, you do not need it at all. You can use the WANBOOT features found on most SPARC systems. See http://bradhudsonjr.wordpress.com/2011/08/10/how-to-create-an-ai-server/ for details (slightly dated b/c it was during pre-release, but all concepts are still present with maybe a syntax change or two in the GA release).

    • jflaster May 14, 2012 at 7:00 pm

      Thank you for the feedback.

      You can definitely go that route and it is less work if you have only a handful of hosts or if you absolutely can’t run dhcp at all.

      In my environment we have a large install base and I wanted a setup that would work across the board for Sparc/x86 with the majority of the heavy lifting done via scripts on the server, rather than the client. Less prone to user error. But your solution is good for the 1 offs and truly remote systems.

      • bradhudsonjr May 14, 2012 at 7:15 pm

        Our corporate standards actually dictate not using DHCP for our installs b/c we are large enough to have entirely different teams managing our static IP assignments pushed into DNS servers. We can’t perform a build without first having the static hostname/IP assigned in DNS, which is then easily scripted into profiles and manifests.

  2. jflaster May 14, 2012 at 7:22 pm

    My environment is similar in provisioning the IP/DNS prior to build. So the manifest/profiles do come up on the actual server. If I was restricted to not use DHCP/bootp, your method would be good choice and is very scriptable; although I’m not sure how to best handle it on the x86 side. Probably a custom boot cdrom like uberjs,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: