3
A NIM environment is a logical group of machines, and multiple NIM environments can share the same TCP/IP network. However, one machine can be part of only one NIM environment a time, and there can be only one active NIMmaster per environment. The machines (or clients) can be standalone systems, LPARs, diskless, and dataless clients (also known as “thin clients”). The machines can be controlled by one (or more) Hardware Service Console (better known as a Hardware Management Console, or HMC), or be standalone machines without a HMC. Your first task is to determine which machine or LPAR will be the NIM master. Next, you must decide which machines will serve the NIM resources. There are three basic machine roles in a NIM environment: the master, the client (NIM “machine”), and the resource server. The resource server can be either the NIM master or a standalone machine (a system that has its own local copy of the AIX operating system). NIM Environment Master Master refers the machine where you set up and maintain your NIM environment. You can also initiate installations from here (push mode). It is the key piece of the NIM environment. NIM master is only used to run administrative tasks. Client The NIM client can be the target for NIM master-initiated operations such as installation, updates, and so forth (push mode). Also, a client can initiate its own installation or update (pull mode). A NIM client automatically becomes a resource server when it holds NIM resources. Resource server Any machine (the master or a standalone client) can be configured by the master as a server for a particular software resource. In most environments, the master is also resource server. Push and pull modes The push mode operation is initiated from the master. The pull mode operation is initiated from the client. The very first time a client is installed, only the pull mode can be used. Note the following points: · In order for the push mode to be successful, the client must have a miNIMum AIX image already installed and TCP/IP configured. · To use the pull mode, you need access to the clients’ SMS menu. For this you either need a console attached to the machine, or for HMC-managed systems, you need access to the HMC. NIM database The NIM database is stored in the AIX Object Data Management (ODM) repository on the NIM master and is divided into four classes: machines, networks, resources, groups. Machines class If NIM master is setup and running then lsNIM command extract the content of NIM database. To extract info of a particular class use lNIM –c classname. Networks class The network is what allows the machines in a NIM environment to communicate which each other. If the network is a simple local area network (LAN), the definition of the network object is simplified. The purpose of the network object is to depict the network topology used by the NIM environment. Each modification made on the physical network must be reflected to the NIM database. Example: # lsNIM -c networks NET_EN1 networks ent Nstate=Network state The Nstate field determines whether the network object is in use. If the Nstate value displayed is different from ready for a NIM operation, you cannot perform any operation on this object. Resources class A NIM resource is a pointer to a file or a directory located on a Resource Server. NIM Master is the default Resource Server. e. g. The bosinst_data resource points to a file that contains information used to perform the installation process without requiring any manual intervention. The basic characteristics of a resource are the NIMname, the location (the location of the file or directory), and the resource server hosting the resource. To list the resources: lsNIM –c resource To list characterisitics of a resource: lsNIM –l resource_name Rstate=resource state Rstate values: ready for use / verification is being performed / customization is being performed / unavailable for use The Rstate shown determines whether the object is currently in use or not. If the Rstate is not ready, it cannot be used and a warning message will appear on the console. Groups class A group is a collection of either machines or resources. Only two types are available:

Nim Basics

Embed Size (px)

DESCRIPTION

NIm Basics for starters

Citation preview

ANIMenvironment is alogical groupof machines, and multipleNIMenvironments can share the same TCP/IP network. However, one machine can be part of only oneNIMenvironment a time, and there can be only one activeNIMmaster per environment.The machines (or clients) can be standalone systems,LPARs, diskless, and dataless clients (also known as thin clients). The machines can be controlled by one (or more) Hardware Service Console (better known as a Hardware Management Console, orHMC), or be standalone machines without aHMC.Your first task is to determine which machine orLPARwill be theNIMmaster.Next, you must decide which machines will serve theNIMresources.There are three basic machine roles in aNIMenvironment: the master, the client (NIMmachine), and the resource server. The resource server can be either theNIMmaster or a standalone machine (a system that has its own local copy of theAIXoperating system).NIMEnvironmentMasterMaster refers the machine where you set up and maintain yourNIMenvironment. You can also initiate installations from here (push mode). It is the key piece of theNIMenvironment.NIMmaster is only used to run administrative tasks.ClientTheNIMclient can be the target forNIMmaster-initiated operations such as installation, updates, and so forth (push mode). Also, a client can initiate its own installation or update (pull mode). ANIMclient automatically becomes a resource server when it holdsNIMresources.Resource serverAny machine (the master or a standalone client) can be configured by the master as a server for a particular software resource. In most environments, the master is also resource server.Push and pull modesThepushmode operation is initiated from themaster. Thepullmode operation is initiated from theclient. The very first time a client is installed, only the pull mode can be used. Note the following points: In order for the push mode to be successful, the client must have a miNIMum AIX image already installed and TCP/IP configured. To use the pull mode, you need access to the clients SMS menu. For this you either need a console attached to the machine, or forHMC-managed systems, you need access to theHMC.NIM databaseTheNIMdatabase is stored in the AIX Object Data Management (ODM) repository on theNIMmaster and is divided into four classes:machines, networks, resources, groups.Machines classIfNIMmaster is setup and running then lsNIMcommand extract the content ofNIMdatabase.To extract info of a particular class use lNIMc classname.Networks classThe network is what allows the machines in aNIMenvironment to communicate which each other. If the network is a simple local area network (LAN), the definition of the network object is simplified. The purpose of the network object is to depict the network topology used by theNIMenvironment. Each modification made on the physical network must be reflected to theNIMdatabase.Example:# lsNIM-c networksNET_EN1 networks entNstate=Network stateThe Nstate field determines whether the network object is in use. If the Nstate value displayed is different from ready for aNIMoperation, you cannot perform any operation on this object.Resources classANIMresource is a pointer to a file or a directory located on a Resource Server.NIMMaster is the default Resource Server. e. g. The bosinst_data resource points to a file that contains information used to perform the installation process without requiring any manual intervention. The basic characteristics of a resource are theNIMname, the location (the location of the file or directory), and the resource server hosting the resource.To list the resources: lsNIMc resourceTo list characterisitics of a resource: lsNIMl resource_nameRstate=resource stateRstate values: ready for use / verification is being performed / customization is being performed / unavailable for useThe Rstate shown determines whether the object is currently in use or not. If the Rstate isnot ready, it cannot be used and a warning message will appear on the console.Groups classAgroupis a collection of either machines or resources. Only two types are available: res_group, for grouping a set of resources mac_group, for grouping a set of machinesImportant Resource types:SpotSPOT, or Shared Product Object Tree, is a directory of code (installed filesets) that is used during client booting procedure. It is equivalent in content to the code that resides in the /usr file system on a system running AIX 5L (binary objects executables and libraries, header files and shell scripts). This resource (directory) replaces the content of the basic ramdisk image available on installation CDs.The installation is performed over a network, and there are no AIX CDs available. Device drivers, the BOS install program, and other necessary code needed to perform a base operating system installationare found inside the SPOT. During the installation, the client machine NFS mounts this resource in order to access the code needed for the installation process.The SPOT also contains the code needed to generate the boot images (kernels, which will be stored in the /tftpboot directory) that the client uses until it can manage to NFS-mount the SPOT directory.By running thelsNIM -t spotcommand, you can the list the different available SPOT resources.lpp_sourceAn 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.By running thelsNIM -t lpp_sourcecommand, you can the list the different available lpp resources.mksysbThis resource is a file containing the image of the root volume group (generated with the AIXmksysbcommand) of a machine. It is used to restore a machine, or to install it from scratch (also known as cloning a client).By running thelsNIM -t mksysbcommand, you can the list the different available mksysb resourcesbosinst_dataThe bosinst_data resource is a flat ASCII file similar to the bosinst.data. This resource comes in handy for both push or pull installation of multiple machines at the same time.By running thelsNIM -t bosinst_datacommand, you can the list the different available bosinst_data resources.scriptThe script resource is a file. After the BOS installation is finished on your client, you can perform customization such as file system resizing, additional user creation, and so forth.bootThe boot resource created a /tftpboot directory to hold all of your boot images.AIX Installation using NIM:To start a machine installation, only two resources are mandatory: the LPP source (lpp_source), and the Shared Product Object Tree (SPOT). However, to avoid using manual intervention during the installation process, additional resources providing information for the AIX_install process can be used (like bosinst_data, image_data, and script).Install NIM Master:# smitNIMconfigOR#NIMconfig -a netname=master_net -a pif_name=en0 -a netboot_kernel=mp -a cable_type=tp -a client_reg=yesThis will addNIMesisandNIMdsubsystems and startNIMesis subsystem.NIM CommandslsNIM To list theNIMresourceslsNIM -l dcmds To list the detailed info about the object dcmdslsNIM -O dcmds To list the operation dcmds object can supportlsNIM -c resources dcmds To list the resources allocated to the machine dcmdsNIMclient The client version ofNIMcommand (User can obtain same results ofNIMin server )NIMconfig -a pif_name=en0 -a netname=net1 To initialise theNIMmaster with network name net1NIMconfig -r To rebuild /etc/NIMinfo file which contains the variables forNIMNIM -o define -t lpp_source -a source=/dev/cd0 -a server=master -a location=/export/lpp_source/lpp_source1 lpp_source1 To define lpp_source1 image in /export/lpp_source/lpp_source directory from source cd0NIM -o define -t mksysb -a server=master -a location=/resources/mksysb.image mksysb1 To define mksysb resource mksysb1, from source /resources/mksysb.image on masterNIM -o remove inst_resource To remove the resource inst_resourceNIM -o check lpp_source1 To check the status of lpp_source lpp_source1NIM -o allocate -a spot=spot1 -a lpp_source=lpp_source1 node1 To allocate the resources spot1 and lpp_source1 to the client node1NIM -o bos_inst node1 To initialiseNIMfor the BOS installation on node1 with the allocated resourcesNIM -o dkls_init dcmds To initialize the machine dcmds as diskless operationNIM -o dtls_init dcmds To initialize the machine dcmds for dataless operationNIM -o cust dcmds To initialize the machine dcmds for customize operationNIM -o diag dcmds To initialize the machine dcmds for diag operationNIM -o maint dcmds To initialize the machine dcmds for maintenance operationNIM -o define -t standalone -a platform=rspc -a if1=net1 dcmds xxxxx -a cable_type1=bnc dcmds To define the machine dcmds as standalone with platform as rspc and network as net1 with cable type bnc and mac address xxxxxNIM -o unconfig master To unconfigureNIMmasterNIM -o allocate -a spot=spot1 dcmdsTo allocate the resource spot1 from machine dcmdsNIM -o deallocate -a spot=spot1 dcmdsTo de allocate the resource spot1 from machine dcmdsNIM -o remove dcmdsTo remove machine dcmds after removing all resources associated to itNIM -o reboot dcmds To reboot ther client dcmdsNIM -o define -t lpp_source -a location=/software/lpp1 -a server=master -a source=/dev/cd0 lpp1 To define lppsource lpp1 on master at /software/lpp1 directory from source device /dev/cd0