Professional Documents
Culture Documents
permission to run
the NIM resources. A
client of any other
than the client.
NIM performs network installs by using a client/server model based on the bootp/tftp
protocols for receiving a network boot image.
1. config for netboot
Configure client to be booted from master. Then reboot client and in SMS choose
network boot.
2. /etc/bootptab
When a NIM client is configured to be booted from the NIM Master, client requests
info from server about the boot image.
The bootpd daemon will use the /etc/bootptab configuration file to pass
information to the client (server, gateway IP...).
tail /etc/bootptab
aix21.domain.com:bf=/tftpboot/aix21.domain.com:ip=10.200.50.50:ht=ethernet:sa=50.20.
100.48:gw=10.200.50.1:sm=255.255.255.0:
3. /tftpboot
After client receives bootp reply, next step is transferring the boot image to
the client. It is achieved with the help of tftp.
root@aixnim1: /etc # ls -l /tftpboot
lrwxrwxrwx
1 root
system
34 Dec 19 18:36 aix21.domain.com ->
/tftpboot/spot_5200-08.chrp.mp.ent
-rw-r--r-1 root
system
1276 Dec 19 18:36 aix21.domain.com.info
...
-rw-r--r-1 root
system
9260943 Dec 8 15:31 spot_520008.chrp.mp.ent
(this contains the boot image (kernel), what the client is using, until it can
NFS mount the SPOT )
Once the boot image is obtained, the client requests (using tftp) a configuration
file (.info).
This contains info about which server contains the install image and other
necessary install resources.
4.-5.-6. NFS mount of resources
After the boot image is loaded into memory at the client, the SPOT and other
resources are NFS mounted in the client's RAM file system.
SPOT consists of filesets (device drivers, BOS install programs) what is used
during boot.
After install finished:
Upon completion of install, the client sends state information to the master via
'nimclient' calls to the master's nimesis daemon.
The NIM master then deallocates all install resources from the client.
The deallocation process consists of:
- Removing files from tftp directory
- Remove file entry in /etc/bootptab
- Unexporting nfs resources from client (remove entries from /etc/exports)
- Updating client information in the NIM database (machine state)
----------------------SERVER SIDE (PUSH) INSTALL:
For new installations and mksysb restores:
1. install NIM filesets
bos.sysmgt.nim.master
bos.sysmgt.nim.spot
2. configure machine as NIM master
smitty nimconfig
(Netw. name and Primary Netw. Install Interface should be set)
3. Define lpp_source
smitty nim_mkres -> choose lpp_source
(Server of Resource : master, and the others...)
4. After lpp_source, define SPOT
smitty nim_mkres -> choose spot
(Server of Resource: master, and the others...)
5. After the 2 basic resources defined, add the first NIM client
smitty nim_mkmac
6. start AIX installation to the client
IN SMITTY:
smitty nim_task_inst -> select install
(install method should be rte, and SPOT and LPP (what we created above))
(if mksysb restore, then mksysb)
Select:
Accept new license agreements -> yes
Initiate reboot and installation now -> no (this should be done manually,
because it is the first time installation)
IN COMMAND LINE:
1.allocate sopt and lpp_source to the client:
nim -o allocate -a spot=spot_5300-05 -a lpp_source=5300-05 aix21
2.initiate the install (it will set the bootlist to network boot on the client
and then reboot the client)
nim -o bos_inst -a source=rte -a installp_flags=agX -a accept_licenses=yes aix21
(a:apply, g:install prereqs, X:expand filesystems)
7. Additional checks before installation
- verify that the correct entry has been added in the /etc/bootptab file:
tail /etc/bootptab -> itt will show a line with the name of the host and
other settings
- verify that boot files have been created in the /tftpboot directory
a symbolic link with the hostname (this is a link to the boot image
(kernel))
a <client name>.info file, which is used to set variables during
installation
- lsnim -l <hostname> -> Cstate will be changed from "ready" to "enabled"
- showmount -e -> it should show what is exported to the system
(it is a <hostname>.script file, where you can see some details: ip...)
8. Start client installation
power on the client -> go into SMS menu
- 2. Setup Remote IPL -> select the desired adapter
- 1. IP parameters -> then if needed Client/Server/Gateway IP Address and Subnet
Mask can be set
**VERY IMPORTANT**
If master and client are on the SAME subnet, and ping does not work with given
gateway, then set Gateway IP to NIM masters ip address!!
There were a few firmware levels that made you use 0.0.0.0 if the master and
client were on the same network.
- then go back (ESC) to do a Ping Test (1. Execute Ping Test)
- then go back to the main menu (M) -> 5. Select Boot Options -> 1. Select
Install/Boot device -> 6. Network
- select the needed adapter -> 2. Normal Mode Boot -> 1. Yes
(later need to be chosen: language, disk to be installed on (mksysb: 2 disks are
needed, lpp_source: 1 disk is needed only))
9. Redo checks - and during install:
-/etc/bootptab -> no longer contains a specific line
-/tftpboot -> no longer contains the link
-lsnim -l <hostname> -> Cstate must be set back to "ready for nim op."
-nim -o showlog -a log_type=boot aix21
If install unsuccessful:
nim -Fo reset aix21
nim -Fo deallocate -a subclass=all aix21
----------------------AT CLIENT SIDE (PULL):
BOS installation from the client:
1. lpp_source and SPOT allocated first to the client
nimclient -o allocate -a lpp_source=LPP_53_ML4 -a spot=SPOT_53_ML4
2. starting BOS installation
nimclient -o bos_inst -a accept_license=yes
OS Update from the client:
Performing an update_all (cust) operation from the client:
nimclient -o cust -a lpp_source=lpp5305 -a fixes=update_all
----------------------Debugging an installation
If there are problems during BOS install, you can use 911.
Type: 911 at this screen, and it will turn on debug mode, which will show many
additional info during install.
-----------------------------------/ETC/NIMINFO:
This file always exist on the NIM master and mostly will exist on a NIM client.
This file is a text file and contains hostname information for the client, tells
the client who its master is, communication port and protocol informations. This
file should not be edited manually. If there is incorrect information in the
file, it should be removed and recreated.
rebuild /etc/nimifo of NIM master:
on NIM master: nimconfig -r
rebuild /etc/niminfo of NIM client:
on NIM master: smitty nim -> perf. nim adm. -> manage machines -> specify new
master
(select client, then NIM master (if already used master name is used, it
rebuilds /etc/niminfo on client))
on NIM client: niminit -a master=<MASTER_HOSTNAME> -a name=<CLIENT_NIM_NAME>
(niminit -a master=aixnim01 -a name=aix01 -a connect=nimsh (it will use nimsh,
deafult is rsh))
(niminit -av name=aix31 -a master=aixnim1.domain.com -a master_port=1058 (-v:
verbose mode))
-----------------------------------Commands on Master:
/var/adm/ras
files
/var/adm/ras/nimsh.log
log of nimsh (connection problem with client
can be checked here)
/var/adm/ras/nimlog
general nimlog file, can be view: alog -f
/var/adm/ras/nimlog -o (shows failed NIM operations)
lsnim
shows the classes of the NIM database:
machines, networks ... (it is stored in the ODM)
lsnim -c machines
lists this class elements: machines,
networks, resources
lsnim -t <type>
lists the resources of that type (spot,
lpp_source, mksysb, standalone...) (e.g. lsnim -t spot)
lsnim -l <resource>
shows the attributes of the resource (e.g.
lsnim -l spot_5300_09)
lsnim -O <resource>
shows valid nim operations for that resource
(remove, change...)(e.g: lsnim -O lpp5300)
nim -o check <resource>
<rewsource>)
2. reset the client state: (it will reset the Cstate/Rstate of a resource to
"ready for use")
-nim -Fo reset <client>
3. deallocate the given resources:
-nim -o deallocate -a spot=<spot> <client>
(nim -Fo deallocate -a subclass=all <client>)
-----------------------------------Preparing a system for maintenance (network) boot:
# nim -Fo reset <client>
<--reset the state of the
client (if it was not "ready for NIM operations")
# nim -o deallocate -a subclass=all <client>
<--deallocates all
resources from client (if lpp_source/spot was allocated to it before)
# nim -o maint_boot -a spot=spot_5300-11-04 <client> <--prepares the system for
network boot
(after boot if needed later, you can do reset and deallocate again)
-----------------------------------SOME CHECKS FOR COMMON PROBLEMS:
ON MASTER:
- check the communication between nim master and client: nim -o lslpp <nim
client>
- check if there are allocations to the client: lsnim -a spot ... (reset client,
deallocate resource)
ON CLIENT:
- if rsh is used:
-check correct connection (for connecttion refused error: inetd.conf,
.rhosts file)
-check if firewall is blocking communication (telnet to rsh ports)
- if nimsh is used:
-check nimsh log: /var/adm/ras/nimsh.log
-check if nimsh is running: lssrc -s nimsh (restart can help: stopsrc -s
nimsh; startsrc -s nimsh)
-check /etc/niminfo file (if there is invalid entry, correct on master and
recreate /etc/niminfo)
- for authentication (cpuid) problems in the log:
-diskless, dataless: these needs certain resouces (I have never seen clients
with this type)
Settings/attributes of a NIM client can be cheked on NIM master: lsnim -l
<client>
# lsnim -l aix31
aix31:
class
type
comments
connect
platform
netboot_kernel
if1
...
=
=
=
=
=
=
=
machines
standalone
autosysb:
shell
chrp
mp
VLAN448_Admin_10_200_30_0 aix31 0 ent1
[aix222]
<--any
<--we
<--twisted
<--checked
<--same as
<--set
<--set
(If you created earlier a network for this new client (what is recommended),
network settingswill be filled automatically.)
--------------------------
LPP SOURCE
LPP_SOURCE:
An lpp_source is a directory similar to AIX install CDs. It contains AIX Licensed Program Products (LLPs) in Backup
File Format (BFF) format and RPM Package Manager (RPM) filesets that you can install.
3. Updating the base level lpp_source (in point 1 named as lpp5304) with TL update lpp_source (TL5304)
-updating base level lpp_source from a TL directory
nim -o update -a show_progress=yes -a packages=all -a source=TL5304 lpp5304
(source:downloaded update lpp_source; lpp5304:the base lpp_source what we wanted to update with the downloaded
update lpp_source)
-checking and removing duplicate filesets
nim -o lppmgr TL5304
---------------------Creating a NIM lpp source + TL update (with SMITTY)
(An lpp_source from TL6 SP6 DVD image will be updated by TL7 SP3 filesets downloaded from FixCentral)
1. I copied 2 AIX DVDs into 1 directory:
cp -prh /iso/installp/ppc/* /nim/lppsource/TL6_SP6_base
(for both DVDs)
2. lpp_source creation
smitty nim -> nim administration -> manage resouces -> define a resource (lpp_source)
Resource Name
Resource Type
Server of Resource
Location of Resource
[TL6_SP6_base]
lpp_source
[master]
[/nim/lppsource/TL6_SP6_base]
warning: 0042-267 c_mk_lpp_source: The defined lpp_source does not have the
"simages" attribute because one or more of the following packages are missing:
bos
bos.net
bos.diag
...
(it is OK, we do not need simages=yes, because it is only a TL update lpp_source not a base install)
(removed duplicate (superseded) as in step 3)
6. Update TL6_SP6_base with TL7_SP3_update
smitty nim -> nim administration -> manage resouces -> perform operations (base what we want tu update -> update
TARGET lpp_source
SOURCE of Software to Add
SOFTWARE Packages to Add
TL6_SP6_base
TL7_SP3_update
[all]
3. NFS mount
NIM client must be able to perform NFS mounts and read/write operations.
4. multibos
The nimadm command is not supported with the multibos command when there is a bos_hd5 logical volume.
5. lv names
lv names must not be longer than 11 characters (because they will get an alt_ prefix during migration, and AIX
limitaion is 15 characters for an lv).
6. TCB (Trusted Computing Base is a security feature which periodically checks the integrity of the system.)
If you use disk caching option (-j flag) it does not matter if TCB is turned on or off (usually it is not turned on)
However if you omit "-j" flag (NFS read/write) TCB should be turned off. (TCB needs to access file metadata which
is not visible over NFS).
Command to check if TCB is enabled/disabled: odmget -q attribute=TCB_STATE PdAt
7. ncargs (Specifies the maximum allowable size of the ARG/ENV list when running exec() subroutines.)
This is a bug: if ncargs is customized to a value less than 256, it resets all other sys0 attributes to default value.
So make sure ncargs value is at least on 256: lsattr -El sys0 -a ncargs (chdev -l sys0 -a ncargs='256' )
root
14811364
1 0 12:21:19 pts/2 0:06 /usr/java5/jre/bin/java
-Dderby.system.home=/usr/ibm/common/acsi/repos -Xrs -Djava.library.path=...
This process is some System Director stuff, so if you don't have that you can get rid of it.
Workaround:
After resterting nimadm migration, I monitored these filesystems. (fuser -cux <fs_name>)
Around 70% of the installation, this process popped up. I waited install goes about 90% and I did "kill <pid>".
After this nimadm was successful.
SPOT
SPOT:
Essentially the SPOT is a /usr filesystem just like the one on your NIM master. Everything that a machine requires in
a /usr file system, such as the AIX kernel, executable commands, libraries, and applications are included in the SPOT.
During client install client needs to run commands (mkvg, mklv..), these commands are availabe in the SPOT.
During the installation, the client machine NFS mounts this resource in order to access the code needed for the
installation process. Device drivers, the BOS install program, and other necessary code needed to perform a base
operating system installation are found inside the SPOT.
SPOT is responsible for
- Creating a boot image to send to the client machine over the network.
- Running the commands needed to install the NIM client.
You can think of it as having multiple "mini-systems" on your NIM master, because each SPOT is its own /usr
filesystem. You can upgrade it, add fixes to it, use it to boot a client system....etc.
You can also create a SPOT from a NIM mksysb resource. This SPOT however is not as versatile as one created from
an lpp_source and can not be upgraded with any fixes and can only be used with the mksysb resource it was created
from.
When a SPOT is created, network boot images are constructed in the /tftpboot directory using code from the newly
created SPOT. When a client performs a network boot, it uses tftp to obtain a boot image from the server. After the boot
image is loaded into memory at the client, the SPOT is mounted in the client's RAM file system to provide all
additional software support required to complete the operation.
root@aixnim1: / # lsnim -l spot_5300_09
spot_5300_09:
class
= resources
type
= spot
plat_defined = chrp
Rstate
= ready for use
prev_state = ready for use
location
= /nim/spot/spot_5300_09/usr
...
operations:
reset
= reset an object's NIM state
cust
= perform software customization
showres = show contents of a resource
maint
= perform software maintenance
lslpp
= list LPP information about an object
fix_query = perform queries on installed fixes
showlog = display a log in the NIM environment
check = check the status of a NIM object
lppchk = verify installed filesets
update_all = update all currently installed filesets
creating a SPOT (only the top directory should be specified, the SPOT directory will be created automatically):
nim -o define -t spot -a server=master -a location=/nim/spot -a source=5300-09-03 -a installp_flags=-aQg
spot_5300-09-03
resetting a SPOT (if an operation failed, with this the resource state (Rstate) will be updated, and SPOT is ready to use):
nim -Fo reset spot_5300-09-03
preferable however to run a force check on the SPOT instead:
checking a SPOT (verifies the usability of a SPOT, and rebuild network boot image if necessary and change its state to
"ready for use"):
nim -Fo check spot_5300-09-03
checking the contents of the spot (verifies that software was installed successfully on a spot resource):
nim -o lppchk -a show_progress=yes spot_5200_08
Creating a SPOT from an mksysb (created spot can be used only for this mksysb):
smitty nim_mkres -> spot -> enter the values needed (the Source of Install Image should be the mksysb)
checking if a SPOT contains a fileset:
nim -o showres 'spot_5300-11-04_bb1' | grep bos.alt_disk_install.rte
nim -o lslpp -a filesets="bos.alt_disk_install.rte" spot_5300-11-04_bb1
checking a SPOT level (similar to instfix -i | grep ML):
root@aixnim1: / # nim -o fix_query spot_5200-08 | grep ML
All filesets for 5.2.0.0_AIX_ML were found.
All filesets for 5200-01_AIX_ML were found.
All filesets for 5200-02_AIX_ML were found.
update a spot with an lpp_source:
nim -o cust -a fixes=update_all -a lpp_source=5305_lpp 5305_spot
SPOT is an installed entity, like any other AIX system, so it can run into cases where it has broken filesets, broken
links, or missing/corrupt files. They are also fixed in the same manner as you would on any other system:
nim -o lppchk -a lppchk_flags="v" 5305_spot <--use the "Force Overwrite" or "Force Reinstall" options for -v
errors
nim -o lppchk -a lppchk_flags="l" 5305_spot <--using the "-ul" flags for missing links from "-l" errors
nim -o lppchk -a lppchk_flags="c" 5305_spot <--replacing bad files for any "-c" output
---------------------------------Spot creation with SMITTY:
smitty nim -> perform nim administration -> manage resources -> define a resource (spot)
Resource Name
Resource Type
Server of Resource
Source of Install Images
Location of Resource
...
COMMIT software updates?
[spot_TL7_SP3]
spot
[master]
[TL7_SP3]
[/nim/spots]
yes
spot_TL7_SP3
TL7_SP3
[+ 6.1.7.2 Alt. Disk Inst. Runt.] <--after F4 -> bos.alt_disk_install.rte with F7
[yes]
[no]