Startup

System Startup and Shutdown

System boot process:

  • Power on
  • PDC executes CPU, Memory and other tests
  • PDC initialize the console to display messages
  • Looks for Primary boot path
  • It loads and executes Initial System Loader (ISL). Roll of boot ROM ends.
  • ISL loads the secondary system loader called "hpux". It resides on boot area of the disk
  • "hpux" loads "/stand/vmunix" into memory and hands control over to kernel
  • Kernel loads the device drivers
  • Swapper process started. It has process ID 0. It manages memory for swapping in and out. It schedules all other process. Its first job is to startup the init process.
  • /sbin/pre_init_rc getting executed. It checks and repairs root file system.
  • /sbin/init started. Process ID is 1. It refers /etc/inittab. It does the following.
    1. read the /etc/inittab for default run level
    2. ioinitrc - It invokes insf command with -e option to find any new devices.
    3. bcheckrc - activates LVM and run fsck on file systems if required.
    4. /sbin/rc - It brings the system to the default run level. This script is run whenever the system moves from to a higher one or vice versa.
    5. /usr/bin/getty

To add a program to the startup time:

  1. Execution script for starting and stopping is installed in /sbin/init.d directory
  2. Configuration files are placed in /etc/rc.config.d directory
  3. If script is to be run on run level 2, place a link to the execution script at /sbin/rc2.d directory

HP-UX boot disk has a boot area. The files in this area are in the LIF format. Important parts of the boot area are

  1. ISL: Initial program loader
  2. hpux: Secondary system loader
  3. AUTO: contains hpux utility name and arguments to be passed to the hpux utility
  4. LIF volume header that identifies LIF volume
  5. File containing hp-ux volume name

ISL Commands:

ISL> hpux show autofile # To view the contents of AUTO file

ISL> hpux -is boot # To boot the system in the single user mode

ISL> hpux -lq boot # To ignore quorum and boot

ISL> hpux -lm boot # To boot in the maintenance mode

ISL> hpux -ll /stand # To list the files in the /stand directory

hpux Commands:

setboot command is used to view or change the boot path in a running system
To set the primary path to scsi.1.0 and auto boot on

 # setboot -p scsi.1.0 -b on  

To create an area on the boot disk for a LIF volume, boot utilities and BDRA

 # pvcreate -B /dev/rdsk/c0t0d0

To place the boot utilities on the boot disk:

 #  mkboot  /dev/rdsk/c0t0d0

To add an AUTO file in boot area:

 # mkboot -a "hpux (52.3.0;0)/stand/vmunix" /dev/rdsk/c0t0d0

To List the contents of LIF volume

 # lifls -l /dev/dsk/c0t0d0   

lifcp command is used to copy files to or from the LIF volume
To copy the contents of AUTO file to file1

 # lifcp /dev/rdsk/c0t0d0:AUTO file1  # Copies the contents of AUTO file to file1. 

EFI Commands reference

Boot Commands — EFI Shell Commands related to nPartition booting

 autoboot      - Set/view autoboot timeout variable.
 bcfg          - Display/modify the driver/boot configuration.
 boottest      - Set/view BootTest bits.
 dbprofile     - Display/modify direct boot profiles for use by lanboot.
 lanboot       - Boot over the LAN.
 reconfigreset - Reset the system (nPartition) for reconfiguration; 
                 the nPartition remains inactive, in the  shutdown for reconfig state.
 reset         - Reset the system (nPartition).
 search        - Connect drivers for bootables devices.

Configuration Commands — for changing and retrieving system (nPartition) information.

 cellconfig    - Deconfigure/reconfigure cells. (Set cell use-on-next-boot values.)
 cpuconfig     - Deconfigure/reconfigure processors and processor cores..
 date          - Display the current date or set the date of the system (nPartition).
 dimmconfig    - Deconfigure/reconfigure memory (DIMMs).
 err           - Display/change the error level.
 errdump       - View/clear logs.
 fru           - View FRU data.
 info          - isplay hardware information.
 monarch       -  Set/view a monarch processor.
 romdrivers    - Enable/disable PCI expansion ROM drivers.
 rootcell      - Set/view preferred root cells. (Set nPartition core cell choices.)
 tftp Performs - TFTP operation to a bootp/DHCP enabled Unix boot server.

 time          - Display the current time or set the time of the system (nPartition). 
                 EFI time is set and presented in GMT (Greenwich mean time).
 variable      - Save/restore specific EFI variables.
 ver           - Display the version information.

Filesystem Commands — For managing files, directories, and attributes

 attrib        - Display/change the attributes of files/directories.
 cd            - Update/view the current directory.
 comp          - Compare the contents of two files.
 cp            - Copy one or more files/directories to another location.
 edit          - Edit an ASCII or UNICODE file in full screen.
 eficompress   - Compress infile and write to outfile.
 efidecompress - Decompress infile and write to outfile.
 ls            - Display a list of files and subdirectories in a directory.
 mkdir         - Create one or more directories.
 mount         - Mount a filesystem on a block device.
 rm            - Delete one or more files/directories.
 touch         - Update time of file/directory with current time.
 type          - Display the contents of a file.
 vol           - Display volume information of the file system.