[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]

Commands Reference, Volume 4


nim Command

Purpose

Performs operations on Network Installation Management (NIM) objects.

Syntax

nim { -o Operation} [ -F ] [ -t Type ] [ -a Attribute=Value . . . ] {ObjectName}

Description

The nim command performs an operation on a NIM object. The type of operation performed is dependent on the type of object specified by the ObjectName parameter. Possible operations include initializing environments and managing resources. You can use the lsnim command to display the list of supported operations.

Flags


-a Attribute = Value . . . Assigns the specified value to the specified attribute. Use the lsnim -q Operation -t Type command to get a list of valid attributes for a specific operation.
-F Overrides some safety checks.
-o Operation Specifies an operation to perform on a NIM object. The possible operations are:

allocate
Allocates a resource for use.

bos_inst
Performs a BOS installation.

change
Changes an object's attributes.

check
Checks the status of a NIM object.

cust
Performs software customization.

deallocate
Deallocates a resource.

define
Defines an object.

diag
Enables a machine to boot a diagnostic image.

dkls_init
Initializes a diskless machine's environment.

dtls_init
Initializes a dataless machine's environment.

fix_query
Lists the fix information for a given APAR or keyword.

lppchk
Verifies installed filesets on NIM machines and SPOTs

lslpp
Lists licensed program information about an object.

maint
Performs software maintenance.

remove
Removes an object.

reset
Resets an object's NIM state.

sync_roots
Synchronizes root directories for diskless and dataless clients for a specific Shared Product Object Tree (SPOT).

unconfig
Unconfigures the NIM master fileset.

AIX 4.2 or later Examples:

maint_boot
Enables a machine to boot in maintenance mode.

showlog
Displays a NIM client's installation, boot or customization log, or a SPOT's installation log from the NIM master.

showres
Displays the contents of a NIM resource.

Use the lsnim -POt Type command to get a list of the valid operations for a specific type.

AIX 4.3 or later Operations:

alt_disk_install
Performs an alternate disk installation.
-t Type Specifies the type of the NIM object for define operations. The possible types are:

resource types:

bosinst_data
Config file used during base system installation.

dump
Parent directory for client dump files.

fix_bundle
Fix (keyword) input file for the cust or fix_query operation.

home
Parent directory for client /home directories.

image_data
Config file used during base system installation.

installp_bundle
Installp bundle file.

lpp_source
Source device for optional product images.

mksysb
mksysb image.

paging
Parent directory for client paging files.

root
Parent directory for client / (root) directories.

script
Executable file which is run on a client.

shared_home
/home directory shared by clients.

spot
Shared Product Object Tree (SPOT) - equivalent to /usr file system.

tmp
Parent directory for client /tmp directories.

AIX 4.2 or later Resource Types:

exclude_files
Contains files to be excluded from a mksysb image. This resource applies only to AIX 4.2 or later.

resolv_conf
Name-server configuration file. This resource applies only to AIX 4.2 or later.

machine types:

diskless
All file systems and resources remote.

dataless
Local paging,dump; remote /,/usr; others remote or local.

standalone
Local file systems and resources.

master
Machine that controls the NIM environment.
-t Type (Continued)

network types:

tok
Token-Ring network.

ent
Ethernet network.

fddi
FDDI network.

atm
ATM network. (AIX 4.3 or later.)

generic
Other TCP/IP networks.

AIX 4.2 or later only:

group types:

mac_group
Group of machines. This type applies only to AIX 4.2 or later.

res_group
Group of resources. This type applies only to AIX 4.2 or later.

Security

Access Control: You must have root authority to run the nim command.

Examples

The following examples are grouped by operation.

define

  1. To define an rspc uniprocessor dataless machine on the token-ring network called net1 and call it altoid, type:

    nim -o define -t dataless -a if1="net1 fred 10005aa88500" \
    -a ring_speed=16 -a platform=rspc -a netboot_kernel=up \
    -a comments="Dataless client altoid"
    

    The comments attribute is optional and may contain any user-entered notes.

    Note: The if1 attribute is required.
  2. To define a resource that is a directory containing installable images that is located on server altoid and has a path name of /usr/sys/inst.images, and name that resource images, type:

    nim -o define -t lpp_source -a server=altoid \
    -a location=/usr/sys/inst.images images
    
  3. To create a new SPOT resource named myspot on the NIM master in the /export/exec directory, using an lpp_source named images, type:

    nim -o define -t spot -a server=master -a location=/export/exec \
    -a source=images myspot
    
  4. To define a network object named BLDG905, with a subnetmask of 255.255.240.0 and an address of 129.35.129.0, type:

    nim -o define -t tok -a snm=255.255.240.0 \
    -a net_addr=129.35.129.0 BLDG905
    
  5. To define an lpp_source, lppsrc1, that will be located on the master from a tape selecting a specific set of software products that are on the tape, bos.INed and bos.adt, type:

    nim -o define -t lpp_source -a location=/images2/lppsrc1 \
    -a source=/dev/rmt0 -a server=master -a packages="bos.INed \
    bos.adt" lppsrc1
    
  6. To define a standalone machine that is a Symmetrical Multi-Processor model which has a BOOTP-enabled IPL ROM, its hostname is jupiter and it will also be known as jupiter in the NIM environment, using a token-ring network called net1 and a ring speed of 16, type:

    nim -o define -t standalone -a if1="net1 jupiter 0" \
    -a ring_speed=16 -a platform=rs6ksmp jupiter
    
  7. To define a mksysb resource, mksysb1, from an existing mksysb image located in /resources/mksysb.image on the master, type:

    nim -o define -t mksysb -a server=master \
    -a location=/resources/mksysb.image mksysb1
    
  8. To define a NIM network named ATMnet with a subnet mask of 255.255.240 and an address of 129.35.101.0 to represent an ATM network, use the generic network type as follows:

    nim -o define -t generic -a snm=255.255.240.0 \
    -a net.addr=129.35.101.0 ATMnet
    
  9. To define a PowerPC PCI bus-based, symmetric multiprocessor computer whose hostname is bluefish as a standalone machine on a token ring network called net1 and have the machine be known to the NIM environment as bluefish, enter:

    nim -o define -t standalone -a platform=rspcsmp \
    -a if1="net1 bluefish 0" -a ring_speed=16 bluefish
    

remove

To remove a resource named dump_files, type:

nim -o remove dump_files

change

Machines on the BLDG905 network use the gateway905 gateway to reach the OZ network. Machines on the OZ network use the gatewayOZ gateway to reach the BLDG905 network. To add a route between two networks named BLDG905 and OZ, type:

nim -o change -a routing1="OZ gateway905 gatewayOZ" BLDG905

check

  1. To have NIM check on the usability of a SPOT named myspot, type:

    nim -o check myspot
    
  2. To check the status of an lpp_source named images, type:

    nim -o check images
    

allocate

  1. To allocate resources to a diskless workstation with the name of syzygy and SPOT attribute value of spot1 ,enter:

    nim -o allocate -a spot=spot1 syzygy
    
  2. To perform a base system installation on the machine named krakatoa, resources must first be allocated by entering:

    nim -o allocate -a spot=myspot -a lpp_source=images krakatoa
    

    Then the NIM environment can be initialized to support the install by performing the bos_inst operation, type:

    nim -o bos_inst krakatoa
    
  3. To install the software product, adt, into a standalone machine, stand1, given that the installable option, adt, resides in the lpp_source, images, type:

    nim -o allocate -a lpp_source=images stand1
    

    Then enter:

    nim -o cust -a filesets="adt" stand1
    
  4. To install software products into a standalone machine, stand1, such that the image for the installable option, adt, resides in the lpp_source, images, and the installp_bundle, bundle1, contains the name of the installable option, type:

    nim -o allocate -a lpp_source=images \
    -a installp_bundle=bundle1 stand1
    

    Then enter:

    nim -o cust stand1
    

deallocate

To deallocate an lpp_source named images from the standalone machine client1, type:

nim -o deallocate -a lpp_source=images client1

bos_inst

To install the machine blowfish, using the resources spot1, images1, bosinst_data1, and rconf1, first allocate the resources by entering:

nim -o allocate -a spot=spot1 -a lpp_source=images1 \
-a bosinst_data=bosinst_data1 -a resolv_conf=rconf1 blowfish

Then, perform the BOS installation by entering:

nim -o bos_inst blowfish

cust

  1. To install a software product into a spot, spot1, such that the image for the installable option, adt, resides in the lpp_source, images, type:

    nim -o cust -a lpp_source=images -a filesets=adt spot1
    
  2. To install a software product into a spot, spot1, such that the image for the installable option, adt, resides in the lpp_source, images, and the installp_bundle, bundle1, contains the name of the installable option, type:

    nim -o cust -a lpp_source=images -a installp_bundle=bundle1 spot1
    
  3. To install a software product into a spot, spot1, such that the image for the installable option, adt, resides on a tape that is in the tape drive that is local to the machine where the spot resides, type:

    nim -o cust -a lpp_source=/dev/rmt0 -a filesets=adt spot1
    
  4. To install a software product into a spot, spot1, such that the image for the installable option, adt, resides on a tape that is in the tape drive that is local to the machine where the spot resides, type:

    nim -o cust -a lpp_source=/dev/rmt0 -a filesets=adt spot1
    
  5. To install all fileset updates associated with APAR IX12345, residing on the tape /dev/rmt0 into spot1 and any diskless or dataless clients to which spot1 is currently allocated, type:

    nim -F -o cust -afixes=IX12345 -a lpp_source=/dev/rmt0 spot1
    
  6. To update all software installed on the client Standalone1, with the latest updates in the lpp_source named updt_images, type:

    nim -o allocate -a lpp_source=updt_images Standalone1
    nim -o cust -afixes=update_all Standalone1
    
  7. To install the machine catfish with the contents of the installp_bundle bundle1, first allocate the resources by entering:

    nim -o allocate -a installp_bundle=bundle1 \
    -a lpp_source=images1 catfish
    

    Then, perform the cust operation by entering:

    nim -o cust catfish
    

maint

  1. To deinstall the software products bos.INed and adt from a spot, spot1, type:

    nim -o maint -a installp_flags="-u" \
    -a filesets="bos.INed adt" spot1
    
  2. To deinstall the options bos.INed and adt from a spot, spot1, such that the installp_bundle, bundle2, contains the names of the installable options, type:

    nim -o maint -a installp_flags="-u" \
    -a installp_bundle=bundle2 spot1
    
  3. To cleanup from an interrupted software installation on a spot, spot1, type:

    nim -o maint -a installp_flags="-C" spot1
    
  4. From the master, to deinstall the software products bos.INed and adt from a standalone machine, stand1, type:

    nim -o maint -a installp_flags="-u" \
    -a filesets="bos.INed adt" stand1
    
  5. From the master, to clean up from an interrupted software installation on a standalone machine, stand1, type:

    nim -o maint -a installp_flags="-C" stand1
    

dkls_init

To initialize the environment for a diskless workstation with the name of syzygy, using the resources spot1, root1, dump1, and paging1, first allocate the resources by entering:

nim -o allocate -a spot=spot1 -a root=root1 -a dump=dump1 \
-a paging=paging1 syzygy

Then initialize the resources for the client machine by entering:

nim -o dkls_init syzygy

dtls_init

To initialize the environment for a dataless workstation with the name of syzygy, using the resources spot1, root1, and dump1, first allocate the resources by entering:

nim -o allocate -a spot=spot1 -a root=root1 -a dump=dump1 syzygy

Then initialize the resources for the client machine by entering:

nim -o dtls_init syzygy

fix_query

To list information about fixes installed on client Standalone1 for 20 APAR numbers, create the file /tmp/apar.list with one APAR number per line, as shown:

IX123435
IX54321
IX99999
...

then enter:

nim -o define -t fix_bundle -alocation=/tmp/apar.list \
                 -aserver=master fix_bun
nim -o allocate -a fix_bundle=fix_bun Standalone1
nim -o fix_query Standalone1

lppchk

To check fileset version and requisite consistency on the SPOT spot1, type:

nim -o lppchk spot1

AIX 4.2 or later Examples

allocate

  1. To automatically configure a machine with name resolution services after a BOS installation, create the file /exports/resolv.conf, with contents similar to the following:

    nameserver      129.35.143.253
    nameserver      9.3.199.2
    domain          austin.ibm.com
    

    then enter:

    nim -o define -t resolv_conf -a location=/exports/resolv.conf \
    -a server=master rconf1
    

    Prior to issuing the bos_inst operation, allocate this resource with other required and optional resources by entering:

    nim -o allocate -a spot=spot1 -a lpp_source=images1 \
    -a bosinst_data=bid1 -a resolv_conf=rconf1 client1
    
  2. To allocate all resources applicable to standalone machines from the NIM resource group res_grp1, to the machine mac1, type:

    nim -o allocate -a group=res_grp1 mac1
    

bos_inst

  1. To install the machine blowfish while allocating the resources spot1, images1, bosinst_data1, and rconf1 automatically when the bos_inst operation starts, type:

    nim -o bos_inst -a spot=spot1 -a lpp_source=images1 \
    -a bosinst_data=bosinst_data1 -a resolv_conf=rconf1 blowfish
    
  2. To use the default resources when installing the machine mac1, type:

    nim -o bos_inst mac1
    

change

  1. The adapter identified by the host name sailfish2.austin.ibm.com is attached to a token ring network. To define a secondary interface for this adapter on the NIM master and instructing NIM to locate the NIM network representing the attached ethernet network and, if not found, have NIM define a NIM network with subnetmask 255.255.255.128, type:

    nim -o change -a if2="find_net sailfish2.austin.ibm.com 0" \
    -a net_definition="tok 255.255.255.128" -a ring_speed2=16 master
    

    Note: A default name is generated for the network, and no routing information is specified for the new network.
  2. To define default routes for the networks net1 and net2 which use default gateways gw1 and gw2 respectively, enter the following two commands:

    nim -o change -a routing1="default gw1" net1
    nim -o change -a routing1="default gw2" net2
    
  3. To designate the resources defined by the resource group res_grp1 as the set of resources always allocated by default during any operation in which these resources are applicable, type:

    nim -o change -a default_res=res_grp1 master
    

cust

  1. To update all software installed on the client Standalone1, with the latest updates in the lpp_source named updt_images, type:

    nim -o cust -a lpp_source=updt_images -a fixes=update_all \
    Standalone1
    
  2. To install the machine catfish with the contents of the installp_bundle bundle1, while allocating this resource and the lpp_source images1 when the cust operation runs, type:

    nim -o cust -a installp_bundle=bundle1 -a lpp_source=images1 \
    catfish
    

define

  1. To define a machine group named DisklsMacs1 with members that are NIM diskless machines named diskls1, diskls2, and diskls3, type:

    nim -o define -t mac_group -a add_member=diskls1 \
    -a add_member=diskls2 -a add_member=diskls3 DisklsMacs1
    
  2. To define a resource group named DisklsRes1 with resources spot1, root1, dump1, paging1, home1, tmp1, type:

    nim -o define -t res_group -a spot=spot1 -a root=root1 \
    -a dump=dump1 -a paging=paging1 -a home=home1 -a tmp=tmp1 \
    DisklsRes1
    
  3. To display the space required to define a mksysb resource, mksysb2, and create a mksysb image of the client, client1, during the resource definition where the image will be located in /resources/mksysb.image on the master, type:

    Note: This action only shows the space required for the operation, mksysb or resource creation does NOT take place.

    nim -o define -t mksysb -a server=master \
    -a location=/resources/mksysb.image -a source=client1 \
    -a mk_image=yes -a size_preview=yes mksysb2
    
  4. To define a mksysb resource, mksysb2, and create the mksysb image of the client, client1, during the resource definition where the image will be located in /resources/mksysb.image on the master, type:

    nim -o define -t mksysb -a server=master \
    -a location=/resources/mksysb.image -a source=client1 \
    -a mk_image=yes mksysb2 
    
  5. To define a mksysb resource, mksysb2, and create a mksysb image of the client, client1, during the resource definition where the mksysb flags used to create the image are -em, and the image will be located in /resources/mksysb.image on the master, type:

    nim -o define -t mksysb -a server=master \
    -a location=/resources/mksysb.image -a source=client1 \
    -a mk_image=yes -a mksysb_flags=em mksysb2
    
  6. To define an exclude_files resource, exclude_file1, located in /resources/exclude_file1 on the master, type:

    nim -o define -t exclude_files -a server=master \
    -a location=/resources/exclude_file1 exclude_file1
    
  7. A machine called redfish, hostname redfish_t.lab.austin.ibm.com, has its primary interface attached to a token-ring network with ring speed of 16 Megabits. To define redfish as a standalone machine in the NIM environment and instructing NIM to locate the name of the network that the machine's primary interface is attached, type:

    nim -o define -t standalone  -a if1="find_net \
    redfish_t.lab.austin.ibm.com 0" -a ring_speed1=16 redfish
    
  8. A machine called bluefish, hostname is bluefish_e.lab.austin.ibm.com, has its primary interface attached to an ethernet network with cable_type of bnc. To define bluefish as a diskless machine in the NIM environment and instructing NIM to locate the name of the network that the machine's primary interface is attached, and if not found, have NIM define a NIM network with the name ent_net, subnetmask of 255.255.255.128 and default route using the gateway with hostname lab_gate, type:

    nim -o define -t diskless -a if1="find_net \
    bluefish_e.lab.austin.ibm.com 0" -a net_definition="ent \
    255.255.255.128 lab_gate 0 ent_net" -a cable_type=bnc bluefish
    

    Note: Specify 0 in place of the master gateway in the net_definition attribute if a default route for the master already exists, otherwise you must specify the master gateway.

dkls_init

  1. To initialize the environment for a diskless workstation with the name of syzygy, type:

    nim -o dkls_init syzygy
    
  2. To exclude the member named diskls2 from operations on the machine group DisklsMacs1, and then initialize the remaining members while allocating the diskless resources defined by the resource group named DisklsRes1, enter the following two commands:

    nim -o select -a exclude=diskls2 DisklsMacs1
    nim -o dkls_init -a group=DisklsRes1 DisklsMacs1
    
  3. To initialize the group of diskless machines defined by the machine group dtgrp1, while allocating the required and optional resources defined by the resource group dk_resgrp1, when the dkls_init operation runs, type:

    nim -o dkls_init -a group=dtgrp1 dk_resgrp1
    

dtls_init

  1. To initialize the environment for a dataless workstation with the name of syzygy, type:

    nim -o dtls_init syzygy
    
  2. To exclude the member named dataless1 from operations on the machine group DatalsMacs1, and then initialize the remaining members while allocating the dataless resources defined by the resource group named DatalsRes1, enter the following two commands:

    nim -o select -a exclude=datals2 DatalsMacs1
    nim -o dtls_init -a group=DatalsMacs1 DatalsRes1
    
  3. To initialize the group of dataless machines defined by the machine group DatalsMacs1, while allocating the required and optional resources defined by the resource group DatalsRes1, when the dtls_init operation runs, type:

    nim -o dtls_init -a group=DatalsMacs1 DatalsRes1
    

lppchk

To verify the file checksums for all packages beginning with the name bos on NIM targets in the group of standalone machines macgrp1, and displaying detailed error information and updating the software database to match the actual file checksum when inconsistencies are found, type:

nim -o lppchk -a lppchk_flags='-c -m3 -u' \
-a filesets='bos*' macgrp1

Since the lppchk operation runs in the background on group members by default, to view the output from the lppchk operation enter:

nim -o showlog -a log_type=lppchk macgrp1

maint

From the master, to deinstall the software products bos.INed and adt from a standalone machine, stand1, such that installp_bundle, bundle2, contains the names of the installable options, type:

nim -o maint -a installp_flags="-u" \
-a installp_bundle=bundle2 stand1

maint_boot

To enable the NIM standalone client, stand1, to boot in maintenance mode, type:

nim -o maint_boot stand1

This sets up the maintenance boot operation, but you must initiate the network boot locally from stand1.

showlog

To view the boot logs of the machines defined by the group DisklsMacs1, type:

nim -o showlog -a log_type=boot DisklsMacs1

showres

  1. To show the contents of the config script script1, type:

    nim -o showres script1
    
  2. To show the contents of the bosinst.data resource bosinst_data1, type:

    nim -o showres bosinst_data1
    
  3. To list all the filesets in the lpp_source lpp_source1, type:

    nim -o showres lpp_source1
    
  4. To list all the filesets in the lpp_source lpp_source1 relative to what is currently installed on the machine machine1, type:

    nim -o showres -a reference=machine1 lpp_source1
    
  5. To list user instructions for the bos.INed and xlC.rte filesets on the lpp_source lpp_source1, type:

    nim -o showres -a filesets="bos.INed xlC.rte" \
    -a installp_flags="qi" lpp_source1
    
  6. To list all problems fixed by software on the lpp_source lpp_source1, use:

    nim -o showres -a instfix_flags="T" lpp_source1
    

AIX 4.3 or later Examples

alt_disk_install

  1. To install a mksysb resource all_devices_mysysb to client roundrock, on hdisk4 and hdisk5, using the image_data resource image_data_shrink, with debug turned on, type:

    nim -o alt_disk_install -a source=mksysb\
    -a image_data=image_data_shrink\
    -a debug=yes\
    -a disk='hdisk4 hdisk5' roundrock
    
  2. To clone a rootvg on client austin to hdisk2, but only run phase1 and phase2 (leaving the /alt_inst file systems mounted), type:

    nim -o alt_disk_install -a source=rootvg\
    -a disk='hdisk2'\
    -a phase=12 austin
    

AIX 5.1 or later Examples

bos_inst

  1. To install the machine blowfish and accept software license agreements, type:

    nim -o bos_inst -a spot=spot1 -a lpp_source=images1 \
    -a accept_licenses=yes -a resolv_conf=rconf1 blowfish
    

Files


/etc/niminfo Contains variables used by NIM.

Related Information

The lsnim command, nimclient command, nimconfig command, niminit command.

The .info file.


[ Previous | Next | Table of Contents | Index | Library Home | Legal | Search ]