HPUX Supplement for Micah Altman's Unix Handouts

Coming from an IRIX environment HPUX should not be too difficult to understand. Most of my notes on my main Unix page are directly applicable.

For HP-UX adminstrators, in addition to my general Unix reading list on that page, I recommend

Poniatowski, Marty, 1997. HP-UX System Adminstration Handbook and Toolkit,NJ:Prentice Hall.

HPUX Tools

Many of the common troubleshooting and tuning tools (such as ps) are available under HPUX, but may differ somewhat from other Unix'es. Here are some HPUX-specific tools or HPUX-specific implementations of common tools to look for:

HPUX Memory Management

HP-UX also has a significantly different approach to memory management than most other Unixes. Two kernel features may be of particular interest:

  1. Dynamic Buffer Cache: This controls the amount of filesystem data cached in memory. Unlike other systems, DBC memory is not flushed when process space gets tight, so too large a dbc can cause swapping. Also, the DBC tends to be synced all at once, instead of paged gradually, so that large DBC's can cause intermittent delays. Tune with the kernel variables dbc_min_pct and dbc_max_pct.
  2. Pseudo-Swap: HPUX does not have virtual swap, and in fact demands that there be swap allocation for every page of VM allocation, even if the VM currently resides in RAM. In other words, while IRIX allows safe VM allocation up to (RAM+SWAP), HPUX only allows it up to (SWAP). To get around this somewhat, HP uses a "pseudo-swap", and memory locking (which avoids the need for swap reservation) to avoid their own poor implementation of swap reservation. Sigh. This can cause problems on systems with a small amount of memory. Tune with swapmem_on and unlockable_pages.

You may also want to read the

  • HP-UX Kernel Tuning and Performance Guide .

    HPUX Bootup Process

    The HPUX bootup process is conceptually the same as the IRIX bootup process described in my handouts. Both OS's: (1) Load bootup parameters from non-volatile memory, and run diagnostics. (2) Load a bootstrap loader for the OS. (3) Start init and procede through the inittab entries and the rcXX.d scripts.

    Some of the HPUX commands, especially in stages 1 & 2, are different in the details:

    1. PDC: This is HP's firmware loader. To access it, press <esc> at the start of the boot process. The PDC menu will allow you to turn on the autoboot and autosearch parameters, which are useful if you want the system to come up automatically. The PDC menu also allows you to turn on diagnostics which can tell you if boards or memory is failing.
    2. ISL: This is the second stage loader. To access it, use the "boot pri isl" command from PDC. From here, you can examine the boot path and console path, and also boot into single user mode, or boot a backup kernel using HPUX.
    3. HPUX: The third (and final) stage loader. Use this from ISL to boot into single user mode or to boot an alternate kernel -- very useful when the system hangs on normal bootup (e.g. trying to access nonexistent NFS mounts). For example, to boot into single user mode, type "hpux -i1 boot" from ISL.
    4. HP-ux proper: From here on, the boot process is quite similar to IRIX. Both use the inittab to direct the startup process. Most processes are started from the rc scripts (one big /etc/rc script in HPUX 9.X, and /sbin/rc?.d/* scripts in HPUX 10.0 and later). Many of the configuration parameters for these scripts are kept in /etc/rc.config.d. HPUX does not have a "verbose" startup mode, like IRIX, but instead keep a log of all boot script output in /etc/rc.log.

    HPUX Panic Analysis

    HP-UX does not support the svr5r3 tool icrash, which is immensely useful for crash debugging. Instead, they provide their own scripts. This is what you need to do to run a panic analysis:

    1. cd /var/adm/crash/core.[n]
    2. zcat /usr/contrib/lib/Q4Lib.tar.Z | tar -xvf -
    3. gunzip vmunix
    4. /usr/contrib/bin/q4pxdb vmunix
    5. cp q4lib/sample.q4rc.pl ~/.q4rc.pl
    6. /usr/contrib/bin/q4 -p .
    7. include analyze.pl
    8. run Analyze AU > crash[n]_rpt.txt
    ________

    Search this site for: Search tips
    [ Things to do with this page: | Print it!  | Comment on it! | Track it! ]
    Copyright © 1995-2008 Micah Altman