The OpenBoot PROM Monitor

The OpenBoot PROM Monitor

The OpenBoot PROM monitor is based on the Forth programming language, and can be used to run Forth programs that perform the following functions:

  • Booting the system, by using the boot command

  • Performing diagnostics on hardware devices by using the diag command

  • Testing network connectivity by using the watch-net command

The OpenBoot monitor has two prompts from which commands can be issued: the ok prompt, and the > prompt. In order to switch from the > prompt to the ok prompt, you simply need to type n:

> n

Commands are typically issued from the ok prompt. These commands include boot, which boots a system from the default system boot device, or from an optional device specified at the prompt. Thus, if a system is at run level 0, and needs to be booted, the boot command with no options specified will boot the system:

ok boot
SPARCstation 20, Type 5 Keyboard
ROM Rev. 2.4, 256 MB memory installed, Serial #456543
Ethernet address 5:2:12:c:ee:5a HostID 456543
Rebooting with command:
Boot device: /iommu@f,e0000000/sbus@f,e0001000/espdma@f,400000/esp@f,8...
SunOS Release 5.9 Version Generic 32-bit
Copyright (c) 1983-2002 by Sun Microsystems, Inc.
configuring IPv4 interfaces: hme0.
Hostname: Winston
The system is coming up. Please wait.
checking ufs filesystems
/dev/rdsk/c0t0d0s1: is clean.
NIS domainname is Cassowary.Net.
starting rpc services: rpcbind keyserv ypbind done.
Setting netmask of hme0 to
Setting default IPv4 interface for multicast: add net 224.0/
4: gateway Winston
syslog service starting.
Print services started.
volume management starting.
The system is ready.
winston console login:

Alternatively, if you have modified your hardware configuration since the last boot and you want the new devices to be recognized, you should always reboot using this command:

ok boot -r

This is equivalent to performing a reconfiguration boot using the following command sequence in a shell as the superuser:

# touch /reconfigure; sync; init 6


# reboot -- -r

So far, we’ve looked at automatic booting. However, sometimes it is desirable to perform a manual boot, using the command boot -a, where parameters at each stage of the booting process can be specified. These parameters include:

  • The path to the kernel that you wish to boot

  • The path to the kernel’s modules directory

  • The path to the system file

  • The type of the root file system

  • The name of the root device

For example, if we wished to use a different kernel, such as an experimental kernel, we would enter the following parameters during a manual boot:

Rebooting with command: boot -a
Boot device: /pci@1f,0/pci@1,2/ide@1/disk@0,1:a File and args: -a
Enter filename [kernel/sparcv9/unix]: kernel/experimental/unix
Enter default directory for modules [/platform/SUNW,Sparc-20/kernel
/platform/sun4m/kernel /kernel /usr/kernel]:
Name of system file [etc/system]:
SunOS Release 5.9 Version Generic 64-bit
Copyright (c) 1983-2002 by Sun Microsystems, Inc.
root filesystem type [ufs]:
Enter physical name of root device

To accept the default parameters, simply press ENTER when prompted. Thus, to only change the path to the experimental kernel, we would enter kernel/experimental/unix at the Enter filename prompt.

Part I: Solaris 9 Operating Environment, Exam I