Here is what I use. Keep in mind that you have to copy the hcienginestop from $HCIROOT/bin to a different directory within you path and name it with a .pl extension. This is because you then need to modify the waitForIt subroutine from:
######################################################################
# waitForIt – loop waiting for the process to exit
# Args:
# name = process name
# Returns:
# pid of process, or 0 if exited
#
sub waitForIt {
local( $name ) = @_;
local( $tries ) = 30;
while( ($pid = &getHciEnginePid( $name )) && $tries– ) {
sleep 10;
}
return $pid;
}
and change the sleep to 1 second. This will vastly improve the time that the system requires to shut down.
We use AIX 5.2 with qdx5.3 and these scripts work tremendously well. We reboot once a month without incident.