Monthly Archives: March 2012

To configure a AIX box as a NTP client first set the correct time zone using `smitty chtz_date`. Also set the system time manually as accurate as possible, if the system time would be way out of the reality, the xntpd daemon will not handle this and end with the following error in the error log:

LABEL:          SRC_SVKO
Sequence Number: 4298
Class:           S
Type:            PERM
WPAR:            Global
Resource Name:   SRC

Probable Causes

Failure Causes

        Recommended Actions

Detail Data

Also there will be no error recorded in the syslog, nor will there be any error if xntpd will be run manually with the debug option enabled.

Back to the configuration. This is how my /etc/ntp.conf file looks like:

server prefer
driftfile /etc/ntp.drift
tracefile /etc/ntp.trace

Now we start the xntpd daemon:

# lssrc -s xntpd
Subsystem         Group            PID          Status
 xntpd            tcpip                         inoperative
# startsrc -s xntpd
0513-059 The xntpd Subsystem has been started. Subsystem PID is 3997772.
# lssrc -s xntpd
Subsystem         Group            PID          Status
 xntpd            tcpip            3997772      active

The time synchronization may take some time. So don’t worry to wait for 15 min. to check the synchronization status using ntpq.

# ntpq -p
     remote           refid      st t when poll reach   delay   offset    disp
*       2 u   62   64  377    39.51    4.800    0.98
+  3 u   42   64  357    60.24   -0.091    0.64

Ntpq output explained

Now in order to let xntpd start each time the system boots edit /etc/rc.tcpip and uncomment the ntp entry as follows:

# Start up Network Time Protocol (NTP) daemon
start /usr/sbin/xntpd "$src_running"

I wrote a tiny script that can report the number of stale partitions across multiple Volume Groups. If invoked with the -a flag the script will list LPs, PPs and Stale partitions for all Logical Volumes in all active Volume Groups. Using the -v flag only information for the specified Volume Group will be displayed.

Usage: -v rootvg -a

Sample output:

VG: rootvg   LV: hd5     LPs: 1      PPs: 2         STALE 0
VG: rootvg   LV: hd4     LPs: 6      PPs: 12        STALE 0
VG: rootvg   LV: hd2     LPs: 29     PPs: 58        STALE 0
VG: rootvg   LV: hd3     LPs: 4      PPs: 8         STALE 0
VG: rootvg   LV: hd1     LPs: 2      PPs: 4         STALE 0

Read More

To mount a CD or DVD from the CLI use:

# mount -V cdrfs -o ro /dev/cd0 /mnt
# df -g /mnt
Filesystem    GB blocks      Free %Used    Iused %Iused Mounted on
/dev/cd0           3.64      0.00  100%  1905950   100% /mnt

To mount a iso image on the /mnt directory use:

# loopmount -i aix61_dvd.iso -o "-V cdrfs -o ro" -m /mnt 
# df -g /mnt
Filesystem    GB blocks      Free %Used    Iused %Iused Mounted on
/dev/loop0         3.64      0.00  100%  1905950   100% /mnt

After os level update it might happen that not all filesets are installed correctly what results in a lower oslevel than we attempted to update to. For example if we update from TL5 to TL7 on AIX 6.1. The oslevel command may return that we are on TL 6 instead of TL 7.

# oslevel -s

Instfix may help us to nail down the missing filesets

# instfix -i | grep ML
    All filesets for 6100-00_AIX_ML were found.
    All filesets for 6100-01_AIX_ML were found.
    All filesets for 6100-02_AIX_ML were found.
    All filesets for 6100-03_AIX_ML were found.
    All filesets for 6100-04_AIX_ML were found.
    All filesets for 6100-05_AIX_ML were found.
    All filesets for 6100-06_AIX_ML were found.
    Not all filesets for 6100-07_AIX_ML were found.

Do display the missing filesets that are holding us back from TL7 use:

# instfix -icqk 6100-07_AIX_ML | grep :-:
6100-07_AIX_ML:openssh.base.client: 6100-07 Update
6100-07_AIX_ML:openssh.base.server: 6100-07 Update 6100-07 Update
6100-07_AIX_ML:openssl.base: 6100-07 Update
6100-07_AIX_ML:openssl.license: 6100-07 Update 6100-07 Updat

This post will describe a interim Fix installation from the APAR IV16587 on a system level 6100-07-02-1150, more information  can be found here, more about Interim fixes in general is here.

This procedure will require a system reboot.

1. Download the right ifix for your oslevel according to the APAR description (see APAR link above)

2. Check if an ifix is not already installed on the system

# emgr -l
There is no efix data on this system.

3. Get some information from the downloaded ifix about itself:
Read More

Sometimes if things get stuck it might be necessary on the NIM master server to reset the NIM client status and deallocate all resources from it. Here is how:

# nim -Fo reset client_name

-F Force
-o Operation

# nim -o deallocate -a subclass=all  client_name

-a attribute

# lsnim -l client_name
   class          = machines
   type           = standalone
   connect        = shell
   platform       = chrp
   netboot_kernel = 64
   if1            = EN_0 power2 0
   net_settings1  = auto auto
   cable_type1    = tp
   Cstate         = ready for a NIM operation
   prev_state     = BOS installation has been enabled
   Mstate         = not running
   Cstate_result  = reset

That’s it.

This post will describe how to:

1. Create a Volume Group
2. Create a Logical Volume within the VG containing a JFS2 filesystem that will be automatically mounted during boot.
3. Add a disk to the VG and mirror the data across 2 disks
4. Display LP>PP mappig and LVCB

1. Create a VG
Read More