How to Configure Aix NIM Server

How to configure Aix NIM Server

Master (NIM Master):

NIM master one and only in a NIM environment it has the permission to run the commands remotely on NIM Clients. The NIM master has all the NIM resources

Client (NIM Client):

NIM Client is nothing but any standalone machine or LPAR in the NIM environment. client use the resources that reside on the NIM master to perform the software maintenance, backup etc..,

SPOT (NIM Spot):

The Shared product Object Tree (SPOT) is a fundamental resource in the NIM environment. A spot provide the /usr file system for disk less data less clients., as well as network boot support for clients.

/usr file system contains user Aix kernel,executable commands,libraries, and applications.

NIM DATABASE:

The NIM database is stored in the AIX Object Data Management (ODM) repository. NIM master is divided into four classes.

1. machines: shows the machines in NIM (master, clients)
2. networks: shows what type of network (topology: ent, Token-Ring… ) can be used
3. resources: shows resource types: mksysb, spot ..

Required File Sets:
1. bos.sysmgt.nim.master
2. bos.sysmgt.nim.spot
3. bos.sysmgt.nim.client

NIM File set Installation:

bash-4.2#installp -acgXYd . bos.sysmgt.nim.client 7.1.3.45
bash-4.2#installp -acgXYd . bos.sysmgt.nim.master 7.1.3.45
bash-4.2#installp -acgXYd . bos.sysmgt.nim.spot 7.1.3.45

Note:

• bos.sysmgt.nim.client not required to install its already installed on our operating system.
• We need to update the NIM files sets to current NIM server oslevel(AIX 7.1.TL9.SP4)

NIM file sets have been successfully installed.

NIM File set Installation

Requirement of Network Services & Protocols:

Verify the inetd network service running status.

inetd network service running status
inetd network service running status

TFTPD (Trivial File Transfer Protocol):

* TFTP is application layer network protocols.
* It is used for restore and recovery purpose.
* Protocol Port number is 67 TCP/UDP.

bash-4.2# grep tftp /etc/services

tftp 69/udp # Trivial File Transfer 
tftp 69/tcp # Trivial File Transfer

Un comment the tftp service line in /etc/intetd.conf file.

bash-4.2# grep tftp /etc/inetd.conf
tftp     dgram  udp6    SRC     nobody  /usr/sbin/tftpd       tftpd -n

BOOTPD:

This is the initial communication made between the NIM master and client during network boot.
bootpd daemon will use the /etc/bootptab configuration file to pass information to the client

bash-4.2# grep bootp /etc/services
bootps                  67/udp         # Bootstrap Protocol Server
bootps                  67/tcp         # Bootstrap Protocol Server

Note:

If the master and client systems are on separate networks, the router must be set to forward bootp packets.

By default bootp and tftp protocol was not allowed two different networks.. so we have to open the ports an Layer 3 network switch.

NIM Server Support Different Networks:

NIM Server Configuration Network Topology
NIM Server Configuration Network Topology

We Have to open Network Port on Network L3 Switch or router.

NIM Server         Protocol                 Direction      NIM Client
192.168.1.1        bootps 67 tcp/udp        <======>       192.168.2.2
192.168.1.1        tftp   69 tcp/udp        <======>       192.168.2.2

Network Router Configuration:

NIM Firewall Port Open
NIM Firewall Port Open

Note: Trace Bootp & Tftp Packets

bash-4.2# tcpdump -i en0 dst 192.168.2.2

From nim server we could use tcpdump utility to saw the bootp and tftp packets at the time of NIM client boot.

Required files and Directories:

You can check if user nobody exist

bash-4.2# grep nobody /etc/passwd
nobody:!:4124967294:4124967294:123/X/*systemadmin//System Admin ID:/:

Create the tftp access control file. It contains the default tftp directory control list.

bash-4.2# cat>/etc/tftpaccess.ctl
# NIM access for network boot
allow:/tftpboot

This file must be have the below permissions.

bash-4.2# chmod 644 /etc/tftpaccess.ctl
bash-4.2# ls -l /etc/tftpaccess.ctl
-rw-r--r--    1 root     system           41 Apr 10 10:17 /etc/tftpaccess.ctl
bash-4.2# ls -ld /tftpboot/
drwxr-xr-x    2 root     system          256 Apr 10 10:22 /tftpboot/

To confirm the tftpd service status if it is running or not.

bash-4.2# lssrc -t tftp
Service       Command              Arguments            Status
tftp         /usr/sbin/tftpd      tftpd -n             active
bash-4.2# ps -ef | grep tftp
root    8454184  3997852       0 12:50:40     -  0:00 /usr/sbin/tftpd -n
nobody  9502768  8454184       0 12:50:40     -  0:00 /usr/sbin/tftpd -n

TFTP protocol Local test connection on NIM master:

We have to test the TFTP functions on NIM server local host.
Step 1: Create one text file on /tftpboot/ directory with 744 permissions.

bash-4.2# cat>/tftpboot/tftp-test.txt
This is tftp test file
bash-4.2# chmod 744 /tftpboot/tftp-test.txt
bash-4.2# ls -l /tftpboot/tftp-test.txt
-rwxr-xr-x    1 root     system           15 Apr 10 10:35 /tftpboot/tftp-test.txt

Step 2: Test the tftp functionality in NIM Sevrer.

bash-4.2# tftp localhost
tftp> get /tftpboot/tftp-test.txt tftp-test.txt
Received 16 Bytes in 0.0 Seconds
tftp> quit

Check the tftp local host status.

tftp local host test
tftp local host test

For store the lpp_source:

Create the file systems for store the NIM Server resources like mksysb,spot,lpp_source etc..,

bash-4.2# mklv -y lpp_source_lv -t jfs2 Nimvg 12
bash-4.2# crfs -v jfs2 -d lpp_source_lv -m /export/lpp_source -A yes -p rw
bash-4.2# mount /export/lpp_source
bash-4.2# chmod 755 /export/lpp_source

For store the OS Spot it contains the aix kernel.

bash-4.2# mklv -y spot_lv -t jfs2 Nimvg 16
bash-4.2# crfs -v jfs2 -d spot_lv -m /export/spot -A yes -p rw
bash-4.2# mount /export/spot
bash-4.2# chmod 755 /export/spot

For store MKSYSB image.

bash-4.2# mklv -y mksysb_lv -t jfs2 Nimvg 16
bash-4.2# crfs -v jfs2 -d mksysb_lv -m /export/mksysb -A yes -p rw
bash-4.2# mount /export/mksysb
bash-4.2# chmod 755 /export/mksysb

Required file system has been successfully created.

bash-4.2# df -gt
/dev/mksysb_lv      4.50      3.62      0.88   81% /export/mksysb
/dev/lpp_source_lv  3.00      0.00      3.00    1% /export/lpp_source
/dev/spot_lv        4.00      0.00      4.00    1% /export/spot

To stop and start the NFS services.

bash-4.2# stopsrc -g nfs
bash-4.2# startsrc -g nfs
bash-4.2# lssrc  -g nfs
NIM Nfs Service
NIM Nfs Service

Create /etc/exports for store the nfs file system information’s. with 644 permissions.

exportfs

Configure NIM Master Environment :

All NIM pre request everything ready, so we have to configure NIM Master Environment.

Step 1: Go to smitty nim
Step 2: Select Configure the NIM Environment then press enter.
Step 3: Select Configure a Basic NIM Environment (Easy Start up) then press enter.
Step 4: Fill the All NIM Master details.

Primary Network Interface for the NIM Master : [en0]--- NIM Server Network Adapter.
Input device for installation images         : [/dev/cd0] – it contains AIX -7100-03-05-1524 imag
                                             (OR)
					     :[/export/mksysb/7100-03-05-1524-mksys ]
LPP_SOURCE Name				     : type the Lpp_source name [AIX- 7100-03-05-LPP]
LPP_SOURCE Directory			     : Insert the Lpp_source directory [/export/lpp_source]
Create new file system for LPP_SOURCE?	     : [no]
SPOT Name                                    : Enter Spot Name.[AIX -7100-03-05-SPOT]
SPOT Directory				     : Choose existing spot directory [/export/spot]
Create new file system for SPOT?	     : [no]

Then Press enter to continue the NIM Master Environment configuration. It will take few minutes and return some warning errors. This is not a major error. Just press ESC+0.

Define Multiple Networks in NIM Server:

Step 1: Go to smitty nim then press enter.
Step 2: Select Perform NIM Administration Tasks then press enter.
Step 3: Select Manage Networks then press enter.
Step 4: Select Define a Network then press enter.
Step 5: Choose the Network Type [ent = ether-net network] then press enter.
Step 6: Type or select values in entry fields.

Network Name       				: [VLAN-101]  
Network Type      				: [ent]
Ethernet Type     				: [Standard]
Network IP Address				: [192.168.1.1]
Sub net mask        		                : [255.255.255.0]
Default Gateway for this Network                : [192.168.1.254]

Then Press enter to continue to configure the NIM 101 VLAN Network Routing. Press ESC+0 exit prom smitty menu.

Step 7: Verify the created NIM Network Routing.

bash-4.2# lsnim -l VLAN-101
VLAN-101:
class         =  networks
type          =  ent
Nstate        =  ready for use
prev_state    =
net_addr      = 192.168.1.0
snm           =  255.255.255.0
routing1      =  default 192.168.1.254

NIM Server Successfully configured. Verify the NIM Master.

bash-4.2# lsnim -l master
class                       =	machines
type                        =	master
max_nimesis_threads         =	20
if_defined         	    =	chrp.64.ent
comments           	    =	machine which controls the NIM environment
platform           	    =	chrp
netboot_kernel     	    =	64
if1                	    =	network1 NIM-LPAR F21E5B0EC10B
cable_type1        	    =	N/A
Cstate                      =	ready for a NIM operation
Mstate			    =	currently running

NIM Master server configuration successfully configured.

Related posts

One Thought to “How to Configure Aix NIM Server”

  1. somnath dhavale

    Very good explaination given……

Leave a Comment