Under Construction
Displaying predefined NIM information
The lsnim command offers two options for displaying predefined NIM information: “-p” and “-P“. Using the “-p” option displays only the class, subclass, or type names. Using the “-P” option instead displays a description alongside the names. Using the “-p” option alone displays all existing classes:
aixnim # lsnim -p
machines
resources
networks
management
groups
customers
aixnim #
If “-P” is used instead, there is a short description for each class:
aixnim # lsnim -P
machines = class of NIM objects which represent machines
resources = NIM object class which represent install resources
networks = class of NIM objects which represent networks
management = class of NIM objects which represent machine control points
groups = a group of machines or resources
customers = class of NIM objects which represent machines and resources
aixnim #
Note: There are some other classes internally, but they are not relevant for custom NIM objects and are therefore not displayed.
If you want to know all the associated types for a class, you can use the “-c” (class) option along with the desired class. Below are all the types of the machines class:
aixnim # lsnim -P -c machines
diskless = all filesystems & resources remote
dataless = local paging,dump; remote /,/usr; others remote or local
standalone = local filesystems & resources
master = machine which controls the NIM environment
alternate_master = alternate machine which can control the NIM environment
wpar = file systems and resources hosted on managing system
standalone = local filesystems & resources
aixnim #
Note: The shorter “lsnim -Pcmachines” can also be used. The POSIX standard for using options is supported.
Internally, NIM uses subclasses, which can be displayed with the “-S” option:
aixnim # lsnim -PS
class = used to group NIM predefined object classes
platform_subclass = attributes which define the platform choices
rs6k_subclass = machine configuration types which are supported for rs6k
rs6ksmp_subclass = machine configuration types which are supported for rs6ksmp
rspc_subclass = machine configuration types which are supported for rspc
rspcsmp_subclass = machine configuration types which are supported for rspcsmp
info_attrs = groups info which can be customized for an object
flag_attrs = subset of attributes which are used as flags only
seqno = subset of attributes which require a sequence number
if_attrs = groups network interface attributes together
dkls_res = subset of resource types which diskless can use
dtls_res = subset of resource types which dataless can use
std_res = subset of resource types which standalone can use
mstr_res = subset of resource types which master can use
pull_ops = subclass of operations which may be pulled
bos_res = groups BOS image types together
cust_res = groups customization resource types together
arch_subclass = attributes which define the architecture choices
connect_subclass = attribute which defines the protocol used for client communication
mgmt_profile_attrs = groups management profile attributes together
keyexch_attrs = groups keyexch attributes together
wpar_res = subset of resource types which wpar can use
managed_resources = groups resources allocated to managing system
update_policy_subclass = attribute which defines the update policy for client installs
aixnim #
However, we will not further investigate subclasses here.
Occasionally, it’s interesting to know which operations are possible on a particular NIM type. To do this, use the “-O” (operation) option with “-p” or “-P“. Additional options allow you to select the type(s) of interest.
Example 1: Operations that are possible on the NIM type standalone:
aixnim # lsnim -P -t standalone -O
standalone:
define = define an object
change = change an object's attributes
remove = remove an object
allocate = allocate a resource for use
deallocate = deallocate a resource
diag = enable a machine to boot a diagnostic image
cust = perform software customization
bos_inst = perform a BOS installation
maint = perform software maintenance
reset = reset an object's NIM state
lslpp = list LPP information about an object
fix_query = perform queries on installed fixes
check = check the status of a NIM object
reboot = reboot specified machines
maint_boot = enable a machine to boot in maintenance mode
showlog = display a log in the NIM environment
showres = show contents of a resource
lppchk = verify installed filesets
alt_disk_install = perform an alt_disk_install operation on a client
alt_disk_mig = perform an alt_disk_mig operation on a client
restvg = perform a restvg operation
lswpar = show the characteristics of a workload partition
syncwpar = synchronize workload partition software with the managed system
showdump = Show the location of a client dump
snap = collect a snap record from a client
deploy = deploy an ovf_vm NIM resource to the target NIM client objects
eject = eject a vopt_iso object from a client target
aixnim #
Example 2: Operations that are possible on NIM types of the networks class:
aixnim # lsnim -Pc networks -O
tok:
define = define an object
change = change an object's attributes
remove = remove an object
ent:
define = define an object
change = change an object's attributes
remove = remove an object
ent6:
define = define an object
change = change an object's attributes
remove = remove an object
fddi:
define = define an object
change = change an object's attributes
remove = remove an object
generic:
define = define an object
change = change an object's attributes
remove = remove an object
atm:
define = define an object
change = change an object's attributes
remove = remove an object
hfi:
define = define an object
change = change an object's attributes
remove = remove an object
aixnim #
Example 3: Operations that are possible on NIM types of the managed_resources subclass:
aixnim # lsnim -POs managed_resources
devexports:
define = define an object
change = change an object's attributes
remove = remove an object
showres = show contents of a resource
savewpar:
change = change an object's attributes
remove = remove an object
showres = show contents of a resource
define = a workload partition backup image
secattrs:
define = define an object
change = change an object's attributes
remove = remove an object
showres = show contents of a resource
wpar_spec:
define = define an object
change = change an object's attributes
remove = remove an object
showres = show contents of a resource
aixnim #
If you are interested in further information such as
- attributes
- internal attributes
- flags
- operations
- states
- …
then, instead of “-O” (operation), the option “-l” (detailed or long) can be used. The output can be very extensive and is therefore only shown here using the example of the type ent:
aixnim # lsnim -P -t ent -l
ent:
class = networks
type = ent
define = define an object
change = change an object's attributes
remove = remove an object
reserved = indicates that the object is for NIM internal use only
info = used to relate state specific information to the user
missing = information missing from an object's definition
at = the time when a scheduled NIM operation will occur
locked = object is locked for update
comments = user entered comments
Nstate = NIM state
prev_state = store the object's previous NIM state
net_addr = network address for a network
snm = subnetmask for a network
routing = routing information for a network
other_net_type = other network interface types which are represented by the same network
ieee_ent = specifies whether the network is an IEEE 802.3 ethernet network.
new_name = Represents the new name for a NIM object.
aixnim #
A less well-known option is the use of the “-a” (attribute) option together with “-p” or “-P“. This combination allows for descriptive help text for attributes (including operations).
Example 1: Description of the class attribute:
aixnim # lsnim -p -a class
class:
NIM functions by modeling some aspects of the physical
environment in which it is operating. To do this, NIM requires that
each physical entity that is going to participate be
represented by a unique object in the NIM database. To
organize this information, NIM classifies each object into a specific
class and type. You can display the list of object classes which NIM
supports using the lsnim command:
# lsnim -p
To display a list of object types for a specific object class, enter:
# lsnim -p -c <NIM object class>
aixnim #
Example 2: Description for the attribute connect:
aixnim # lsnim -p -a connect
connect:
This attribute is a predefined string value that determines which
network communication protocol is enabled on the client. By default
NIM clients will use the RSH Protocol for accepting NIM push
operations. Valid string values are:
shell client will use RSH for accepting NIM push operations.
nimsh client will use NIM Service Handler for accepting NIM
push operations.
aixnim #
Example 3: Description of the operation update:
aixnim # lsnim -p -a update
update:
This operation updates an lpp_source by adding software to the
lpp_source or removing software from the lpp_source. When adding
software to an lpp_source, a source attribute must be specified. The
source attribute can be an lpp_source object or a directory or device
that is local to the server of the target lpp_source. To remove
software from an lpp_source you must specify the remove attribute.
The remove attribute and source attribute are mutually exclusive.
The package attribute will accept any input accepted by the gencopy
command. You may specify an installp_bundle instead of packages.
aixnim #
The “-Z” option may be useful for writing shell scripts in the NIM environment. It separates fields from each other with a “:” character in the output, which often makes further processing easier.