JavaStation Client Software Guide

JavaStation Boot Sequence

When the JavaStation computer is powered on, it initiates communication with several different network services to obtain the information and software it requires to operate on the network. The JavaStation boot sequence is accomplished by the following network services:

These services need not reside on the same machine. A DNS service must also be provided on the network for the JavaStation systems to operate correctly, but it is not directly involved in the boot sequence.

The boot sequence can occur in a variety of ways. Essentially, it must accomplish the following tasks:

  1. Lease an IP address to the JavaStation computer. Each JavaStation system must lease an IP address from an address pool managed by a DHCP server. The DHCP server should assign addresses dynamically. The Solaris DHCP server can also assign IP addresses permanently, but this method creates greater administration overhead if many JavaStation computers reside on the network.

  2. Deliver and boot the JavaOS software on the JavaStation computer. The JavaOS image is booted from flash memory if the JavaStation computer has flash memory. Otherwise, the JavaOS image is delivered to the JavaStation computer from a network server via TFTP, NFS, or a combination of TFTP and NFS.

  3. Deliver the main user application to the JavaStation computer. The main user application is either linked directly to the JavaOS boot image or delivered separately to the JavaStation computer via HTTP.

  4. Update the JavaOS image stored in flash memory. This task applies only to JavaStation clients with flash memory ("tower" models). After the JavaStation computer boots, the JavaOS image stored in flash memory is updated if a newer copy of the JavaOS image exists on the network and if flash updating is enabled. If the flash memory is updated, the JavaStation computer immediately reboots with the newer copy of JavaOS.

The following sections describe the JavaStation computer's power-on and boot sequence tasks in detail.

Power On

The JavaStation programmable read-only memory (PROM) includes TFTP, NFS, and DHCP client implementations and is thus able to carry out the boot sequence. At power on, the PROM checks to see if flash memory is present and valid. If so, the PROM loads it into memory and transfers control to it. JavaOS initializes itself and then completes Task 1, described below.

If the above tests fail, the JavaOS image is not loaded from flash into memory, and the PROM proceeds to complete Task 1 itself.

Task 1: Lease an IP Address

Either the PROM or the JavaOS software leases an IP address from the DHCP server by completing the following "handshake" with the JavaStation DHCP server. For simplicity, the description below refers to the PROM or the JavaOS software as "the DHCP client."

  1. The DHCP client broadcasts DHCPDISCOVER packets until a DHCPOFFER is received. The DHCPDISCOVER packet includes the Client Class Identifier option, which identifies the DHCP client as a JavaStation (see "Vendor-Specific Options"). If the broadcast takes an unusually long time, a notice is displayed on the JavaStation screen approximately every minute so the user knows if the server is responding or not.

  2. One or more DHCP servers respond with DHCPOFFER packets. The DHCPOFFER(s) are examined by the DHCP client to determine whether they contain the options required to boot JavaStation computers (see "DHCP").

  3. The DHCP client chooses the best DHCPOFFER it receives that contains the required options. (The best offer is the DHCPOFFER with the most additional options that are applicable to JavaStation computers.) The DHCP client remembers the IP address of the server that sent the offer.

  4. The DHCP client broadcasts a DHCPREQUEST packet. This packet contains the IP address of the server chosen in the previous step. All other DHCP servers that responded in the second step are thus informed that they have not been selected.

  5. The selected server sends a DHCPACK packet back to the DHCP client.

At this point, the JavaStation has received all of its configuration information from the DHCP server. The figure below illustrates the initial handshake.

Figure 2-1 JavaStation Client - DHCP Server Handshake

Graphic

Task 2: Deliver and Boot the JavaOS Software

Task 2 is to pass control of the JavaStation to the JavaOS software. If the JavaOS image has not been loaded from flash memory, it must now be downloaded from the network. The information required for the download was passed to the JavaStation computer in the initial DHCP handshake. Specifically, this information consists of:

The following table shows JavaOS boot information from the DHCP server and the resulting actions taken by the PROM.

Table 2-1 DHCP Information for Booting JavaOS

If the boot protocol is... 

And the DHCP server also delivers... 

The JavaOS software is downloaded and booted as follows  

Not set or TFTP  

The IP address of a server that contains an initial boot program (the "booter") in its TFTP root directory  

The JavaStation PROM downloads the booter from the server using TFTP, then transfers control to it.  

When the booter begins execution, it checks the PROM's device tree for the name and location of the JavaOS image and the name of a server that contains this image in an NFS-exported directory. If the booter does not find this information in the PROM, it obtains it from the DHCP server. The booter mounts this directory using NFS, copies the JavaOS image, and transfers control to it.  

Note that this method of delivery is deprecated in favor of downloading JavaOS directly over NFS.  

 

The IP address of a server that contains the JavaOS image in its TFTP root directory 

The JavaStation PROM downloads JavaOS from the server using TFTP, then transfers control to it.  

Note that this method of delivery is much slower than downloading JavaOS over NFS.  

NFS  

The IP address of a server that contains the JavaOS image in an exported NFS directory 

The JavaStation PROM downloads JavaOS from the server using NFS, then transfers control to it.  

 

The DHCP options used to deliver the above information are described in "The DHCP Service Configuration Table ".

Task 3: Deliver Main Application

The main application can be linked to the JavaOS binary into a single executable that is stored in flash or delivered to the JavaStation computer using either method described in the table above. The method of binding an application to the JavaOS binary is called static linking and is described in Chapter 6, Statically Linking an Application to the JavaOS Image .

Alternatively, a main application is delivered to the JavaStation by a web server (HTTP server) on the network. The URL of the application zip file and other JavaOS application-loading properties are passed to the DHCP client in the initial handshake through the DHCP Vendor-Specific Options, as described in "Vendor-Specific Options". For descriptions of the JavaOS application loading properties, see Chapter 5, Dynamically Loading Applications .

Task 4: Update Flash Memory With New JavaOS Image

Tower model computers may include flash memory to store the JavaOS image. After the JavaOS software finishes its initialization, it determines whether it needs to update the flash memory with a new JavaOS image based on the following criteria:

Both the property and the checksum are delivered by DHCP as Vendor-Specific Options. See "Vendor-Specific Options".

The JavaOS checksum identifies the revision level of the JavaOS image. For more information, see "Managing the JavaOS Checksum".

The results of each possible set of conditions are shown in the table below.

Table 2-2 Conditions for Updating JavaStation Flash Memory

Conditions 

Results  

javaos.alwaysUpdate

Checksum 

 

Not set  

different  

JavaOS software opens a Flash Update dialog box on the JavaStation screen. The user has the option of updating flash memory with the new JavaOS binary. 

Not set  

same  

JavaOS software does not update the flash memory.  

true

different  

JavaOS software updates flash memory without querying the user.  

true

same 

JavaOS software does not update the flash memory.  

false

different  

JavaOS software does not update the flash memory.  

false

same  

JavaOS software does not update the flash memory.  

If the flash memory is updated, the JavaStation computer immediately reboots with the newly updated JavaOS image.

Note that if any of the following conditions exist, flash memory is never updated: