Friday, July 6, 2012

AI - Framework installation


Beyond the AI server itself, an ISC-DHCP server and an IPS repository server are required.
Assume 192.168.0.11 is the IP address of the AI server being set up.
     
Take a snapshot of the system (just in case):
  
# zfs snapshot -r rpool@backup
# zfs destroy rpool/swap@backup
# zfs destroy rpool/dump@backup
 
To install the AI server and tools, simply add the installadm package.
For a "dry-run" (preview of the installation changes) add the -nv  option. 
  
# pkg install installadm

At first, there should be nothing configured:
  
# installadm list
There are no services configured on this server.

Perhaps it's a good idea to pre-create a ZFS dataset for it:
  
# zfs create -o compression=on rpool/export/auto_install
# zfs create rpool/export/auto_install/files

Enable the mDNS (multicast DNS):
  
# svcadm enable dns/multicast

Then create the default service and let most things setup automatically:
  
# installadm create-service

Creating service from: pkg:/install-image/solaris-auto-install
OK to use subdir of /export/auto_install/ to store image? [y/N]: y
Download: install-image/solaris-auto-install ...  Done
Install Phase ...  Done
Package State Update Phase ...  Done
Image State Update Phase ...  Done
Reading Existing Index ...  Done
Indexing Packages ...  Done

Creating service: solaris11-i386

Image path: /export/auto_install/solaris11-i386

Refreshing install services

Creating default-i386 alias.

No local DHCP configuration found. 
This service is the default alias for all PXE clients. 
If not already in place, the following should be added to the DHCP configuration:
        Boot server IP       : 192.168.0.11
        Boot file            : default-i386/boot/grub/pxegrub

Refreshing install services

The above message "No local DHCP configuration found..." can be ignored.
One must set /etc/inet/dhcpd4.conf as in ISC-DHCP AI configuration sample.
As per the warning message, the key clauses of  "PXEBoot" class must be set:
  • "filename" (Boot file)
  • "next-server" (Boot server IP)
 
Watch out for multi-homed AI server hosts as they need adjustment.
In such cases it's necessary to define which network AI is to service.
The default is all networks (0.0.0.0) which may cause trouble.
  
$ svcprop -p all_services/networks install/server:default
0.0.0.0/0