Configuring a NIM client and NIM mksysb image

 

Configuring a server as a client of an existing NIM master

Check that the client has the following filesets installed

# lslpp -l | grep -i nim.client
bos.sysmgt.nim.client      5.3.7.0  COMMITTED  Network Install Manager -
bos.sysmgt.nim.client      5.3.7.0  COMMITTED  Network Install Manager -

Ensure the above filesets are installed and then configure the server as a client of the NIM server by typing the following

smitty eznim

------------------------------------------------------------------------------------------------------------------

		 EZ NIM (Easy NIM Tool)

Move cursor to desired item and press Enter.

  Configure as a NIM Master
  Configure as a NIM Client

------------------------------------------------------------------------------------------------------------------

Select "Configure as a NIM Client"

------------------------------------------------------------------------------------------------------------------

		Configure as a NIM Client

Move cursor to desired item and press Enter.

  Add this system to a NIM environment
  Configure Client Communication Services
  Update this system
  Reinstall this system
  Reset this system
  Show the NIM environment

------------------------------------------------------------------------------------------------------------------

Select "Add this system to a NIM environment"

------------------------------------------------------------------------------------------------------------------

		Easy NIM - Client Configuration

Type or select values in entry fields.
Press Enter AFTER making all desired changes.

                                                   [Entry Fields]
* Machine Name                                  []
* Primary Network Install Interface             []                                                                                                                         
* Host Name of Network Install Master           []

  Hardware Platform Type                         chrp
  Kernel to use for Network Boot                [mp] 

------------------------------------------------------------------------------------------------------------------

Configure the above fields as appropriate and then press return

Check that there is now a /etc/niminfo file on the client, the contents of which should look similar to the following

#cat /etc/niminfo
#------------------ Network Install Manager ---------------
# warning - this file contains NIM configuration information
#       and should only be updated by NIM
export NIM_NAME=client1
export NIM_HOSTNAME=client1
export NIM_CONFIGURATION=standalone
export NIM_MASTER_HOSTNAME=master1
export NIM_MASTER_PORT=1058
export NIM_REGISTRATION_PORT=1059
export NIM_SHELL="shell"
export NIM_BOS_IMAGE=/SPOT/usr/sys/inst.images/installp/ppc/bos
export NIM_BOS_FORMAT=rte
export NIM_HOSTS=" 192.168.0.4:client1  192.168.0.1:master1 "
export NIM_MOUNTS=""

We now need to check that the master can "see" the client. To do this run the following command on the master NIM server.

lsnim -c machines

master1          machines       master
client1     machines       standalone
client2     machines       standalone
client3     machines       standalone
client4     machines       standalone
client5     machines       standalone

In this case we can see the client1 is recognised as a NIM client

To get detailed client information use the following command.

lsnim -l client1

You should get output similar to the following

client1:
   class          = machines
   type           = standalone
   connect        = shell
   comments       = client1
   platform       = chrp
   netboot_kernel = mp
   if1            = network1 client1 00095BBEC8B6 ent1
   net_settings1  = auto auto
   cable_type1    = tp
   Cstate         = ready for a NIM operation
   prev_state     = ready for a NIM operation
   Mstate         = currently running
   cpuid          = 00C7E6DB6C00

At this point some of the fields above may not be set, additional fields can be configured by running the following command on the master NIM server.

smitty nim

------------------------------------------------------------------------------------------------------------------

		Network Installation Management

Move cursor to desired item and press Enter.

  Configure the NIM Environment
  Perform NIM Software Installation and Maintenance Tasks
  Perform NIM Administration Tasks
  Create IPL ROM Emulation Media
  NIM POWER5 Tools
  Thin Server Maintenance

------------------------------------------------------------------------------------------------------------------

Select "Perform NIM Administration Tasks"

------------------------------------------------------------------------------------------------------------------

		Perform NIM Administration Tasks

Move cursor to desired item and press Enter.

  Manage Networks
  Manage Machines
  Manage Resources
  Manage Groups
  Backup/Restore the NIM Database
  Configure NIM Environment Options
  Rebuild the niminfo File on the Master
  Change the Master's Primary Interface
  Manage Alternate Master Environment
  Unconfigure NIM

------------------------------------------------------------------------------------------------------------------

Select "Manage Machines"

------------------------------------------------------------------------------------------------------------------

		 Manage Machines 
Move cursor to desired item and press Enter.

  List All Machines
  Define a Machine
  Change/Show Characteristics of a Machine
  Specify New Master for Client Machine
  Remove a Machine
  Manage Network Install Interfaces
  Manage Network Install Resource Allocation
  Perform Operations on Machines
  Query Remote Machine
  Manage Secondary Adapter Definition Files

------------------------------------------------------------------------------------------------------------------

Select "Change/Show Characteristics of a Machine"

Choose the server

------------------------------------------------------------------------------------------------------------------

		Change/Show Characteristics of a Machine

Type or select values in entry fields.
Press Enter AFTER making all desired changes.

                                                        [Entry Fields]
  Machine Name                                       [client1]
* Hardware Platform Type                             [chrp]                                                                                                                        
* Kernel to use for Network Boot                     [mp]                                                                                                                          
  Machine Type                                        standalone
  Network Install Machine State                       currently running
  Network Install Control State                       ready for a NIM operation
  Primary Network Install Interface
    Network Name                                      network1
    Host Name                                        [client1v2]
    Network Adapter Hardware Address                 [00095BBEC8B6]
    Network Adapter Logical Device Name              [ent1]
    Cable Type                                        tp                                                                                                                           
    Network Speed Setting                            [auto]                                                                                                                        
    Network Duplex Setting                           [auto]                                                                                                                        
  IPL ROM Emulation Device                           []                                                                                                                            
  CPU Id                                             [00C7E6DB6C00]
  Communication Protocol used by client              [shell]                                                                                                                       
  NFS Client Reserved Ports                          []                                                                                                                            
  Comments                                           [client1]

  Force                                               no    

------------------------------------------------------------------------------------------------------------------

Any additional fields can be configured from this screen.

If you need to determine the CPU ID then use the following command.

uname -m

 

Creating a NIM mksysb resource

The mksysb resource is a file containing the image of the root volume group (generated with the AIX mksysb command) of a machine. It is used to restore a machine, or to install it from scratch (also known as “cloning” a client). A mksysb resource can be defined by first creating the mksysb image with SMIT or the mksysb command, and then using SMIT defining the resource that references the backup image file.

A mksysb resource can also be defined using CLI as follows:

nim -o define -t mksysb -a source=<client_to_backup> -a server=master -a location=<location to store file> RESOURCE_NAME

To create the mksysb image of the client at the same time as defining a mksysb resource type:

nim -o define -t mksysb -a source=client1 -a server=master -a mk_image=yes -a location=/export/mksysb_clients/client1/client1.mksysb client1_image

 

Creating server groups with additional spot resources

Group servers by functionality in server groups. All servers in one group can then share a spot resource.

Creation of the server group

nim -o define -t mac_group -a add_member=oraprod1 -a comments="The spot for this group is Oracle_prod_spot" Oracle_prod_group

Add additional members to the group

nim -o change -a add_member=oraprod2 Oracle_prod_group

List the attributes of the group

lsnim -l Oracle_prod_group

Oracle_prod_group:
   class    = groups
   type     = mac_group
   comments = The spot for this group is Oracle_prod_spot
   member1  = oraprod1
   member2  = oraprod2

Next create spot resources form a mksysb image of one of the servers in the group.

nim -o define -t spot -a source=oraprod1_image -a server=master -a location=/export/spot Oracle_prod_spot

List the attributes of the spot

lsnim -l Oracle_prod_spot

Oracle_prod_spot:
   class         = resources
   type          = spot
   plat_defined  = chrp
   arch          = power
   Rstate        = ready for use
   prev_state    = verification is being performed
   location      = /export/spot/Oracle_prod_spot/usr
   version       = 5
   release       = 3
   mod           = 7
   oslevel_r     = 5300-07
   alloc_count   = 0
   server        = master
   if_supported  = chrp.mp ent
   Rstate_result = success
   mksysb_source = oraprod1_image