Você está na página 1de 43

AIX 5L Network Installation Management (NIM) (Course Code AU08) Student Exercises ERC 6.

0 IBM Certified Course Material V3.1.0.1 cover Front cover Student Exercises September 2005 Edition The information contained in this document has not been submitted to any formal IBM test and is distributed on an as is basis without any warranty either express or implied. The use of this information or the imple mentation of any of these techniques is a customer responsibility and depends on the customers ability to evaluate and integrate the m into the customers operational environment. While each item may have been reviewed by IBM for accuracy in a specific situation, th ere is no guarantee that the same or similar results will result elsewhere. Customers attempting to adapt these techniques to their own en vironments do so at their own risk. Copyright International Business Machines Corporation 1996, 2005. All rights res erved. This document may not be reproduced in whole or in part without the prior writte n permission of IBM. Note to U.S. Government Users Documentation related to restricted rights Use, du plication or disclosure is subject to restrictions set forth in GSA ADP Schedule Contract with IBM Corp. Trademarks IBM is a registered trademark of International Business Machines Corporation. The following are trademarks of International Business Machines Corporation in t he United States, or other countries, or both: Linux is a trademark of Linus Torvalds in the United States, other countries, or both. Other company, product and service names may be trademarks or service marks of o thers. AIX AIX 5L BladeCenter Domino eServer Lotus Notes Lotus Notes POWER3 PowerPC pSeries RS/6000 SP xSeries Student Exercises V3.1.0.1 TOC Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Contents iii Contents Trademarks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . v Exercises Description . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . vii Exercise 1. Introduction to NIM . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1-1 Exercise 2. Setting Up the NIM Master . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2-1 Exercise 3. Base (RTE) Install . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3-1

Exercise 4. Defining Additional Base Install Resources . . . . . . . . . . . . . . . . . . . . . 4-1 Exercise 5. Advanced Base Install . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 5-1 Exercise 6. Using NIM for Disaster Recovery . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6-1 Exercise 7. LPP_SOURCE and SPOT Management . . . . . . . . . . . . . . . . . . . . . . . . . 7-1 Exercise 8. Ongoing Client Updates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8-1 Appendix A. Initiating a Manual Install on an HMC LPAR . . . . . . . . . . . . . . . . . . . A-1 Appendix B. Initiating a Manual Install on a Stand-alone Machine . . . . . . . . . . . B-1 Appendix C. Initiating a Manual Install on a 170. . . . . . . . . . . . . . . . . . . . . . . . . . . C-1 Appendix D. Typical Base (RTE) Install Output. . . . . . . . . . . . . . . . . . . . . . . . . . . . D-1 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. iv Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Trademarks v V3.1.0.1 TMK Trademarks The reader should recognize that the following terms, which appear in the conten t of this training document, are official trademarks of IBM or other companies: IBM is a registered trademark of International Business Machines Corporation. The following are trademarks of International Business Machines Corporation in t he United States, or other countries, or both: Linux is a trademark of Linus Torvalds in the United States, other countries, or both. Other company, product and service names may be trademarks or service marks of o thers. AIX AIX 5L BladeCenter Domino eServer Lotus Notes Lotus Notes POWER3 PowerPC pSeries RS/6000 SP xSeries Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. vi Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercises Description vii V3.1.0.1 pref Exercises Description Overall Thoughts These exercises are set up to reinforce the material in the lecture. Most are reasonably short and typically end in an activity that takes awhile. Hence, we may choose during several exercises to restart the next lecture before completing the last exercise. Most exercises can be done either in smit or at the command line.

Exercise Dependencies Most exercises depend upon the fact that prior exercises have completed successfully. If your team decides to implement alternate activity, please let your instructor know to see if this activity may interfere with future exercises. Exercise Teams You are paired up for these exercises. Your team members work together to implement a NIM environment. You have one NIM master and one NIM client to work with. Machine Differences These exercises are taught in a few different machine environments. Please note your instructors directions on what you need for your specific environment. Exercise Instructions This section tells you what to do but does not give you details on how to get it done. This section is normally chosen by folks that already have a pretty good NIM background. Exercise Instructions with Hints This section is exactly the same as the section above, except that it not only tells you what to do but gives you detailed instructions on how to get it done. Most folks that don t have an extensive NIM background choose to do this section of the exercise. Exercise Solutions On some occasions you may be asked a question during the exercise. Answers to those questions are found in this section of each exercise. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. viii Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 1. Introduction to NIM 1-1 V3.1 EXempty Exercise 1. Introduction to NIM What This Exercise is About This exercise allows the students to use the lsnim command to view and analyze current NIM objects and to briefly explore NIM tasks available in smit. What You Should Be Able to Do Use the lsnim command to view NIM objects Identify basic tasks available under the smitty nim menu Introduction Depending on your environment, your instructor may need to supply you with the following information: PC Login ID: __________________________________________ PC Login Password: ____________________________________ AIX Demo Master Machine name: _________________________ AIX Login ID: _________________________________________ AIX Login Password: ___________________________________ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 1-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to the NIM master demonstration machine using the instructions prov ided by your instructor. __ 2. Run the lsnim | more command. Notice the objects in your NIM database that appear.

__ 3. Let s use the lsnim command again. This time, lets view just the machines c lass. You should see a master and client listed. The clients name is the name in the fi rst column thats not the master name. Record the name of the client below. Client Name _________________________________________________ __ 4. Using the clients name from the last listing, do a low-level listing of thi s client. From the low-level listing, notice your client s Cstate value. Is it ready for a NIM operation? Notice also the connect value. Is your client using the rsh (shell) o r nimsh communication protocol? __ a. Is your client ready for a NIM operation? _____________________________ __ b. What communication protocol is your client using? _____________________ __ 5. Now, use the lsnim command to view just the resources class. Notice the SP OT on the listing. You can identify it by looking at the type field (the last colum n) and looking for the type of SPOT. Then, once youve found the right line, look back to the first field and identify the name of the SPOT. Record the name below. Name of your SPOT: ______________________________________________ __ 6. Now, lets do a low-level listing of this SPOT resource that we identified a bove. Notice the oslevel_r field. Use the value of this field to record below what lev el this SPOT is at. __ a. What level is this SPOT at? _________________________________________ __ 7. Now, while still looking at your SPOTs low-level listing, notice the server and location fields. Use this information to find out where this resource is located . Change to the directory listed and view this resource. __ 8. Run another lsnim report. This time, rather than viewing all resources, le ts use the -t option to narrow it down to just the lpp_source type of resources. Notice the name of the lpp_source on your system. (Remember, its the name in the first field .) Now, do a low-level listing of this resource and find out its location. Change t o that location and notice the contents. __ 9. Finally, take a minute to explore the smitty nim menu. Concentrate on the tasks available under the Perform Software Installation and Maintenance Tasks menu item. Please be careful, though. Dont install any software at this time. When don e, please exit out of this system. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 1. Introduction to NIM 1-3 V3.1 EXempty Exercise Instructions with Hints __ 1. Log in to the NIM master demonstration machine using the instructions prov ided by your instructor. __ 2. Run the lsnim | more command. Notice the objects in your NIM database that appear. lsnim | more

__ 3. Let s use the lsnim command again. This time, lets view just the machines c lass. You should see a master and client listed. The clients name is the name in the fi rst column thats not the master name. Record the name of the client below. Client Name _________________________________________________ # lsnim -c machines __ 4. Using the clients name from the last listing, do a low-level listing of thi s client. From the low-level listing, notice your client s Cstate value. Is it ready for a NIM operation? Notice also the connect value. Is your client using the rsh (shell) o r nimsh communication protocol? __ a. Is your client ready for a NIM operation? _____________________________ __ b. What communication protocol is your client using? _____________________ # lsnim -l <client name> __ 5. Now, use the lsnim command to view just the resources class. Notice the SP OT on the listing. You can identify it by looking at the type field (the last colum n) and looking for the type of SPOT. Then, once youve found the right line, look back to the first field and identify the name of the SPOT. Record the name below. Name of your SPOT: ______________________________________________ # lsnim -c resources | more __ 6. Now, lets do a low-level listing of this SPOT resource that we identified a bove. Notice the oslevel_r field. Use the value of this field to record below what lev el this spot is at. # lsnim -l <spot_name> __ a. What level is this SPOT at? _________________________________________ __ 7. Now, while still looking at your SPOTs low-level listing, notice the server and location fields. Use this information to find out where this resource is located . Change to the directory listed and view this resource. # lsnim -l <spot_name> # cd directory_where_spot_is # ls Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 1-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 __ 8. Run another lsnim report. This time, rather than viewing all resources, le ts use the -t option to narrow it down to just the lpp_source type of resources. Notice the name of the lpp_source on your system. (Remember, its the name in the first field .) Now, do a low-level listing of this resource and find out its location. Change to that location and notice the contents. # lsnim -t lpp_source # lsnim -l <lpp_source_name> # cd directory_where_lpp_source_is # ls # cd installp/ppc # ls | more __ 9. Finally, take a minute to explore the smitty nim menu. Concentrate on the

tasks available under the Perform Software Installation and Maintenance Tasks menu item. Please be careful, though. Dont install any software at this time. When don e, please exit out of this system. # smitty nim Perform Software Installation and Maintenance Tasks Exit smit when done exploring. # exit (back to your own AIX system) END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 1. Introduction to NIM 1-5 V3.1 EXempty Exercise Solutions 6. a. Is your client ready for a NIM operation? Answers may vary. If the Cstate field is set to Ready for a NIM operation the answer is yes. b. What communication protocol is your client using? Answers may vary. If the connect field is set to shell it is using rsh. If it is set to nimsh, its using nimsh. 8. a. What level is this SPOT at? Answers may vary. Notice the oslevel_r field. It probably says 5300-01. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 1-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 2. Setting Up the NIM Master 2-1 V3.1 EXempty Exercise 2. Setting Up the NIM Master What This Exercise is About This exercise allows the students to set up their NIM master. What You Should Be Able to Do Set up the NIM master Introduction You need to make sure you are aware of the following in your environment: AIX Master Machine name: _______________________________ AIX Master Machine IP: __________________________________ AIX Client Machine name: ________________________________ AIX Client Machine IP: __________________________________ Is DNS currently used: __________________________________ Your Master machines Primary network interface: _____________ Where your AIX code is located ____________________________ (/usr/sys/inst.images/AIXinstalls by default) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 2-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. Run the lslpp -L grep nim command to see what filesets you currently have

installed. You should see the bos.sysmgt.nim.client fileset as this is downloade d on any V5 base machine. However, notice that the required bos.sysmgt.nim.master fileset is missing. __ 3. Install this bos.sysmgt.nim.master fileset. Rather than using an AIX insta ll CD as your INPUT device, use the /usr/sys/inst.images/AIXinstalls directory. __ 4. We set up our NIM environment according to the layout taught in the lectur e. To start this procedure, lets create a nimvg volume group using our spare hdisk1 disk. __ 5. Lets create and mount our /export/nim filesystem inside the nimvg volume group. Make it a JFS2 filesystem at 8000 MB and use an INLINE log. Take all othe r defaults. Dont forget to mount your file system. __ 6. Before we configure our master, lets double check the hostname resolution thats in place. Hostname resolution can cause big problems with NIM if it is not set up right or is unstable. In order to be extra cautious during our NIM learning c urve, we choose to use a local /etc/hosts file instead of relying on DNS. At your plan ned NIM master machine, please move your /etc/resolv.conf file (if it exists) to /etc/resolv.conf.bak. __ 7. Now, lets make sure that you have the appropriate entries for your NIM mast er and client in your /etc/hosts file at your planned master site. Ask your instructor if you are not yet sure what hostnames and IPs to use. Finally, issue the hostname command at this planned master site to make sure that your /etc/hosts entry for your master matches the hostname for your system. __ 8. Now were ready to configure our master. Use smitty nim and navigate down to the appropriate menu to configure your master. Make sure to place your resources in your newly mounted /export/nim filesystem. If using smit, the location for your lpp_source should be /export/nim/lpp_source/lpp_source53ML1. The location for your spot should be /export/nim/spot. Call your resources lpp_source53ML1 and spot53ML1. Define your bundles and be sure to choose the safe backout option at the bottom. __ 9. From another terminal session thats also logged into the master site, lets v iew our progress. Type in lsnim. You should already begin to see some of the objects in your NIM database even though the setup is still in progress. Also, view your /etc/niminfo file. Finally, notice the new nim daemons available on your lssrc a listing. __ 10. While your NIM master sets up, let s take a short break and then return t o lecture. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 2. Setting Up the NIM Master 2-3 V3.1 EXempty Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. Run the lslpp -L grep nim command to see what filesets you currently have installed. You should see the bos.sysmgt.nim.client fileset as this is downloade d on any V5 base machine. However, notice that the required bos.sysmgt.nim.master

fileset is missing. # lslpp -L | grep nim __ 3. Install this bos.sysmgt.nim.master fileset. Rather than using an AIX insta ll CD as your INPUT device, use the /usr/sys/inst.images/AIXinstalls directory. # smitty install_latest Input Device: /usr/sys/inst.images/AIXinstalls Software to Install: bos.sysmgt.nim.master OR # geninstall -d /usr/sys/inst.images/AIXinstalls -IacNgX \ bos.sysmgt.nim.master __ 4. We set up our NIM environment according to the layout taught in the lectur e. To start this procedure, lets create a nimvg volume group using our spare hdisk1 disk. # smitty _mksvg Volume Group Name: nimvg Physical Volume Names: hdisk1 OR # mkvg -S -y nimvg hdisk1 __ 5. Lets create and mount our /export/nim filesystem inside the nimvg volume group. Make it a JFS2 filesystem at 8000 MB and use an INLINE log. Take all othe r defaults. Dont forget to mount your file system. # smitty crjfs2std Volume Group Name nimvg Unit Size: Megabytes Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 2-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 Number of Units: 8000 Mount Point: /export/nim Mount Automatically: yes Logical Volume for Log: INLINE # mount /export/nim OR # crfs -v jfs2 -g nimvg -p rw -A yes -a logname=INLINE \ -a size=8000M -a agblksize=4096 -m /export/nim # mount /export/nim __ 6. Before we configure our master, lets double check the hostname resolution thats in place. Hostname resolution can cause big problems with NIM if it is not set up right or is unstable. In order to be extra cautious during our NIM learning c urve, we choose to use a local /etc/hosts file instead of relying on DNS. At your plan ned NIM master machine, please move your /etc/resolv.conf file (if it exists) to /etc/resolv.conf.bak. # mv /etc/resolv.conf /etc/resolv.conf.bak __ 7. Now, lets make sure that you have the appropriate entries for your NIM mast er and client in your /etc/hosts file at your planned master site. Ask your instructor if you are not yet sure what hostnames and IPs to use. Finally, issue the hostname command at this planned master site to make sure that your /etc/hosts entry for your master matches the hostname for your system. # vi /etc/hosts # hostname

__ 8. Now were ready to configure our master. Use smitty nim and navigate down to the appropriate menu to configure your master. Make sure to place your resources in your newly mounted /export/nim filesystem. If using smit, the location for your lpp_source should be /export/nim/lpp_source/lpp_source53ML1. The location for your spot should be /export/nim/spot. Call your resources lpp_source53ML1 and spot53ML1. Define your bundles and be sure to choose the safe backout option at the bottom. # smitty nim (or nim_config_env) Configure the NIM Environment Configure a Basic NIM Environment (Easy Startup) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 2. Setting Up the NIM Master 2-5 V3.1 EXempty Primary Network Interface for the NIM: en0 Input device for installation images: /usr/sys/inst.images/AIXinstalls LPP_SOURCE Name: lpp_source53ML1 LPP_SOURCE Directory: /export/nim/lpp_source Create new Filesystem for LPP_SOURCE? no SPOT Name: spot53ML1 SPOT Directory: /export/nim/spot Create new Filesystem for SPOT? no Define NIM System Bundles? yes Remove all newly added NIM Definitions... yes OR (For viewing only) # nimconfig -a pif_name=en0 \ -a netname=network1 \ -a cable_type1=N/A # nim -o define -t lpp_source \ -a server=master \ -a location=/export/nim/lpp_source/lpp_source53ML1 \ -a source=/usr/sys/inst.images/AIXinstalls \ lpp_source53ML1 # nim -o define -t spot \ -a server=master \ -a location=/export/nim/spot \ -a source=lpp_source53ML1 \ spot53ML1 # mkdir /export/installp_bundle # cp /usr/sys/inst.data/sys_bundles/* /export/installp_bundle # nim -o define -t installp_bundle \ -a server=master \ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 2-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 -a location=/export/installp_bundle/<bundle_file_name> \ bundle_name Repeat the above step for all bundles. __ 9. From another terminal session thats also logged into the master site, lets v iew our progress. Type in lsnim. You should already begin to see some of the objects in your NIM database even though the setup is still in progress. Also, view your /etc/niminfo file. Finally, notice the new nim daemons available on your lssrc a listing. From another master terminal session: # lsnim

# more /etc/niminfo # lssrc -a | grep nim __ 10. While your NIM master sets up, let s take a short break and then return t o lecture. END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 3. Base (RTE) Install 3-1 V3.1 EXempty Exercise 3. Base (RTE) Install What This Exercise is About This exercise allows the students to define a client and then subsequently perform a manual base RTE install. What You Should Be Able to Do Define a Client they plan to install Set up the master to be able to handle a base install Initiate a manual install from the client site Introduction Depending on your environment, your instructor may need to supply you with the following information: HMC Hostname: __________________________________________ HMC Login ID: ___________________________________________ HMC Login Password: _____________________________________ HMC Managed Machine: ___________________________________ Client Partition Name: _____________________________________ Machine Appendix to Use for Client Initiation: ___________________ Ethernet Adapter to Use at Client: ____________________________ Speed/Duplex Settings: ____________________________________ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 3-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. We do three major things in this exercise: define your client, set up the master to handle a client install, and finally go to the client and initiating the install . __ 3. Before we define our client to NIM we have to have its hostname resolution for its install adapter in place at the NIM master. Since we double checked all of this in the last exercise, we presume its ready to go now. __ 4. Another thing we need to know in order to define our client is what platfo rm type it is. Use the getconf command and record the information below. Clients Machine Architecture: _______________________________________ __ 5. One final thing we need to know is what kernel type we re using. Viewing t he HARDWARE_BITMODE and MP_CAPABLE getconf variables tells us what we are capable of running. However, the best method to use on a currently running syste m is to view what /usr/lib/boot/unix is symbolically linked to (64, mp or up). Thi s tells us what we currently ARE running at this time. Record the information below. (CAUTION: There are some problems in our current lab environment choosing a 64-bit boot image. So if you see 64-bit, then choose mp instead). Clients Kernel Type: ______________________________________________

__ 6. Define your client to NIM. Put in your clients hostname on the first panel. Use the name as it appears in your hostname resolution database at your master. (If usin g DNS back home you can either use the long or short hostname. Your clients system hostname will always be set up to use the long hostname regardless.) Press Enter . Then, make sure you use your clients platform and kernel type. Use the nimsh protocol, N/A for cable type and ent0 for the logical device name. Let all other fields default. __ 7. Run the lsnim | more command to see your new client definition. Then, run the lsnim -l <client name> command to see your clients Cstate. __ 8. Lets now set up the master side to do a base install on your client. Go int o smitty nim and navigate down to do a base install on your client. Choose your cl ient as the installation target. Choose the RTE installation type. Choose your lpp_so urce and SPOT. Finally, choose to accept the license agreements and make sure you choose not to initiate the reboot and installation now. __ 9. Lets briefly explore what youve just accomplished. Issue the lsnim -l <clien t name> command and notice your clients Cstate. Also notice extra resources at the bottom that have just been allocated to this client. __ 10. Do a tail on the /etc/bootptab file. Notice the entry for your client. Al so notice the bf field. This is the bootfile your client is using. Do a long listing on the /tftp boot directory and make sure this bootfile exists. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 3. Base (RTE) Install 3-3 V3.1 EXempty __ 11. Finally, issue the showmount -e command to see what directories N FS has exported. __ 12. Since were doing a manual install, we need to go to the client site to con tinue this operation. This procedure changes depending on the hardware you have installed. If you know how to cause your client to boot over the network and contact your master, then do so now. If not, then please refer to the exercise appendix point ed out earlier by your instructor that shows you how to do this for your specific hardware. __ 13. Since this is a manual install, you have to answer all the standard BOS i nstall questions that come up. The two main options to watch out for are the install method (choose overwrite) and what disks to install onto (choose hdisk0). Once youve answered those two questions, let the rest of the answers default. __ 14. Congratulations! If youve made it this far, youre past the majority of the problems folks can potentially run across when doing a NIM install. __ 15. You can continue to monitor your progress at the NIM master. Type in lsni m -l <client name>. Notice not only the Cstate field, but the info field. In fact, if you end

up with errors, you have an err field to also look at. If interested, refer to A ppendix D. Typical Base (RTE) Install Output. This appendix lists what normal installati on output looks like. Eventually your client should finish the install, change the bootlist to hdisk0 and reboot. __ 16. Let s take a short break and then return to lecture while your client is installing. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 3-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. We do three major things in this exercise: define your client, set up the master to handle a client install, and finally go to the client and initiating the install . __ 3. Before we define our client to NIM we have to have its hostname resolution for its install adapter in place at the NIM master. Since we double checked all of this in the last exercise, we presume its ready to go now. __ 4. Another thing we need to know in order to define our client is what platfo rm type it is. Use the getconf command and record the information below. Clients Machine Architecture: _______________________________________ # getconf -a | grep MACHINE_ARCHITECTURE __ 5. One final thing we need to know is what kernel type we re using. Viewing t he HARDWARE_BITMODE and MP_CAPABLE getconf variables tells us what we are capable of running. However, the best method to use on a currently running syste m is to view what /usr/lib/boot/unix is symbolically linked to (64, mp or up). Thi s tells us what we currently ARE running at this time. Record the information below. (CAUTION: There are some problems in our current lab environment choosing a 64-bit boot image. So if you see 64-bit, then choose mp instead). Clients Kernel Type: ______________________________________________ # ls -l /usr/lib/boot/unix __ 6. Define your client to NIM. Put in your clients hostname on the first panel. Use the name as it appears in your hostname resolution database at your master. (If usin g DNS back home you can either use the long or short hostname. Your clients system hostname will always be set up to use the long hostname regardless.) Press Enter . Then, make sure you use your clients platform and kernel type. Use the nimsh protocol, N/A for cable type and ent0 for the logical device name. Let all other fields default. # smitty nim (or smitty nim_mkmac) Perform NIM Administration Tasks Manage Machines Define a Machine Enter your client machines hostname Press Enter

Hardware Platform Type: Use data from getconf Kernel to use for Network Boot: Use data from unix symbolic link Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 3. Base (RTE) Install 3-5 V3.1 EXempty Communication Protocol Used by Client: nimsh Cable Type: N/A Network Adapter Logical Device Name: ent0 OR nim -o define -t standalone \ -a if1="network1 <client hostname> 0 ent0" \ -a cable_type1="N/A" \ -a connect={nimsh|shell} \ -a platform={rspc|chrp} \ -a netboot_kernel={mp|up|64} \ <client name> (use your clients short name for client name. use only one space between entries in the if1 attribute) __ 7. Run the lsnim | more command to see your new client definition. Then, run the lsnim -l <client name> command to see your clients Cstate. # lsnim | more # lsnim -l <client name> __ 8. Lets now set up the master side to do a base install on your client. Go int o smitty nim and navigate down to do a base install on your client. Choose your cl ient as the installation target. Choose the RTE installation type. Choose your lpp_so urce and SPOT. Finally, choose to accept the license agreements and make sure you choose not to initiate the reboot and installation now. # smitty nim (or smitty nim_bosinst) Perform NIM Software Installation and Maintenance Tasks Install and Update Software Install the Base Operating System on Standalone Clients Target: <client_name> Installation Type: rte LPP_SOURCE: lpp_source53ML1 SPOT: spot53ML1 Accept new license agreements: yes Initiate reboot and installation now? no OR Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 3-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 nim -o bos_inst -a spot=spot53ML1 \ -a lpp_source=lpp_source53ML1 \ -a no_client_boot=yes \ -a accept_licenses=yes \ <client name> __ 9. Lets briefly explore what youve just accomplished. Issue the lsnim -l <clien t name> command and notice your clients Cstate. Also notice extra resources at the bottom that have just been allocated to this client. # lsnim -l <client name> __ 10. Do a tail on the /etc/bootptab file. Notice the entry for your client. Al so notice the bf

field. This is the bootfile your client is using. Do a long listing on the /tftp boot directory and make sure this bootfile exists. # tail /etc/bootptab # ls -l /tftpboot __ 11. Finally, issue the showmount -e command to see what directories NFS has exported. # showmount -e __ 12. Since were doing a manual install, we need to go to the client site to con tinue this operation. This procedure changes depending on the hardware you have installed. If you know how to cause your client to boot over the network and contact your master, then do so now. If not, then please refer to the exercise appendix point ed out earlier by your instructor that shows you how to do this for your specific hardware. Find the appropriate appendix to show how to initiate the install from the clien t side. __ 13. Since this is a manual install, you have to answer all the standard BOS i nstall questions that come up. The two main options to watch out for are the install method (choose overwrite) and what disks to install onto (choose hdisk0). Once youve answered those two questions, let the rest of the answers default. Type the F1/1 key and enter to choose this display as the system console. (The answer depends on your type of console. Just follow the prompts at your console.) Wait a minute Type 1 and press Enter to have English during install 2. Change/Show Installation Settings and Install 1. System Settings 1. New and Complete Overwrite Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 3. Base (RTE) Install 3-7 V3.1 EXempty Double check that the hdisk0 is a chosen disk for the install. 0. Continue with Choices indicated above. (This should put you back at the main Installation and Settings menu). 0. Install with the Current Settings listed above. 1. Continue with Install __ 14. Congratulations! If youve made it this far, youre past the majority of the problems folks can potentially run across when doing a NIM install. __ 15. You can continue to monitor your progress at the NIM master. Type in lsni m -l <client name>. Notice not only the Cstate field, but the info field. In fact, if you end up with errors, you have an err field to also look at. If interested, refer to A ppendix D. Typical Base (RTE) Install Output. This appendix lists what normal installati on output looks like. Eventually your client should finish the install, change the bootlist to hdisk0 and reboot. # lsnim -l <client name> __ 16. Let s take a short break and then return to lecture while your client is

installing. END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 3-8 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 4. Defining Additional Base Install Reso urces 4-1 V3.1 EXempty Exercise 4. Defining Additional Base Install Resources What This Exercise is About This exercise allows the students to define three resources that can be used to customize and automate a base install. What You Should Be Able to Do Define an install bundle Define a post customization script Define a bosinst_data resource Introduction This exercise allows you to define three commonly used NIM resources that can be used to customize and automate a base install. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 4-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. We define three major things in this exercise: an installp_bundle resource , a script resource and a bosinst_data resource. __ 3. We start by defining our own installp_bundle resource. We could use a lot of the ones that are already out there when we defined our master, but we assume we want to create our own custom installp_bundle. First, make the directory /export/nim/installp_bundle. Then, inside this directory, create a file called m isc.bnd. Inside this file, include the following lines: # The first letter is a capital i, which means these are installp filesets. I:bos.content_list I:bos.cifs_fs __ 4. Now, lets define this resource to NIM. Navigate down under the Perform NIM Administration Tasks menu to find the Define a Resource menu. Use this menu to define this new installp_bundle resource. Give it the misc resource name. Point it to the file we just created. __ 5. Now, in order to use this bundle, we need to make sure that these filesets are available in our lpp_source. We use a couple of new commands to do this. First, issue the nim -o showres lpp_source53ML1 | grep bos.content_list command. If you dont get any output, then your fileset is not available in your lpp_source. Repea t the command for the bos.cifs_fs fileset. __ 6. You probably have determined that neither of these filesets are available in your current lpp_source. Thats because these filesets dont normally get transferred to the lpp_source when a default lpp_source is made. Hence, we have to add these

filesets in ourselves. We learn more about the following NIM update utility in a n upcoming lecture, but for now, just navigate down under the Perform NIM Software Installation and Maintenance Tasks menu to find a maintenance task called Add Software to an lpp_source. When asked for the input device, choose /usr/sys/inst.images/AIXinstalls. On the final dialogue screen you can either ad d your software packages directly, or easier yet, lets use our installp_bundle name to add software to our lpp_source. __ 7. Lets check once again to see if the code is now in our lpp_source by issuin g the nim -o showres lpp_source53ML1 | grep bos.content_list command. This time, you should see your new fileset added to this lpp_source. Try the command again for your bos.cifs_fs fileset. Again, you should now see your fileset appear. __ 8. Lets move on now to our script resource. To get started, lets make the /export/nim/myscripts directory. Then, inside this directory, create a shell scr ipt called simple.ksh. This script is going to do two simple things: make a new user called valerie and increase the /tmp filesystem by 10 MB. Ideally, its good to ec ho out what youre doing when you do it. Your code should look like the following: Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 4. Defining Additional Base Install Reso urces 4-3 V3.1 EXempty #!/usr/bin/ksh echo making valerie mkuser valerie echo Increasing /tmp by 10MB chfs -a size=+10M /tmp __ 9. Lets go into NIM now and define this resource as a script resource. Navigat e down under the Perform NIM Administration Tasks menu and find the menu to Define a Resource. However, this time, define a script resource. Give it the name simple. __ 10. Were down to our final task. This time, were going to create a bosinst_data resource. To get started, lets create the /export/nim/bosinst_data directory at o ur master. Since were using it for a base install, the best template to start from i s the one in our spot. Copy the bosinst.data located in the top of your spot to this n ew directory. Give it the name bosinst_data_rte. Change the permissions so that you can write to this file. __ 11. Edit the bosinst_data_rte file and make sure you check the following fiel ds: control_flow: CONSOLE = Default INSTALL_METHOD = overwrite PROMPT = no EXISTING_SYSTEM_OVERWRITE = yes RUN_STARTUP = no ACCEPT_LICENSES = yes target_disk_data: LOCATION = SIZE_MB = HDISKNAME = hdisk0 locale:

BOSINST_LANG = en_US CULTURAL_CONVENTION = en_US MESSAGES = en_US KEYBOARD = en_US __ 12. Now, go into NIM and define this bosinst_data resource. Give it the NIM n ame: bosinst_data_rte. __ 13. Issue the lsnim command to see your three new resources. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 4-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 __ 14. Congratulations!! Youve just defined three important resources used on a l ot of NIM installs. We use these on the Advanced Base Install Exercise thats coming up soon. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 4. Defining Additional Base Install Reso urces 4-5 V3.1 EXempty Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. We define three major things in this exercise: an installp_bundle resource , a script resource and a bosinst_data resource. __ 3. We start by defining our own installp_bundle resource. We could use a lot of the ones that are already out there when we defined our master, but we assume we want to create our own custom installp_bundle. First, make the directory /export/nim/installp_bundle. Then, inside this directory, create a file called m isc.bnd. Inside this file, include the following lines: # The first letter is a capital i, which means these are installp filesets. I:bos.content_list I:bos.cifs_fs # mkdir /export/nim/installp_bundle # cd /export/nim/installp_bundle # vi misc.bnd (include the lines from above) __ 4. Now, lets define this resource to NIM. Navigate down under the Perform NIM Administration Tasks menu to find the Define a Resource menu. Use this menu to define this new installp_bundle resource. Give it the misc resource name. Point it to the file we just created. # smitty nim (or nim_mkres) Perform NIM Administration Tasks Manage Resources Define a Resource Resource Type: installp_bundle Resource Name: misc Server of Resource: master Location of Resource: /export/nim/installp_bundle/misc.bnd OR # nim -o define -t installp_bundle \ -a server=master \ -a location=/export/nim/installp_bundle/misc.bnd \ misc __ 5. Now, in order to use this bundle, we need to make sure that these filesets

are available in our lpp_source. We use a couple of new commands to do this. First, issue the nim -o showres lpp_source53ML1 | grep bos.content_list command. If you Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 4-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 dont get any output, then your fileset is not available in your lpp_source. Repea t the command for the bos.cifs_fs fileset. # nim -o showres lpp_source53ML1 | grep bos.content_list # nim -o showres lpp_source53ML1 | grep bos.cifs_fs __ 6. You probably have determined that neither of these filesets are available in your current lpp_source. Thats because these filesets dont normally get transferred to the lpp_source when a default lpp_source is made. Hence, we have to add these filesets in ourselves. We learn more about the following NIM update utility in a n upcoming lecture, but for now, just navigate down under the Perform NIM Software Installation and Maintenance Tasks menu to find a maintenance task called Add Software to an lpp_source. When asked for the input device, choose /usr/sys/inst.images/AIXinstalls. On the final dialogue screen you can either ad d your software packages directly, or easier yet, lets use our installp_bundle name to add software to our lpp_source. # smitty nim (or nim_update_add) Perform Software Installation and Maintenance Tasks Software Maintenance and Utilities Add Software to an lpp_source TARGET lpp_source: lpp_source53ML1 Media, directory or lpp_source to copy images from: /usr/sys/inst.images/AIXinstalls INSTALLP BUNDLE containing packages to add: misc OR # nim -o update -a source=/usr/sys/inst.images/AIXinstalls \ -a installp_bundle=misc \ -a gencopy_flags=X \ lpp_source53ML1 __ 7. Lets check once again to see if the code is now in our lpp_source by issuin g the nim -o showres lpp_source53ML1 | grep bos.content_list command. This time, you should see your new fileset added to this lpp_source. Try the command again for your bos.cifs_fs fileset. Again, you should now see your fileset appear. # nim -o showres lpp_source53ML1 | grep bos.content_list # nim -o showres lpp_source53ML1 | grep bos.cifs_fs __ 8. Lets move on now to our script resource. To get started, lets make the /export/nim/myscripts directory. Then, inside this directory, create a shell scr ipt Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 4. Defining Additional Base Install Reso urces 4-7 V3.1 EXempty called simple.ksh. This script is going to do two simple things: make a new user called valerie and increase the /tmp filesystem by 10 MB. Ideally, its good to ec ho out what youre doing when you do it. Your code should look like the following:

#!/usr/bin/ksh echo making valerie mkuser valerie echo Increasing /tmp by 10MB chfs -a size=+10M /tmp # mkdir /export/nim/myscripts # cd /export/nim/myscripts # vi simple.ksh (include the lines from above) __ 9. Lets go into NIM now and define this resource as a script resource. Navigat e down under the Perform NIM Administration Tasks menu and find the menu to Define a Resource. However, this time, define a script resource. Give it the name simple. # smitty nim (or nim_mkres) Perform NIM Administration Tasks Manage Resources Define a Resource Resource Type: script Resource Name: simple Server of Resource: master Location of Resource: /export/nim/myscripts/simple.ksh OR # nim -o define -t script \ -a server=master \ -a location=/export/nim/myscripts/simple.ksh \ simple __ 10. Were down to our final task. This time, were going to create a bosinst_data resource. To get started, lets create the /export/nim/bosinst_data directory at o ur master. Since were using it for a base install, the best template to start from i s the one in our spot. Copy the bosinst.data located in the top of your spot to this n ew directory. Give it the name bosinst_data_rte. Change the permissions so that you can write to this file. # mkdir /export/nim/bosinst_data Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 4-8 Introduction to NIM Copyright IBM Corp. 1996, 2005 # cd /export/nim/bosinst_data # cp /export/nim/spot/spot53ML1/bosinst.data ./bosinst_data_rte # chmod 755 bosinst_data_rte __ 11. Edit the bosinst_data_rte file and make sure you check the following fiel ds: control_flow: CONSOLE = Default INSTALL_METHOD = overwrite PROMPT = no EXISTING_SYSTEM_OVERWRITE = yes RUN_STARTUP = no ACCEPT_LICENSES = yes target_disk_data: LOCATION = SIZE_MB = HDISKNAME = hdisk0 locale: BOSINST_LANG = en_US CULTURAL_CONVENTION = en_US MESSAGES = en_US KEYBOARD = en_US

# vi bosinst_data_rte (include the changes in the lines above) __ 12. Now, go into NIM and define this bosinst_data resource. Give it the NIM n ame: bosinst_data_rte. # smitty nim_mkres Resource Type: bosinst_data Resource Name: bosinst_data_rte Server of Resource: master Location of Resource: /export/nim/bosinst_data/bosinst_data_rte OR # nim -o define -t bosinst_data \ -a server=master \ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 4. Defining Additional Base Install Reso urces 4-9 V3.1 EXempty -a location=/export/nim/bosinst_data/bosinst_data_rte \ bosinist_data_rte __ 13. Issue the lsnim command to see your three new resources. lsnim __ 14. Congratulations!! Youve just defined three important resources used on a l ot of NIM installs. We use these on the Advanced Base Install Exercise thats coming up soon. END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 4-10 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 5. Advanced Base Install 5-1 V3.1 EXempty Exercise 5. Advanced Base Install What This Exercise is About This exercise allows the students to do another base RTE install. However, this time, they automate it and include a bundle and a post customization script. What You Should Be Able to Do Perform an automated install Utilize resources to customize a base RTE install Introduction This exercise presumes you have completed the exercise that defines three resources: an installp_bundle, a script and a bosinst_data. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 5-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. This exercise presumes you have already defined three resources: a misc installp_bundle, a simple script and a bosinst_rte bosinst_data resource. If you have not completed these resources, please refer to the last exercise and complete th em at this time.

__ 3. You can monitor your install from either the master or client site. Howeve r, during the initial part of the install it is nice to have the clients console viewable. If y oure using stand-alone AIX machines, your client console is probably already viewable. If so, skip this step. If using an HMC and you dont already have a console window open to your client, do so at this time. Remember, though, you ca nt open another terminal window until the prior connection was closed. __ 4. We need a few things to automate an install: 1) a NIM client that is up an d running, 2) a bosinst_data resource with the prompt field set to no and 3) when we reach the smitty nim_bosinst screen, we need to answer yes to the Initiate the reboot and install now? question. With that in mind, lets continue. __ 5. Go to the smitty nim_bosinst menu at the master and start your install. Ch oose your client as the install target. Choose the same lpp_source and SPOT you did before. This time, include your new bosinst_data_rte bosinst_data resource, your new misc installp_bundle resource and your new simple script. Make sure you say yes to the Initiate the reboot and install now? prompt. __ 6. The first thing to notice is a message thats broadcast to all the users on the client system. You can tell that the reboot occurs soon and the install follows. __ 7. While youre waiting, issue the lsnim -l <client name> command at your maste r. After waiting for 2-3 minutes, you eventually see the Cstate change to Base Operating System installation is being performed. This happens when the BOS install program starts to run. This is also about the time youll notice the info field appear for the first time. If this info field stops at the prompting_for_data_at _console value then your bosinst.data did not work well. You have to manually go to your clients console and answer the questions to finish the install. If, instead, you eventually see the info field change to BOS install X% complete, youve made it past the bosinst_data resource. The normal install is starting. If so, you re re ady to take a short break and then return to lecture. __ 8. When your install is complete, you can double check that your filesets wer e installed and that your script ran. You can choose to do most of these checks at either the master or the client. If performing the checks at the master, use the nim -o lslpp and nim -o showlog commands. Well learn more about the nim -o lslpp command later. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 5. Advanced Base Install 5-3 V3.1 EXempty Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. This exercise presumes you have already defined three resources: a misc installp_bundle, a simple script and a bosinst_rte bosinst_data resource. If you have not completed these resources, please refer to the last exercise and complete th em at this time. __ 3. You can monitor your install from either the master or client site. Howeve

r, during the initial part of the install it is nice to have the clients console viewable. If y oure using stand-alone AIX machines, your client console is probably already viewable. If so, skip this step. If using an HMC and you dont already have a console window open to your client, do so at this time. Remember, though, you ca nt open another terminal window until the prior connection was closed. Double-click your wsm icon at your PC Enter your HMC hostname or IP Enter your HMCs login ID and password Open up your HMC machine at the left if necessary. Open up the Server and Partition section at the left. Double-click the Server Management icon at the left. If necessary, open up your managed machine at the right. Open up the partitions section under your managed machine. Highlight your partition. Right-click your partition and choose the menu item to close the connection. (in case you still had an old one open) Right-click your partition and choose the menu item to open a terminal window. __ 4. We need a few things to automate an install: 1) a NIM client that is up an d running, 2) a bosinst_data resource with the prompt field set to no and 3) when we reach the smitty nim_bosinst screen, we need to answer yes to the Initiate the reboot and install now? question. With that in mind, lets continue. __ 5. Go to the smitty nim_bosinst menu at the master and start your install. Ch oose your client as the install target. Choose the same lpp_source and SPOT you did before. This time, include your new bosinst_data_rte bosinst_data resource, your new misc installp_bundle resource and your new simple script. Make sure you say yes to the Initiate the reboot and install now? prompt. # smitty nim (or nim_bosinst) Perform NIM Software Installation and Maintenance Tasks Install and Update Software Install the Base Operating System on Standalone Clients Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 5-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 Target: <client name> Type: rte LPP_SOURCE: lpp_source53ML1 SPOT: spot53ML1 BOSINST DATA: bosinst_data_rte Customization Script: simple Initiate reboot and installation now? yes Additional Bundles to install: misc OR # nim -o bos_inst -a spot=spot53ML1 \ -a lpp_source=lpp_source53ML1 \ -a bosinst_data=bosinst_data_rte \ -a script=simple \ -a installp_bundle=misc \ <client name> __ 6. The first thing to notice is a message thats broadcast o all the users on t he client system. You can tell that the reboot occurs soon and the install follows. __ 7. While youre waiting, issue the lsnim -l <client name> command at your maste r.

After waiting for 2-3 minutes, you eventually see the Cstate change to Base Operating System installation is being performed. This happens when the BOS install program starts to run. This is also about the time youll notice the info field appear for the first time. If this info field stops at the prompting_for_data_at _console value then your bosinst.data did not work well. You have to manually go to your clients console and answer the questions to finish the install. If, instead, you eventually see the info field change to BOS install X% complete, youve made it past the bosinst_data resource. The normal install is starting. If so, you re re ady to take a short break and then return to lecture. # lsnim -l <client name> __ 8. When your install is complete, you can double check that your filesets wer e installed and that your script ran. You can choose to do most of these checks at either the master or the client. If performing the checks at the master, use the nim -o lslpp and nim -o showlog commands. We learn more about the nim -o lslpp command later. At master: nim -o showlog -a log_type=bosinst <client name> | more nim -o showlog -a log_type=script <client name> Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 5. Advanced Base Install 5-5 V3.1 EXempty nim -o lslpp <client name> | grep bos.cifs_fs nim -o lslpp <client name> | grep bos.content_list OR At client: alog -t bosinst -o | more view /var/adm/ras/nim.script | more # lslpp -L | grep bos.cifs_fs # lslpp -L | grep bos.content_list # lsuser valerie # df -m END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 5-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 6. Using NIM for Disaster Recovery 6-1 V3.1.0.1 EXempty Exercise 6. Using NIM for Disaster Recovery What This Exercise is About This exercise allows the students to do a NIM client mksysb backup and restore. What You Should Be Able to Do Define a NIM mksysb resource Define a bosinst_data resource to be used on a mksysb install Perform a mksysb install Introduction This exercise presumes you have a running NIM client to backup. Student Exercises Course materials may not be reproduced in whole or in part

without the prior written permission of IBM. 6-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. You back up your client to the /export/nim/mksysb directory at your master site. First, this means that you need to create this directory at the master site. We happen to know that our client is really small. It s probably less than 1 GB in size. So, run a df -m command at your master site and make sure you have about 1 GB free in your /export/nim filesystem. __ 3. Back up your client to your master site by using the Define a Resource scr een in smit. Give it the name <client name>_mksysb. Put it in the file: /export/nim/mksysb/<client name>_mksysb. Be sure to use the option to back it up now and list which client to back up. Take all other defaults. While the backup is starting, double check that your AVAILABLE number is bigger than your REQUIRED number. After making sure you have enough space for the backup, continue on with the next step. __ 4. While you re waiting, you can prepare for your upcoming mksysb install. Yo u could either restore your mksysb by manually answering the BOS install questions that come up at your client site or by using a bosinst_data resource. For this exerci se, you use a bosinst_data resource. Start with your pre-existing bosinst_data resource in the /export/nim/bosinst_data directory that you created earlier. Cop y it over to a file named bosinst_data_mksysb. Now, edit this file. Most of these fie lds work the same on a mksysb install as on an RTE install. Make sure the following fields are set up to restore to the same client as shown. Then, define this file to smit as a bosinst_data resource. Give it the resource name: bosinst_data_mksysb. RECOVER_DEVICES = yes or Default IMPORT_USER_VGS = yes or Default __ 5. Lets hope your mksysb backup is done. Before using it, quickly run a couple of lsmksysb commands against the physical mksysb backup file to preview general information about the backup and to quickly list the table of contents for this backup. Make sure it looks like the backup you want to use. lsmksysb -l -f /export/nim/mksysb/<client name>_mksysb | more lsmksysb -f /export/nim/mksysb/<client_name>_mksysb | more __ 6. We re now ready to do our mksysb restore (or as NIM calls it: a mksysb ins tall). In real life, you d probably have to do a manual install on this client since the c lient is probably not up and running. However, to save a little bit of time in this exerc ise, you re going to do an automated push install. Go into smitty nim_bosinst. Be sur e to choose your client, your spot and your bosinst_data resources. Since we re doing a push, let the Initiate reboot and install now? field default to yes. Let everythin g else default as well. Student Exercises Course materials may not be reproduced in whole or in part

without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 6. Using NIM for Disaster Recovery 6-3 V3.1.0.1 EXempty __ 7. Monitor your install using the lsnim -l <client name> command. If you have good resources, within about 3-4 minutes you should see your info field show up. It eventually starts to show BOS install X% complete. Once you ve reached this stage, your install will probably be OK. If desired, double check your client s console and LED display. __ 8. Take about a 10 minute break. When your install totally completes, you can view it using either NIM s showlog facility at your master and/or by just telnetting into the client and looking around. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 6-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. You back up your client to the /export/nim/mksysb directory at your master site. First, this means that you need to create this directory at the master site. We happen to know that our client is really small. It s probably less than 1 GB in size. So, run a df -m command at your master site and make sure you have about 1 GB free in your /export/nim filesystem. # mkdir /export/nim/mksysb # df -m __ 3. Back up your client to your master site by using the Define a Resource scr een in smit. Give it the name <client name>_mksysb. Put it in the file: /export/nim/mksysb/<client name>_mksysb. Be sure to use the option to back it up now and list which client to back up. Take all other defaults. While the backup is starting, double check that your AVAILABLE number is bigger than your REQUIRED number. After making sure you have enough space for the backup, continue on with the next step. # smitty nim (or nim_mkres) Perform NIM Administration Tasks Manage Resources Define a Resource Resource Type: mksysb Resource Name: <client name>_mksysb Server of Resource: master Location or Resource: /export/nim/mksysb/<client name>_mksysb CREATE System Backup image? yes NIM Client to backup: <client name> OR # nim -o define -t mksysb \ -a server=master \ -a location=/export/nim/mksysb/<client name>_mksysb \ -a mk_image=yes \ -a source=<client name> \ <client name>_mksysb __ 4. While you re waiting, you can prepare for your upcoming mksysb install. Yo u could either restore your mksysb by manually answering the BOS install questions that

Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 6. Using NIM for Disaster Recovery 6-5 V3.1.0.1 EXempty come up at your client site or by using a bosinst_data resource. For thi s exercise, you use a bosinst_data resource. Start with your pre-existing bosinst_data resource in the /export/nim/bosinst_data directory that you created earlier. Cop y it over to a file named bosinst_data_mksysb. Now, edit this file. Most of these fie lds work the same on a mksysb install as on an RTE install. Make sure the following fields are set up to restore to the same client as shown. Then, define this file to smit as a bosinst_data resource. Give it the resource name: bosinst_data_mksysb. RECOVER_DEVICES = yes or Default IMPORT_USER_VGS = yes or Default # cd /export/nim/bosinst_data # cp bosinst_data_rte bosinst_data_mksysb # vi bosinst_data_mksysb # smitty nim_mkres Resource Type: bosinst_data Resource Name: bosinst_data_mksysb Server of Resource: master Location of Resource: /export/nim/bosinst_data/bosinst_data_mksysb OR # nim -o define -t bosinst_data \ -a server=master \ -a location=/export/nim/bosinst_data/bosinst_data_mksysb \ bosinst_data_mksysb __ 5. Lets hope your mksysb backup is done. Before using it, quickly run a couple of lsmksysb commands against the physical mksysb backup file to preview general information about the backup and to quickly list the table of contents for this backup. Make sure it looks like the backup you want to use. lsmksysb -l -f /export/nim/mksysb/<client name>_mksysb | more lsmksysb -f /export/nim/mksysb/<client_name>_mksysb | more __ 6. We re now ready to do our mksysb restore (or as NIM calls it: a mksysb ins tall). In real life, you d probably have to do a manual install on this client since the c lient is probably not up and running. However, to save a little bit of time in this exerc ise, you re going to do an automated push install. Go into smitty nim_bosinst. Be sur e to choose your client, your spot and your bosinst_data resources. Since we re doing a Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 6-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 push, let the Initiate reboot and install now? field default to yes. Let everythin g else default as well. # smitty nim_bosinst Target: <client name> Type: mksysb Mksysb: <client name>_mksysb

SPOT: spot53ML1 BOSINST_DATA: bosinst_data_mksysb OR # nim -o bos_inst \ -a source=mksysb \ -a mksysb=<client name>_mksysb \ -a spot=spot53ML1 \ -a bosinst_data=bosinst_data_mksysb \ <client name> __ 7. Monitor your install using the lsnim -l <client name> command. If you have good resources, within about 3-4 minutes you should see your info field show up. It eventually starts to show BOS install X% complete. Once you ve reached this stage, your install will probably be OK. If desired, double check your client s console and LED display. # lsnim -l <client name> __ 8. Take about a 10 minute break. When your install totally completes, you can view it using either NIM s showlog facility at your master and/or by just telnetting into the client and looking around. At master: # nim -o showlog -a log_type=bosinst <client name> | more (page down to the last set of install output) At Client: # lsuser valerie # lspv # df -m # lslpp -L | grep cifs Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 6. Using NIM for Disaster Recovery 6-7 V3.1.0.1 EXempty END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 6-8 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 7. LPP_SOURCE and SPOT Management 7-1 V3.1 EXempty Exercise 7. LPP_SOURCE and SPOT Management What This Exercise is About This exercise reinforces lpp_source and SPOT management activities. It allows the students to create a new lpp_source and SPOT. It also allows the students to update the SPOT. What You Should Be Able to Do Create a new lpp_source Create a new SPOT Update a SPOT List information inside a SPOT and lpp_source. Introduction This exercise presumes you have a current lpp_source and SPOT at the 5300-01 level. In this exercise, we create a new lpp_source and SPOT at the 5300-02 level. In the next exercise, we use this information to do a maintenance-level update on our client.

Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 7-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. In this exercise you go through the steps to update your lpp_source and SP OT code to handle clients that are upgrading from 5300-01 to 5300-02. To start out this procedure, you would first have to determine what level of code you already have available in your current lpp_source. We already happen to know our lpp_source53ML1 lpp_source is at the 5300-01 level. However, what if you didnt know that? Lets try a few commands listed below and see which ones tell us what level of code we have in our lpp_source53ML1 lpp_source. Remember, the 5300-01 Recommended Maintenance Package line may not always appear on your fix report if you retrieved your code from IBMs Web site. Hence, also knowin g that bos.rte.install is at the 5.3.0.11 fix level inside the 5300-01 maintenance package is useful. Highlight below the commands you find the most useful. lsnim -l lpp_source53ML1 nim -o showres -a instfix_flags=-T lpp_source53ML1 | grep Maint nim -o showres lpp_source53ML1 | grep bos.rte.install __ 3. Now that weve established that our current maintenance level is 5300-01 we need to get our5300-02 maintenance package. We can either get a 5300-02 update CD from IBM or go out to IBMs fix central Web site and download 5300-01 to 5300-02 delta maintenance level code. Fortunately, weve already taken the effort to download this delta code from IBMs Web site for you. Weve also unzipped and untarred it. Ideally we should have placed it in the /export/nim/lpp_source/stag edir directory to match what we taught in lecture. However, due to the fact that the /export/nim filesystem wasnt made yet when we downloaded this code, we placed it instead in the /usr/sys/inst.images/53ML2 directory. __ 4. Take a look inside this /usr/sys/inst.images/53ML2 directory before contin uing. Notice all of the UXXXXX.bff PTF fix files. Notice also the README.5300-02 file. This is a good indication that you have 5300-02 update code in this directory. S ince you see UXXXXX.bff files versus a directory tree of normal fileset names (that i s, bos.rte.install), it s also an indication that you ve downloaded your code from IBM s Web site versus using an AIX Update CD. __ 5. Were now ready to create our new lpp_source. We start this procedure by put ting our 5300-01 base code into this new lpp_source. Use the smitty nim_mkres panel t o create this new lpp_source. Call it lpp_source53ML2. Place it in the /export/nim/lpp_source/lpp_source53ML2 directory on the master. Use your lpp_source53ML1 lpp_source as your input source. Be sure to include all packages from your source. __ 6. Now lets update this lpp_source to the 5300-02 level. Use NIMs update utilit y to do this. Use your /usr/sys/inst.images/53ML2 directory as your source. Choose to add all packages. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 7. LPP_SOURCE and SPOT Management 7-3

V3.1 EXempty __ 7. Lets view the level of our new lpp_source by using the showres oper ation code as shown below. Notice that since we downloaded code from the Web that our 5300-02 Recommended Maintenance Package line does not show up with the first commands output. The code is definitely at 5300-02 level, but we cant determine that easily. However, since we happen to know that the bos.rte.install fileset s hould be at the 5.3.0.20 level when were at the 5300-02 maintenance level, we can reasonably conclude the maintenance level is at 5300-02 if we notice that the bos.rte.install is at 5.3.0.20. (Goodness! That almost sounds like circular logi c!). So, list the bos.rte.install fileset and see what level its at. Then, from that, dete rmine if this lpp_source is at the 5300-02 level. nim -o showres -a instfix_flags=-T lpp_source53ML2 | grep Maint nim -o showres lpp_source53ML2 | grep bos.rte.install __ 8. Its a good idea when adding new fix code into an lpp_source to clean up any extraneous code by using NIMs lppmgr utility. Other than turning the preview option off, use the defaults on smits nim_lppmgr screen. When done, view the output. Notice if any filesets were selected for removal. __ 9. It looks like we have a good lpp_source at the 5300-02 level. The next ste p is to update our NIM master to the 5300-02 level. Although we haven t learned this technique yet, it s pretty simple. We merely update our master the same way we l l update our client in the next lab. Go under the Installation section of smitty n im and choose first to install the bos.rte.install fileset. Then do an Update All on yo ur master. Obviously your target is your master. Use the new lpp_source53ML2 lpp_source as your input source. __ 10. Lets use this new lpp_source53ML2 lpp_source to create a brand new spot at the 5300-02 level. Call this spot spot53ML2. Put it in the /export/nim/spot director y on the master. Commit your code. For the sake of time, choose not to verify your in stall. __ 11. While were waiting for this new SPOT to complete, lets explore how to list the contents of any spot. Open up another terminal session. Issue the following commands to view the contents of your spot53ML1 spot. Find out which commands you feel might be most useful to you. Watch out on the lslpp listing. The defaul t ("-la") is to display committed and applied filesets, including superseded files ets. The "-L" option gives you just the latest fileset level. lsnim -l spot53ML1 nim -o fix_query spot53ML1 | grep ML nim -o showres spot53ML1 | grep bos.rte.install nim -o lslpp spot53ML1 | more nim -o lslpp -alslpp_flags=-L spot53ML1 | more __ 12. Optionally (only if time permits) when your SPOT is ready, issue the foll owing commands to verify the level this new spot is at. Also, do a quick list of the software installed inside. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 7-4 Introduction to NIM Copyright IBM Corp. 1996, 2005

lsnim -l spot53ML2 nim -o fix_query spot53ML2 | grep ML nim -o showres spot53ML2 | grep bos.rte.install nim -o lslpp spot53ML2 | more nim -o lslpp -alslpp_flags=-L spot53ML2 | more Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 7. LPP_SOURCE and SPOT Management 7-5 V3.1 EXempty Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. In this exercise you go through the steps to update your lpp_source and SP OT code to handle clients that are upgrading from 5300-01 to 5300-02. To start out this procedure, you would first have to determine what level of code you already have available in your current lpp_source. We already happen to know our lpp_source53ML1 lpp_source is at the 5300-01 level. However, what if you didnt know that? Lets try a few commands listed below and see which one(s) tell us what level of code we have in our lpp_source53ML1 lpp_source. Remember, the 5300-01 Recommended Maintenance Package line may not always appear on your fix report if you retrieved your code from IBMs Web site. Hence, also knowin g that bos.rte.install is at the 5.3.0.11 fix level inside the 5300-01 maintenance package is useful. Highlight below the commands you find the most useful. lsnim -l lpp_source53ML1 nim -o showres -a instfix_flags=-T lpp_source53ML1 | grep Maint nim -o showres lpp_source53ML1 | grep bos.rte.install __ 3. Now that weve established that our current maintenance level is 5300-01 we need to get our5300-02 maintenance package. We can either get a 5300-02 update CD from IBM or go out to IBMs fix central Web site and download 5300-01 to 5300-02 delta maintenance level code. Fortunately, weve already taken the effort to download this delta code from IBMs Web site for you. Weve also unzipped and untarred it. Ideally we should have placed it in the /export/nim/lpp_source/stag edir directory to match what we taught in lecture. However, due to the fact that the /export/nim filesystem wasnt made yet when we downloaded this code, we placed it instead in the /usr/sys/inst.images/53ML2 directory. __ 4. Take a look inside this /usr/sys/inst.images/53ML2 directory before contin uing. Notice all of the UXXXXX.bff PTF fix files. Notice also the README.5300-02 file. This is a good indication that you have 5300-02 update code in this directory. S ince you see UXXXXX.bff files versus a directory tree of normal fileset names (that i s, bos.rte.install), it s also an indication that you ve downloaded your code from IBM s Web site versus using an AIX Update CD. # cd /usr/sys/inst.images/53ML2 # ls | more __ 5. Were now ready to create our new lpp_source. Well start this procedure by putting our 5300-01 base code into this new lpp_source. Use the smitty nim_mkres panel to create this new lpp_source. Call it lpp_source53ML2. Place it in the /export/nim/lpp_source/lpp_source53ML2 directory on the master. Use your lpp_source53ML1 lpp_source as your input source. Be sure to include all packages from your source. Student Exercises Course materials may not be reproduced in whole or in part

without the prior written permission of IBM. 7-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 # smitty nim_mkres Resource Type: lpp_source Resource Name: lpp_source53ML2 Server of Resource: master Location of Resource: /export/nim/lpp_source/lpp_source53ML2 Source of Install Images: lpp_source53ML1 Names of Option Packages: all OR # nim -o define -t lpp_source \ -a source=lpp_source53ML1 \ -a server=master \ -a location=/export/nim/lpp_source/lpp_source53ML2 \ -a packages=all \ lpp_source53ML2 __ 6. Now lets update this lpp_source to the 5300-02 level. Use NIMs update utilit y to do this. Use your /usr/sys/inst.images/53ML2 directory as your source. Choose to add all packages. # smitty nim (or nim_update_add) Perform NIM Software Installation and Maintenance Tasks Software Maintenance and Utilities Add Software to an lpp_source TARGET lpp_source: lpp_source53ML2 Media, directory or lpp_source to copy images from: /usr/sys/inst.images/53ML2 SOFTWARE Packages to add: all OR # nim -o update \ -a source=/usr/sys/inst.images/53ML2 \ -a packages=all \ -a gencopy_flags=X \ lpp_source53ML2 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 7. LPP_SOURCE and SPOT Management 7-7 V3.1 EXempty __ 7. Lets view the level of our new lpp_source by using the showres oper ation code as shown below. Notice that since we downloaded code from the Web that our 5300-02 Recommended Maintenance Package line does not show up with the first commands output. The code is definitely at 5300-02 level, but we cant determine that easily. However, since we happen to know that the bos.rte.install fileset s hould be at the 5.3.0.20 level when were at the 5300-02 maintenance level, we can reasonably conclude the maintenance level is at 5300-02 if we notice that the bos.rte.install is at 5.3.0.20. (Goodness! That almost sounds like circular logi c!). So, list the bos.rte.install fileset and see what level its at. Then, from that, dete rmine if this lpp_source is at the 5300-02 level. nim -o showres -a instfix_flags=-T lpp_source53ML2 | grep Maint nim -o showres lpp_source53ML2 | grep bos.rte.install __ 8. Its a good idea when adding new fix code into an lpp_source to clean up any extraneous code by using NIMs lppmgr utility. Other than turning the preview opti on off, use the defaults on smits nim_lppmgr screen. When done, view the output. Notice if any filesets were selected for removal.

# smitty nim (or nim_lppmgr) Perform NIM Software Installation and Maintenance Tasks Software Maintenance and Utilities Eliminate Unnecessary Software Images in an lpp_source TARGET lpp_source: lpp_source53ML2 Preview Only? no Take all other defaults OR # nim -o lppmgr \ -a lppmgr_flags="-bu -x -k en_US -e -r" \ lpp_source53ML2 __ 9. It looks like we have a good lpp_source at the 5300-02 level. The next ste p is to update our NIM master to the 5300-02 level. Although we haven t learned this technique yet, it s pretty simple. We merely update our master the same way we l l update our client in the next lab. Go under the Installation section of smitty n im and choose first to install the bos.rte.install fileset. Then do an Update All on yo ur master. Obviously your target is your master. Use the new lpp_source53ML2 lpp_source as your input source. # smitty nim_inst_latest Target: master LPP_SOURCE: lpp_source53ML2 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 7-8 Introduction to NIM Copyright IBM Corp. 1996, 2005 Software to Install: bos.rte.install # smitty nim (or nim_update_all) Perform NIM Software Installation and Maintenance Tasks Install and Update Software Update Installed Software to Latest level (Update All) Target: master LPP__SOURCE: lpp_source53ML2 --------------------------------------------- OR ----------------------------------------- # nim -o cust \ -a lpp_source=lpp_source53ML2 \ -a filesets=bos.rte.install \ -a installp_flags= -acgNX \ master # nim -o cust \ -a lpp_source=lpp_source53ML2 \ -a fixes=update_all \ -a installp_flags= -acgNX \ master __ 10. Lets use this new lpp_source53ML2 lpp_source to create a brand new spot at the 5300-02 level. Call this spot spot53ML2. Put it in the /export/nim/spot director y on the master. Commit your code. For the sake of time, choose not to verify your in stall. # smitty nim_mkres Resource Type: spot Resource Name: spot53ML2 Server of Resource: master Source of Install Images: lpp_source53ML2 Location of Resource: /export/nim/spot

COMMIT Software Updates? yes SAVE replaced files? no OR # nim -o define -t spot \ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 7. LPP_SOURCE and SPOT Management 7-9 V3.1 EXempty -a server=master \ -a location=/export/nim/spot \ -a source=lpp_source53ML2 \ -a installp_flags= -XacNg \ spot53ML2 __ 11. While were waiting for this new SPOT to complete, lets explore how to list the contents of any spot. Open up another terminal session. Issue the following commands to view the contents of your spot53ML1 spot. Find out which commands you feel might be most useful to you. Watch out on the lslpp listing. The defaul t ("-la") is to display committed and applied filesets, including superseded files ets. The "-L" option gives you just the latest fileset level. lsnim -l spot53ML1 nim -o fix_query spot53ML1 | grep ML nim -o showres spot53ML1 | grep bos.rte.install nim -o lslpp spot53ML1 | more nim -o lslpp -alslpp_flags=-L spot53ML1 | more __ 12. Optionally (only if time permits) when your SPOT is ready, issue the foll owing commands to verify the level this new spot is at. Also, do a quick list of the software installed inside. lsnim -l spot53ML2 nim -o fix_query spot53ML2 | grep ML nim -o showres spot53ML2 | grep bos.rte.install nim -o lslpp spot53ML2 | more nim -o lslpp -alslpp_flags=-L spot53ML2 | more END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 7-10 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Solutions 2. The lsnim command is not helpful. The first showres command can be helpful if yo ur code came from an update CD (versus an upgrade from the Web). The last showres command can be helpful if you happen to know a key fileset level thats available in a particular maintenance level package. 8. a. Several filesets were removed, including duplicate, superseded and superfluou s language filesets. Removing these filesets consisted of about 50MB of space savi ngs. 11 and 12. The oslevel_r field on the lsnim -l spot_name report is very useful. You can als o note the maintenance level on the fix_query report. Or, you could identify a key file set (that

is, bos.rte.install in our case) and see what level it was at. Finally, you can use the lslpp listings to view all software installed. Notice that the default listing gives s uperseded and applied filesets. The -L flag shows just the latest fileset level. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 8. Ongoing Client Updates 8-1 V3.1.0.1 EXempty Exercise 8. Ongoing Client Updates What This Exercise is About This exercise lists software installed at a client, installs and removes software and finally installs a new maintenance level update. What You Should Be Able to Do List software installed at a client Install and remove software at a client Install a maintenance level update at a client Introduction This exercise presumes you ve completed the LPP_SOURCE and SPOT Management exercise. It uses the new lpp_source created during this prior exercise. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 8-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Exercise Instructions __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. Let s start out listing the software installed at your client site. You ca n do this from the command line or from smit. We use the command line here. Be careful to quit the more utility using a q versus a <ctrl-c> key sequence. Otherwise you ha ve to reset your terminal with the "stty sane" command. __ 3. Now, let s list the installed fixes at this client site. Again, you can us e the command line or smit to do this. We use the nim -o fix_query command. Again, be careful to quit the more utility using the q key versus a <ctrl-c> key sequence. __ 4. We re now ready to install the bos.terminfo.att.data fileset on your clien t. Be sure to use your old lpp_source53ML1 lpp_source. (We haven t updated our client to 5300-02 yet). In order to save time, choose not to verify your install. Use smit to do all of this. Once done, list the software at your client to make sure your softw are was installed. __ 5. Now let s remove this bos.terminfo.att.data fileset from our client. Be su re to change the preview flag to no. Again, list your client s installed software to m ake sure it s successfully removed. __ 6. OK. We re now ready to upgrade our client to 5300-02. First, let s install the bos.rte.install fileset onto your client from our lpp_source53ML2 lpp_source. __ 7. Now, let s use NIM s update_all operation to update your client to 5300-02 . Use your new lpp_source53ML2 lpp_source as the input source. This update probably takes about 3-4 minutes to complete. (Note: Typically we would also perform a verification of our filesets here, but

we ll forego this extra step in order to save time.) __ 8. Issue the oslevel -r command at your client to verify it s indeed at the 5 300-02 level. Optionally (only if time permits) shutdown and reboot your client in order for t hese changes to officially take effect. (Note: you could have used a script resource to do your client s shutdown/reboot automatically if you did it using the at utility.) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 8. Ongoing Client Updates 8-3 V3.1.0.1 EXempty Exercise Instructions with Hints __ 1. Log in to your AIX NIM master using the instructions provided by your inst ructor. __ 2. Let s start out listing the software installed at your client site. You ca n do this from the command line or from smit. We use the command line here. Be careful to quit the more utility using a q versus a <ctrl-c> key sequence. Otherwise you ha ve to reset your terminal with the "stty sane" command. # nim -o lslpp -alslpp_flags=-L <client name> | more __ 3. Now, let s list the installed fixes at this client site. Again, you can us e the command line or smit to do this. We ll use the nim -o fix_query command. Again, be careful to quit the more utility using the q key versus a <ctrl-c> key sequence. # nim -o fix_query <client name> | more __ 4. We re now ready to install the bos.terminfo.att.data fileset on your clien t. Be sure to use your old lpp_source53ML1 lpp_source. (We haven t updated our client to 5300-02 yet). In order to save time, choose not to verify your install. Use smit to do all of this. Once done, list the software at your client to make sure your softw are was installed. # smitty nim (or nim_inst_latest) Perform NIM Software Installation and Maintenance Tasks Install and Update Software Install Software Target: <client name> LPP_SOURCE: lpp_source53ML1 Software to Install: bos.terminfo.att.data # nim -o lslpp-alslpp_flags="-L" <client name> | grep att.data ---------------------------------------- OR ------------------------------------------------- # nim -o cust \ -a lpp_source=lpp_source53ML1 \ -a filesets=bos.terminfo.att.data \ -a accept_licenses=yes \ -a installp_flags= -acNgX \ <client name> # nim -o lslpp -alslpp_flags=-L <client name> | grep att.data __ 5. Now let s remove this bos.terminfo.att.data fileset from our client. Be su re to change the preview flag to no. Again, list your client s installed software to m ake sure it s successfully removed.

Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 8-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 # smitty nim (or nim_remove) Perform NIM Software Installation and Maintenance Tasks Software Maintenance and Utilities Remove Installed Software Target: <client name> Software Names: bos.terminfo.att.data PREVIEW only? no # nim -o lslpp -alslpp_flags=-L <client name> | grep att.data ---------------------------------------- OR ------------------------------------------------- # nim -o maint \ -a filesets=bos.terminfo.att.data \ -a installp_flags= -Iu \ <client name> # nim -o lslpp -alslpp_flags=-L <client name> | grep att.data __ 6. OK. We re now ready to upgrade our client to 5300-02. First, let s install the bos.rte.install fileset onto your client from our lpp_source53ML2 lpp_source. # smitty nim_inst_latest Target: <client name> LPP_SOURCE: lpp_source53ML2 Software to Install: bos.rte.install OR # nim -o cust \ -a lpp_source=lpp_source53ML2 \ -a filesets=bos.rte.install \ -a installp_flags= -acNgX \ <client name> __ 7. Now, let s use NIM s update_all operation to update your client to 5300-02 . Use your new lpp_source53ML2 lpp_source as the input source. This update probably takes about 3-4 minutes to complete. (Note: Typically we would also perform a verification of our filesets here, but we ll forego this extra step in order to save time.) # smitty nim (or nim_update_all) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Exercise 8. Ongoing Client Updates 8-5 V3.1.0.1 EXempty Perform NIM Software Installation and Maintenance Tasks Install and Update Software Update Installed Software to Latest Level (Update All) Target: <client name> LPP_SOURCE: lpp_source53ML2 OR # nim -o cust \ -a lpp_source=lpp_source53ML2 \ -a fixes=update_all \ -a installp_flags= -acgNX \ <client name> __ 8. Issue the oslevel -r command at your client to verify it s indeed at the 5 300-02 level. Optionally (only if time permits) shutdown and reboot your client in order for t hese

changes to officially take effect. (Note: you could have used a script resource to do your client s shutdown/reboot automatically if you did it using the at utility.) At Client: # oslevel -r # shutdown -Fr END OF EXERCISE Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. 8-6 Introduction to NIM Copyright IBM Corp. 1996, 2005 Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Appendix A. Initiating a Manual Install on an HMC LPAR A-1 V3.1.0.1 AP Appendix A. Initiating a Manual Install on an HMC LPAR __ 1. Start up a wsm session at your PC. Use this session to log in to your HMC. Using the information provided by your instructor. Double-click your WSM icon at your PC Enter in your HMC s hostname or IP as supplied by your instructor. Enter in the HMC User ID and password as supplied by your instructor. __ 2. Open up your HMC machine (if necessary) and then navigate down to find you r managed machine (as supplied by your instructor). From there, open up the partitions section in order to see your client s partition name. If necessary, open up your HMC machine at the left. Open up the Server and Partition section under your HMC machine section at the left. Click on the Server Management icon at the left and wait for the managed machines to appear on the right. Find your managed machine at the right and if necessary, open it up. Open up the partitions section under this managed machine. You should now see your partition name show up. __ 3. Notice your client (partition) state. If it says Not Activated then skip to the next step. If it is running, then open up your partition menu and choose the option t o do an immediate shutdown on your client. (You might do a nicer shutdown back home). Check your client state again. This time it should say Not Activated. Notice your client s (partition s) state. If it says Not Activated then continue on with the next step. Highlight your partition name. Right-click to pull up the partition menu. Wait for it to appear. Choose Shutdown the Partition and then Choose Immediate on the next screen when it appears. Press Enter. Wait a few seconds. View your client s (partition s) state. This time it should say: Not Activated. __ 4. Use your partition s menu to activate your client. Choose the option to op en up a terminal window and make sure you choose the SMS boot mode on the advanced screen. Highlight your partition name. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. A-2 Introduction to NIM Copyright IBM Corp. 1996, 2005

Right click to pull up the partition menu. Wait for it to appear. Choose Activate. On the next screen, choose to Open up a terminal window and click on the advanced button. On the advanced screen, change the boot mode to SMS. Press OK on this advanced screen and then press OK again back on the normal activation screen. __ 5. At your newly opened console window, wait for the SMS menu to appear. If a question appears that asks you to select this as the console, type in the information chosen. Press 0 to select this as the active console (if asked) __ 6. We ll be doing two things in SMS: 1) setting up our IPs to communicate to our master and 2) setting our temporary bootlist to point to our ethernet adapter. __ 7. Navigate down from the Setup Remote IPL menu to the IP Parameters menu to set up your IPs. Make sure to set up the server IP as your master IP (or whereve r your SPOT is located). Set up your client IP as your normal client IP. Set up th e netmask and gateway as appropriate. If there isn t a gateway between your client and server, you could leave the gateway IP as zeros. If necessary, return to you r master to double check what these settings should be. 2. Setup Remote IPL (Initial Program Load) 1. Interpartition Logical LAN 1. IP Parameters 1. Client IP Address Enter Client IP: ________________ (X to abort) 2. Server IP Address Enter Server IP: ________________ (X to abort) 3. Gateway IP Address Enter Gateway IP: _________________ (X to abort) 4. Subnet Mask Enter Subnet Mask:__________________ Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Appendix A. Initiating a Manual Install on an HMC LPAR A-3 V3.1.0.1 AP (X to abort) __ 8. Back out and choose the option to do a Ping Test. Ping your master (SPOT s erver) to make sure you have good communication. If not, double-check your IP settings and whether your client and master have any network communication problems. Fix as necessary before continuing. ESC 3. Ping Test 1. Execute Ping Test Press Any Key to Continue (when done) __ 9. Back out and select the Adapter Configuration menu and then the Speed,Dupl ex menu. This is where you can adjust your media speed settings. On a virtual Ether net adapter, these auto settings are probably not negotiable. However, back home, yo u may have a physical adapter and the speed settings may not be set up right. This

is a good place to go to make sure you have the right speed and duplex settings to match your hub and master. ESC 2. Adapter Configuration 1. Speed,Duplex __ 10. Return to the SMS main menu. From here let s select the Select Boot Optio ns menu in order to change our bootlist to point to our Ethernet adapter. From the Select Boot Options menu, you can go two routes. You can set up a device to boot JUST this time (via the Select/Install Boot Device menu) or to permanently boot from (via the Configure Boot Device Order menu). We choose the first temporary option , since we taught it in the lecture. If, for some reason, your boot fails, it brin gs you back to this bootlist menu and allows you to adjust your settings. Navigate down the Select/Install Boot Device series of menus in order to configure your chosen Ethernet adapter as the device to do a normal boot from. When asked, confirm tha t you re ready to exit SMS to start your boot. M (to return to the main SMS menu) 5. Select Boot Options. 1. Select/Install Boot Device 6. Network 1. Virtual Ethernet 2. Normal Mode Boot 1. Yes (to Exit SMS and start your boot) __ 11. Watch the initial progress at your client s console. Once some initial in formation scrolls by, look quickly for the following lines: BOOTP R = 1 BOOTP S = 1 bootfile=/tftpboot/<client name> PACKET COUNT=XXXXXXX (This should be increasing) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. A-4 Introduction to NIM Copyright IBM Corp. 1996, 2005 __ 12. In a couple minutes or so your BOS install questions should appear on you r client s console. If they do, return to your normal exercise. If they don t, look at the LED number next to your partition at your HMC screen. Report this LED to your instructor. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Appendix B. Initiating a Manual Install on a Stan d-alone Machine B-1 V3.1.0.1 AP Appendix B. Initiating a Manual Install on a Stand-alone Machine __ 1. If your client is still running, power it off and then back on again. Wait for the Interrupt menu to appear. When it does, quickly press the 1key to cause SMS to be loaded. __ 2. We do two things in SMS: 1) setting up our IPs to communicate to our maste r and 2) setting our temporary bootlist to point to our ethernet adapter. __ 3. Navigate down from the Setup Remote IPL menu to the IP Parameters menu to

set up your IPs. Make sure to set up the server IP as your master IP (or wherever yo ur SPOT is located). Set up your client IP as your normal client IP. Set up the net mask and gateway as appropriate. If there isn t a gateway between your client and ser ver, you could leave the gateway IP as zeros. If necessary, return to your master to double check what these settings should be. 2. Setup Remote IPL (Initial Program Load) 1. Interpartition Logical LAN 1. IP Parameters 1. Client IP Address Enter Client IP: ________________ (X to abort) 2. Server IP Address Enter Server IP: ________________ (X to abort) 3. Gateway IP Address Enter Gateway IP: _________________ (X to abort) 4. Subnet Mask Enter Subnet Mask:__________________ (X to abort) __ 4. Back out and choose the option to do a Ping Test. Ping your master (SPOT s erver) to make sure you have good communication. If not, double check your IP settings and whether your client and master have any network communication problems. Fix as necessary before continuing. ESC 3. Ping Test 1. Execute Ping Test Press Any Key to Continue (when done) Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. B-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 __ 5. Back out and select the Adapter Configuration menu and then the Speed,Dupl ex menu. This is where you can adjust your media speed settings. On a virtual Ether net adapter, these auto settings are probably not negotiable. However, back home, yo u may have a physical adapter and the speed settings may not be set up right. This is a good place to go to make sure you have the right speed and duplex settings to match your hub and master. ESC 2. Adapter Configuration 1. Speed,Duplex __ 6. Return to the SMS main menu. From here let s select the Select Boot Option s menu in order to change our bootlist to point to our Ethernet adapter. From the Select Boot Options menu, you can go two routes. You can set up a device to boot JUST this time (via Select/Install Boot Device menu) or to permanently boot from (via the Configure Boot Device Order menu). We choose the first temporary option since we taught it in the lecture. If, for some reason, your boot fails, it brin gs you back to this bootlist menu and allows you to adjust your settings. Navigate down the

Select/Install Boot Device series of menus in order to configure your chosen Ethernet adapter as the device to do a normal boot from. When asked, confirm tha t you re ready to exit SMS to start your boot. M (to return to the main SMS menu) 5. Select Boot Options. 1. Select/Install Boot Device 6. Network 1. Virtual Ethernet 2. Normal Mode Boot 1. Yes (to Exit SMS and start your boot) __ 7. Watch the initial progress at your client s console. Once some initial inf ormation scrolls by, look quickly for the following lines: BOOTP R = 1 BOOTP S = 1 bootfile=/tftpboot/<client name> PACKET COUNT=XXXXXXX (This should be increasing) __ 8. In a couple minutes or so your BOS install questions should appear on your client s console. If they do, return to your normal exercise. If they don t, look at the LED number next to your partition at your HMC screen. Report this LED to your instructor. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Appendix C. Initiating a Manual Install on a 170 C-1 V3.1.0.1 AP Appendix C. Initiating a Manual Install on a 170 __ 1. Go to your client machine. __ 2. Power on your machine and go to the SMS menu. If necessary, power off your machine. Power on your machine. When you see the icons appearing and you hear the music, press the F1 key. Be sure to do this before the last graphical image displays on your screen. Wait about 30 seconds before your SMS main menu appears. __ 3. We do two things in this exercise. Set up our IPs and set our bootlist. Le t s start with setting our IPs. Navigate under the Utilities and RIPL menus to set up your IPs. Check the IP settings back at your master site if you re not 100% sure what to u se. Return to the RIPL menu when done. Utilities RIPL Set Address Enter the address for your server, client, gateway and subnet mask. Use the backspace key to delete. Don t add any extra zeros in the address. If the gateway is not used, set it to the server IP address. Save and Exit when done (return to the RIPL menu). __ 4. Select the Ping and then the Adapter icons to ping your server. Wait for t he 60 seconds for the spanning tree. Then, if you don t get a blinking OK, then either your addresses are wrong or your master is not responding over the network. Please fi x before continuing. Exit back to the RIPL menu when done. ping Adapter

Use the arrow keys and space bar to select your adapter. Press the ping icon and wait about 60 seconds for the spanning tree to complete to see the blinking OK. It will only blink OK for about 3 seconds so you have to continue watching. Exit back to the main RIPL menu when done. __ 5. Check your Ethernet speed setting. Exit all the way back to the main SMS m enu when done. Config Select your Ethernet adapter Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. C-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 Check your speed settings. Use your arrow keys and the space bar to adjust. Exit all the way out to the main SMS menu. __ 6. We re now going to set up our normal bootlist to point to our Ethernet ada pter. We could either make this change occur for just this boot, or we could set it up permanently. On a 170, setting it permanently works better in case you run into installation problems and need to restart your install a few times. Hence, we ll choose the permanent method here in our exercise. Choose the Multiboot and then Boot Sequence menus to change your bootlist to point to your Ethernet adapter. Multiboot Boot Sequence Put a 1next to your network adapter Save your bootlist Check the entries as shown both times __ 7. Exit all the way out. This begins your boot. __ 8. Monitor your initial progress. It should look something like the following : BOOTP S=1 BOOTP R=1 File=/tftpboot/<your_client> PACKET COUNT=NNNN (where this number is increasing) __ 9. In a couple minutes or so your BOS install questions should appear on your client s console. If they do, return to your normal exercise. If they don t, look at the LED number on your client s LED display. Report this LED to your instructor. Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. Copyright IBM Corp. 1996, 2005 Appendix D. Typical Base (RTE) Install Output D-1 V3.1.0.1 AP Appendix D. Typical Base (RTE) Install Output The following output should closely correspond to output you receive when perfor ming a base (RTE) install without using any additional resources. (Note, it may be slig htly different but should be very similar). To get your client s Cstate and info fields, run the following command at the ma ster. You may find it handy to write a simple shell script with a while loop to investigat e your client s state every 5 seconds or so. lsnim -a Cstate -a info <your client name> Normal Cstate entries: Entry When Enabled BOS Installation has been enabled After smitty nim_bosinst at master

BOS Installation is being performed When BOS Install Program Starts Ready for a NIM Operation When Client is Rebooting Normal info entries: Note: all but the top two entries appear when the BOS Install program is running . LED 610: mount -r <nim_master_long_hostname>:/export/nim/spot/spot53ML1/usr /SPOT/usr <blank> extract_data_files query_disks extract_diskette_data setting console initialization verifying_data_files prompting_for_data_at_console (This is when your BOS Install Questions appear at the client console) BOS Install 1% Complete: Preparing Target Disks Student Exercises Course materials may not be reproduced in whole or in part without the prior written permission of IBM. D-2 Introduction to NIM Copyright IBM Corp. 1996, 2005 BOS Install 1% complete: Making boot logical volume BOS Install 1% complete: Making paging logical volumes BOS Install 3% complete: Making logical volumes BOS Install 3% complete: Forming the jfs log BOS Install 5% complete: Make File Systems BOS Install 5% complete: Mounting File Systems BOS Install 7% complete: Restoring Base Operating System BOS Install 12% complete: initializing Disk Environment BOS Install 13% complete: Over Mounting / BOS Install 15% complete: Copying Cu* to disk BOS Install 18-93% complete: Installing Additional Software (this goes on for awhile) BOS Install 95% complete BOS Install 95% complete: Initializing dump device BOS Install 95% complete: Network Install Manager customization bosboot BOS Install 96% complete: Creating boot image BOS Install 100% complete <blank> _______________________________________________________________ At this point the info field disappears. The machine is rebooting. If performing a non-automated install you ll have to go to the console to answer a few questions before you can login remotely. V3.1.0.1 backpg Back page

Você também pode gostar