Chapter Syllabus
14.1 Introduction to the Boot Process
14.2 Processor Dependent Code
14.3 Boot Area on the System Disk
14.4 Initial System Loader
14.5 Loading the HP-UX Kernel
14.6 The init Process
14.7 Runlevels
14.8 Adding a Program to Run at Boot Time
14.9 System Shutdown
Understanding of the system startup and shutdown processes is very important both for routine system administration and troubleshooting. Every HP-9000 server or workstation is supplied with boot code that resides on ROM. As soon as you power on the system, this code executes and performs self-tests and some initialization tasks. It then loads the HP-UX kernel and hands control over to it. The kernel does a number of system initialization tasks before you get a login prompt on your console or terminal. This chapter covers in detail all of the processes that take place from system power on to the display of the login prompt.
In the beginning, you will see an overview of the boot process. The boot process starts from processor dependent code (PDC) that resides on ROM in your system. You will learn how to work with PDC and use its commands by interrupting the boot process. During the boot process, the PDC checks for boot area on the primary boot disk. You will learn the structure of the boot area to
build an understanding of this part of the boot disk. The initial system loader (ISL) is used to load the kernel into memory. Its knowledge is important if you need to boot your machine in single-user mode. You have to rebuild the HP-UX kernel many times, and ISL helps you boot from an old kernel if your new kernel is misconfigured and fails to boot. You will also see how the autoboot works and how to enable or disable it.
Once the HP-UX kernel is loaded into memory, it initializes other processes. The init process is the most important of all of these. It is responsible for most of the system initialization. When you study the section containing information about the init process, you will see the structure of its configuration file and how it performs automatic initialization of other processes at different stages of the boot process.
Runlevels show the system state at a particular instant, and these are also controlled by the init process. You will see which runlevels are supported on HP-UX and what the function is of each. Changing system states by changing runlevels is also explained at this stage.
Many times you need to perform a task right after the system boots up. You may also need to run a program at the boot time. You will find a complete example of how programs are started and stopped during the system startup and shutdown processes. In the last part of this chapter, the shutdown process will be presented. You will see the difference between the shutdown and reboot commands.
After going through this chapter, you will understand the startup and shutdown processes and the different stages that involve these processes. In addition, you will have knowledge of commands and utilities that are used for this purpose. Having a good understanding of this process, you will be able to troubleshoot any HP-UX startup or shutdown problem.
14.1 Introduction to the Boot Process
The boot process of an HP-9000 server or workstation starts when you power it on or when you reboot a running system. It can be divided into two main parts.
• boot ROM startup
• HP-UX startup
In the first stage, the boot ROM startup process is carried out. At its completion, it initiates the HP-UX startup process, which is completed in a number of steps. On an abstract level, the boot sequence can be divided into the following steps.
1. Power on or reboot.
2. The processor dependent code (PDC) executes and performs self-tests. These tests include memory and CPU tests. The PDC also detects any peripherals attached to the system.
3. PDC initializes the console to display messages. It looks for the primary boot path for booting the system. The boot path is the hardware path to the disk used as the boot device.
4. PDC loads and executes the initial system loader (ISL) from the boot path and executes it. At this stage in the startup process, the role of the boot ROM ends.
5. ISL loads the secondary system loader known as hpux, which resides on the boot area of the disk.
6. The hpux loads the HP-UX kernel /stand/vmunix into memory and hands control over to the kernel.
7. The kernel starts the swapper process and then the init process.
8. The init process reads its initialization file, /etc/inittab, and initializes most of the operating system daemons and processes. It brings the system into an appropriate state and makes it usable for users.
As soon as the init process has completed its tasks, you see a login prompt at the console or at any terminal attached to the system. Part of a sample boot process is shown here.
Primary boot path = 0/2/0.6.0
Alternate boot path = 7/2/0.6.0
Console path = 15/1
Keyboard path = 15/1
[*** Manufacturing (or Debug) Permissions ON ***]
System is HP9000/800/V2500 series
Processor is starting the autoboot process.
To discontinue, press any key within 10 seconds.
Device : 0/2/0.6.0
File : hpux
Arguments : hpux
Loading : hpux ........... 163808 bytes loaded.
102368 + 61440 + 864504 start 0xd01cc0
Boot
: disc(0/2/0.6.0;0)/stand/vmunix
6848512 + 1181408 + 6521760 start 0x3a168
5/2/0.8.0.255.1.2.0 sctl
Probing epic6
Probe of epic6 complete
6 saga
6/0/0 btlan6
6/1/0 fcT1
6/1/0.5 fcT1_cntl
6/1/0.8 fcp
System Console is on SPP DUART0 Interface
WARNING: max message size > 65535, adjusting.
WARNING: max bytes on msg q > 65535, adjusting.
Logical volume 64, 0x3 configured as ROOT
Logical volume 64, 0x2 configured as SWAP
Logical volume 64, 0x2 configured as DUMP
Swap device table: (start & size given in 512-byte blocks)
entry 0 - major is 64, minor is 0x2; start = 0, size = 2097152
Starting the STREAMS daemons-phase 1
Checking root file system.
file system is clean - log replay is not required
Root check done.
Create STCP device files
Memory Information:
physical page size = 4096 bytes, logical page size = 4096 bytes
Physical: 16773120 Kbytes, lockable: 12203164 Kbytes, available:
14014856 Kbytes
/sbin/ioinitrc:
Starting /sbin/ioscan -f 1> /dev/null
Starting /sbin/insf -e -C disk 1> /dev/null
Done ioscan & insf
/sbin/bcheckrc:
Checking for LVM volume groups and Activating (if any exist)
Volume group "/dev/vg00" has been successfully changed.
Resynchronized volume group /dev/vg00
vxfs fsck: sanity check: root file system OK (mounted read/write)
(c)Copyright 1983-1997 Hewlett-Packard Co., All Rights Reserved.
(c)Copyright 1979, 1980, 1983, 1985-1993 The Regents of the Univ. of
California
(c)Copyright 1980, 1984, 1986 Novell, Inc.
(c)Copyright 1986-1992 Sun Microsystems, Inc.
(c)Copyright 1985, 1986, 1988 Massachusetts Institute of Technology
(c)Copyright 1989-1993 The Open Software Foundation, Inc.
(c)Copyright 1986 Digital Equipment Corp.
(c)Copyright 1990 Motorola, Inc.
(c)Copyright 1990, 1991, 1992 Cornell University
(c)Copyright 1989-1991 The University of Maryland
(c)Copyright 1988 Carnegie Mellon University
(c)Copyright 1991-1997 Mentat, Inc.
(c)Copyright 1996 Morning Star Technologies, Inc.
(c)Copyright 1996 Progressive Systems, Inc.
(c)Copyright 1997 Isogon Corporation
RESTRICTED RIGHTS LEGEND
Use, duplication, or disclosure by the U.S. Government is subject to
restrictions as set forth in sub-paragraph (c)(1)(ii) of the Rights in
Technical Data and Computer Software clause in DFARS 252.227-7013.
Hewlett-Packard Company
3000 Hanover Street
Palo Alto, CA 94304 U.S.A.
Rights for non-DOD U.S. Government Departments and Agencies are as set
forth in FAR 52.227-19(c)(1,2).
/sbin/auto_parms: DHCP access is disabled (see /etc/auto_parms.log)
HP-UX Start-up in progress
__________________________
Configure system crash dumps .............................. OK
Mount file systems ........................................ OK
Update kernel and loadable modules ........................ N/A
Initialize loadable modules ............................... N/A
Setting hostname .......................................... OK
Set privilege group ....................................... N/A
Display date .............................................. N/A
Save system crash dump if needed .......................... N/A
Enable auxiliary swap space ............................... OK
Start syncer daemon ....................................... OK
Configure HP Fibre Channel interfaces ..................... OK
.......................................................... OK
Configure Loopback interfaces (lo0) ....................... OK
Start Software Distributor agent daemon ................... OK
Configuring all unconfigured software filesets ............ OK
Recover editor crash files ................................ OK
Clean UUCP ................................................ OK
List and/or clear temporary files ......................... OK
Clean up old log files .................................... OK
Start system message logging daemon ....................... OK
Start pty allocator daemon ................................ OK
Start network tracing and logging daemon .................. OK
Configure HP Ethernet interfaces .......................... OK
Configure HP 100BT interfaces ............................. OK
Configure HP SPP 100BT interfaces ......................... OK
Configure LAN interfaces .................................. OK
Start name server daemon .................................. N/A
Start NFS core subsystem .................................. OK
Start NIS+ server subsystem ............................... OK
Start NIS+ client subsystem ............................... OK
Start NIS server subsystem ................................ OK
Start NIS client subsystem ................................ OK
Start NFS client subsystem ................................ OK
Start the Trusted Mode with Nis+ subsystem ................ N/A
Configure pseudo devices for MAC/LLA access ............... OK
Start multicast routing daemon ............................ N/A
Start Internet services daemon ............................ OK
Start dynamic routing daemon .............................. N/A
Start router discover protocol daemon ..................... N/A
Configuring PPP Interface ................................. OK
Start RARP protocol daemon ................................ N/A
Start remote system status daemon ......................... N/A
Configuring man pages for Internet Services ............... OK
Starting mail daemon ...................................... OK
Starting outbound connection daemons for DDFA software .... N/A
Start SNMP Master Network Management daemon ............... OK
Start OSPF MIB Network Management subAgent ................ N/A
Start SNMP HP-UNIX Network Management subAgent ............ OK
Start SNMP MIB-2 Network Management subAgent .............. OK
Start SNMP Trap Dest Network Management subAgent .......... OK
Start DCE daemons ......................................... N/A
Start RPC daemon if needed ................................ OK
Start the Isogon License Server daemon .................... N/A
Start remote boot daemon .................................. OK
Starting X Font Server at TCP port 7000 ................... N/A
Start vt daemon ........................................... OK
Start time synchronization ................................ OK
Start accounting .......................................... OK
Starting the password/group assist subsystem .............. OK
Starting disk array monitor daemons. ...................... OK
Start print spooler ....................................... OK
Starting HP Distributed Print Service ..................... OK
Start clock daemon ........................................ OK
Support Tools Informational Fileset ....................... OK
Start diagnostic subsystem ................................ OK
Starting hardware predictive .............................. OK
Start environment monitoring daemon ....................... OK
Start auditing subsystem .................................. N/A
Start audio server daemon ................................. N/A
SAM System administration configuration ................... OK
MeasureWare performance software is being started. ........ OK
Reinitialize Software Distributor agent daemon ............ OK
Starting Event Monitoring Service ......................... OK
Start EMS SNMP subagent ................................... OK
Start NFS server subsystem ................................ OK
Start X print server(s) ................................... N/A
Start CDE login server .................................... OK
The system is ready.
GenericSysName [HP Release B.11.00] (see /etc/issue)
Console Login:
In the next sections, you will learn more details on how these tasks are performed.
14.2 Processor Dependent Code
The boot procedure for all HP-9000 systems is controlled by program code, PDC, that resides on the ROM installed inside the system. The PDC is different for different computers (that is why its name is processor dependent). PDC is executed after the system is reset or turned on. It performs self-tests and then tests hardware attached to the system. After thoroughly scanning the memory, it initializes the console and copies the console path to the memory. It copies the boot path and autoboot flag into memory. If the autoboot is disabled, it displays a menu of commands. If the autoboot is enabled, it displays a message showing that the system is going to start the autoboot process and gives you the option to interrupt this process by pressing a key within 10 seconds. If you press a key within 10 seconds, you get the PDC menu; otherwise, the system starts booting from the primary boot path.
PDC is an important part, where you perform system administration tasks to specify primary and alternate boot devices. You can display hardware paths and search boot devices attached to the system. You can also use PDC to boot the system from a device other than primary or secondary boot devices. On V-Class machines, PDC can also be used to boot into single-user mode.
PDC Menus
You get PDC menus by interrupting the boot process by pressing a key when a message like the following is displayed.
Processor is starting the autoboot process.
To discontinue, press any key within 10 seconds.
PDC menus may differ on servers and workstations slightly, but most of the commands are the same on all systems. A typical PDC menu looks likes the following.
---------------------- Main Menu --------------------------
Command Description
------- -----------
BOot [PRI|ALT|] Boot from specified path
PAth [PRI|ALT|] Display or modify a path
SEArch [Display|IPL] [] Search for boot device
COnfiguration menu Displays or sets boot values
INformation menu Displays hardware information
SERvice menu Displays service commands
Help [
No comments:
Post a Comment