Saturday, May 20, 2017

NIM server and client configuration in AIX?

NIM server and client configuration in AIX?



NIM SERVER PRE-REQUISITE
========================

The below filesets required to setup NIM server and Client. We could check using      

#lslpp –l |grep nim.

bos.sysmgt.nim.master
bos.sysmgt.nim.spot


NIM SERVER INSTALLATION
========================

We could install using below commands

installp -agXd /mnt/nimpkg/bos.sysmgt.nim.master
installp -agXd /mnt/nimpkg/bos.sysmgt.nim.spot


lslpp -l |grep nim - To display the nim.spot and nim.master file sets
ls -l /etc/niminfo  -> The /etc/niminfo file created as part of the installation

The above installation creates the /etc/niminfo  file and the below deamons.

nimd and nimesis – daemon will get started, if it is not started, restart the inetd
startsrc –g inetd
startsrc –s nimd
startsrc -s nimesis


LPP_SOURCE

Lpp_source: This is having the content of aix in the CD for the aix installation

cd /export/install/nim/lpp_source
mkdir 6101LPP

smitty nim -> Perform NIM Adinistration Task -> Manage Resources -> Define a Resource
select lpp_source as resource type and enter

Fill it up the below mandatory field.
resource name                [61TL07]
resource type                 lpp_source
server of resource [master]
location of resource       [/export/install/nim/lpp_source/6101LPP]
source of install images [/cdrom]
Press enter, lpp_source will be created.

Commands to check
lsnim –l  <LPP_SOURCE NAME> detailed view
lsnim –c <lpp_name>

SPOT


Spot: This is used for aix installation which is created for each lpp_source

smitty nim ->  Perform NIM Adinistration Task ->  Manage Resources ->  Define a Resource
select spot as a resource type and enter

resource name                [spot_61TL07]
resource type                 spot
server of resource [master]
source of install images [61TL07_lpp]
location of resource       [/export/install/nim/spot]

Commands to check:
lsnim –l  <SPOTR NAME> detailed view
lsnim –c <sopt_name>


NIM CLIENT CONFIGURATION
==========================
 Nim master's /etc/hosts client IP and HOSTNAME and obviously client server supppose to be in DNS.

For NIM Client:
Required fileset: bos.sysmgt.nim.client   (This fileset present on aix server defaultly)

smitty nim_mkmac
Enter the machine name and press enter to continue
Select the type of network as "ent = ethernet network" and enter

* NIM Machine Name [abc_testlpar]
* Machine Type [standalone]
* Hardware Platform Type [chrp] Make sure this is set to ‘chrp’
Kernel to use for Network Boot [mp]
* Cable Type bnc/tp
* NIM Network master_net/enX
* Host Name abc_testlpar
 Press enter to continue

Commands to check
lsnim|grep -i abc_testlpar
lsnim -l abc_testlpar

Friday, February 3, 2017

How to check the apar installed in aix?

How to check the particular apar is installed in aix?


Many times we are in the position to check or install the specific apar in aix.

Below is the way to check whether the particular apar is already installed or not.

Example: APAR IZ97457


syntax: #instfix -ik <apar_name>

#instfix -ik IZ97457

All filesets for IZ97457 were found.

The above output shows that the APAR IZ97457 is already installed on the server.



Suppose if the apar is not installed on the server then we have to get the apar first and then installed it.

To list of fixes/apar that are on a directory or CD, then we can use the following:
# instfix -Td <directory>     (or)   # instfix -Td /dev/cd0

once you find out then installed the fix with the below command
# instfix -k <fix> -d <directory>
# instfix -k IZ97457 -d /export/filesets      (or) use # smitty update_by_fix





Thursday, December 22, 2016

How to solve current boot logical volume /dev/hd5, does not exist on /dev/hdisk# in aix?

How to solve current boot logical volume /dev/hd5, does not exist on /dev/hdisk# in aix?



Many cases we could receive this issue when we run mksysb command or run alt_disk copy or create/recreate the bosboot image on the disk.

Please follow the below procedure to fix the issue.


#cd /usr/bin
#cp mkszfile mkszfile.old
#vi mkszfile

search for the argument "-qv" and find the following line


BOOT_BLKS=`LC_MESSAGES=C ${bosboot} -qv | ${tail} -1l | ${awk} '{print $2 * 2}'` 


Add the  -d /dev/ipldevice. The line should look like this when finished


BOOT_BLKS=`LC_MESSAGES=C ${bosboot} -qvd /dev/ipldevice| ${tail} -1l | ${awk} '{print $2 * 2}'` 


then save it and run mksysb or alt_disk again.

or


change mkszfile to use  #bosboot -qvd /dev/ipldevice

****************************************************************************************************************************************



Another blv error

==============


If /dev/ipldevice vary with the boot disk, need to follow the below steps to correct it. We will do the first step for sure and it will end up with error as below, proceed with the next steps.

bosboot -ad /dev/ipldevice
0516-602 lslv: Logical volume name not entered.
0301-168 bosboot: The current boot logical volume, /dev/hd5,   does not exist on /dev/hdisk0.

Solution:
lsvg -p rootvg - hdisk0
lslv -m hd5 -->
hdisk0 on PV1 1st partition
savebase -v - successful

will remove/recreate hd5 – no need to worry it worked good

# rmlv hd5
# mklv -y hd5 -t boot -a e rootvg 1 hdisk0
# cd /dev
# rm ipldevice
# ln /dev/rhdisk0 /dev/ipldevice
# bosboot -ad /dev/ipldevice - same error

# bootinfo -B hdisk0 - 1
# ln /dev/rhd5 /dev/ipl_blv
# cd /dev -
same maj/min numbers
# bosboot -ad /dev/ipldevice

Now we got the same minor and major number for hdisk0

# ls -ld /dev/ipldevice
crw-------    2 root     system       20,  0 Oct 31 2019  ipldevice
# ls -ld /dev | grep -i "20,  0"
# ls -l /dev | grep "20,  0"
brw-------    1 root     system       20,  0 Mar 31 08:54 hdisk0
crw-------    2 root     system       20,  0 Oct 31 2019  ipldevice
crw-------    2 root     system       20,  0 Oct 31 2019  rhdisk0
#
alt_disk_install was able to proceed now

****************************************************************************************************************************

Another blv error

=============


0301-162 bosboot: savebase failed with /dev/hdisk0.

0301-165 bosboot: WARNING! bosboot failed - do not attempt to boot device.


Solution
=======

Boot the sever into maintenance mode
Remove the corrupted blv - #rmlv –f hd5
recreate the new hd5 blv logical volume - # mklv -y hd5 -t boot -a e rootvg
create a bootimage - # bosboot -ad /dev/hdisk0
Shutdwon -Fr 


Thursday, September 15, 2016

How to reset the unknown root password in aix?

How to reset the unknown root password in aix?


1. Ground work:

Get the hmc details
Get the hscroot password of the HMC
Make sure CD available on the server.
Login to hmc and reboot the server from sms mode


2. Implementation

(Boot the server in sms mode and follow the below steps)

5. Select boot options
1. Select install/Boot device
4. IDE
1. IDE-CDROM
3. Service mode boot
1 Yes (Exit sms)
1. Type 1 and press enter to have english during install
3. Start maintenance mode for system recovery
1. Access a root volume group
0 Continue
1 (Select the boot device)
1. Access this volume group and start a shell

# passwd
Changing password for "root"
root's New password:
Enter the new password again:
sync;sync;sync;reboot
                     
3. Validation

login to the server with the new password and confirm you can logon successfully.

4. Downtime
Yes downtime required for this task.

Note: If you dont have CD to boot up the server in maintenance mode, then you can use the NIM server to get maintenance mode. Please see the link below.
http://howtoaix.blogspot.in/2015/04/how-to-boot-server-into-maintenance.html


Saturday, September 10, 2016

How to reboot HMC server in AIX?

How to reboot HMC server in AIX?


1. Ground work:

Ip address or hostname of the HMC
hscroot password to access the HMC
Get the Frames and Lpars attached to this hmc
cat /proc/uptime                   --> To check the uptime of the hmc


2. Reboot the HMC using command line

Login to the hmc with hscroot access
hmcshutdown -t now -r              --> To reboot the HMC


3. Reboot the HMC using GUI mode

Login to the HMC GUI using hscroot user account
HMC management --> Shutdown or restart  --> select Restart HMC  --> Click OK


4. Post check

cat /proc/uptime                   --> To check the uptime of the hmc
Check you can see all the Frames and its Lpars.


Wednesday, September 7, 2016

How to stop and start the hacmp cluster in aix?

How to stop and start the hacmp cluster in aix?


1. Ground work:

/usr/es/sbin/clu*/utiI/clRGinfo      --> To check the RG online status
lssrc -ls clstrmgrES                          --> To check the cluster manager is stable on both nodes
cat /var/hacmp/clverify/clverify.log  --> To check and confirm the log file has no errors.


Take a snapshot of the cluster

smitty hacmp
            extended configuration
                        snapshot configuration
                                    Create snapshot of the cluster configuration
                                                cluster snapshot name / Cluster snapshot description

The above will create .odm and .info file.
Take all the basic outputs

2. Stop the cluster services

smitty hacmp
            system management (C-Spoc)
                        Stop cluster services
                                    (Provide necessary details) stop now / provide node names/  Bring RG offline.

3. Validation

./clRGinfo                                 --> To check the RG online status
lssrc -ls clstrmgrES                   --> To check the cluster manager is stable on both nodes


4. Start cluster services

smitty hacmp
            system management (C-Spoc)
                        Start cluster services
                                    (Provide necessary details) start now / provide node names/  Choose Automatic for manage RG


5. Validation

/clRGinfo      --> To check the RG online status
lssrc -ls clstrmgrES                   --> To check the cluster manager is stable on both nodes
cat /tmp/hacmp.out                --> To check the HA services and RG status.



Tuesday, September 6, 2016

How to increase memory using dlpar in aix?

How to change memory using dlpar in aix?



1. Ground work:

uname -L                                 --> To find the Lpar name and Lpar id.
lparstat -i                                --> To check current assigned memory (Desired memory)
prtconf -m                               --> To check the size of the memory
lsrsrc ibm.managementserver     --> To find the hmc details where the lpar belongs to.
Get the hscroot password to access the HMC for the DLPAR operation.


2. Implementation steps 

Login to the HMC using hscroot access

system management
            servers
                        select the frame
                                    Select the lpar
                                                Dynamic Logical Partitioning
                                                            Processor
                                                                        Add or remove
                                                                                    change the assigned memory
(change the size of the memory - increase upto Maximum memory limits or decrease upto Minimum memory level)
                                                                                                Click OK

We need to change the same in the partition profile so that when the LPAR is reactivated, it should start with the new value.

Select the Lpar
            Configuration
                        Manage profile
                                    Select the default profile last activated
                                                Action
                                                            Edit
                                                                        Now change the desired memory value 
                                                                                    Click OK
                                   
4. Validation
lparstat -i                                        --> To check the output of the memory. (Check online memory)
prtconf -m                                       --> To check the size of the memory.