• Aucun résultat trouvé

Start-Up Procedures

Dans le document apollo System Software Managing (Page 93-100)

Administering Nodes in the l\Tetvyork

3.8 Start-Up Procedures

This section describes node start-up procedures, user log-in procedures, and related files.

3.8.1 Node Startup

Inlt

Inlt

1 m

dm ''''HlrrlJID

I node_datal stahup [. type]

letc/ttys

spm startup

Isys/node _data [. node _Id] Istartup. spm

getty Start process for tty lines and start window systems

Note: Solid lines ( - ) indicate automatic operations. Dashed lines (- - -) indicate paths where the preceding file invokes the following file (for example, letc/rc invokes letc/rc. user.

Figure 3-5. Node Start-Up Files and Operations

3.8.2 111e letc/rc

~e

The letc/rc file is a Bourne shell script executed as the first step in node startup by letc/init. The letc/rc file starts servers and other global processes as root. wheel. none.

This file must also contain the commands that

• Delete any files in the 'node..,.data/tmp and 'node_data/systmp directories

• Start any servers that require root access rights

• Invoke the letc/rc.local and letc/rc.user files (described in the next subsections)

Starting Servers in /ete/re

The /ete/re file contains lines that invoke servers. When the file processes these invoca-tions, it first looks in the /etc/daemons directory to see if a file named for the server exists control the starting of server processes by /ete/re.

3.8.3 The letc/rc.local File

The /ete/re.user file, invoked by /ete/re during start-up processing, contains commands to start servers and other global processes that run as user. server. none, not as root. This file

" mono-chrome node; the file is named 'node_data/startup. 1280bw. Corresponding start-up files for other types of displays draw the locations of the DM windows in different places, but

Figure 3-7. Start-Up Script for DN3000 Monochrome (startup.1280bw)

3.8.7 Server Process Manager Startup

Using 'node_data/spm_control to Control Node Access

The 'node_data/spm_control can prevent unauthorized users from creating processes on or logging into a node. If this file exists on the node running spm, all process creation and login requests are validated. Only users with a SID matching an entry in the file are allowed access; all others are rejected. If the file does not exist, all requests are allowed.

Each SID entry should be in the following format:

person.group.org

where a % character in a field matches anything.

Figure 3-8 shows a sample 'node_data/spm_control file.

# allow access to all users

%.%.%

# allow access to all members of group grp

%.grp.%

Figure 3-8. Sample 'node_datalspm_control File

The tty Line and Window System Startup

The tty lines connect "dumb" terminals to workstations, either directly or through a mo-dem and telephone lines. The letc/ttys file contains commands to start tty lines and win-dow systems. A sample line from the letc/ttys file is shown below:

ttyOl "/etc/getty d1200" dialup on secure

The line starts tty port 1, specifying that it will be monitored by the getty program, that it will run 1200 baud, and that only users with root access will be allows to access the line.

The format for the command lines in the letc/ttys file follows:

tty_line command terminal_type status [window="cmd_string"]

command

terminaCtype

status

window=" cmd _string"

The terminal's entry in the device directory, Idev.

The command to execute for the line. This entry is usually getty. Getty is a program that performs such tasks as rec-ognizing the baud rate, reading the log-in names, and call-ing login. For command you can also specify the start-up file for a window system terminal emulator or some other server process.

The type of terminal normally connected to that tty line, as found in the termcap database file.

A 2-entry option. For the first entry, specify on to enable the line; specify off to disable the line. For the first entry, to allow only root to log in on this line, specify secure. Do not quote this field.

The cmd _string argument is the pathname of the window

Tabs and spaces separate the fields. Use double quotes to enclose fields that contain more than one word (except the status field). If you omit a field, its value defaults to null.

NOTE: .Previous releases used the tty line servers siomonit and siologin to enable tty lines. Although we recommend that you use the letc/ttys file to enable tty lines, you can still use siomonit and siologin. To do so, disable all the entries for serial lines in letc/ttys by setting their status to off. Then, see Subsection 3.12.5, "siologin and siomonit Line Servers, " at the end of this chapter for information on siomonit and siologin.

3.8.8 User Login

Figure 3-9 illustrates user log-in processing.

login

/sys/dm/startupJogln I. type]

or

• node_data/startup Jogln I. type]

~/user _data/startup _ dm I. type]

or

~ /user _ data/sh/logln

Note: Solid lines ( - ) indicate automatic operations. Dashed lines (---) indicate paths where the the preceding file must call the following file.

Figure 3-9. Node Start-Up Files and Operations

User Log-In Processing

1. When a user logs in to the node, the system:

a. First looks in the user's home directory for the S(HOME)/.environ file. If this file exists, it sets the environment and systype accordingly (if the corre-sponding environment was installed on the node).

b. Looks for a shell definition in the user's registry entry. If one is not there, the appropriate shell for the current environment is used.

2. The DM executes one of the following files:

a. 'node_data/startup_login[.type] - The DM first looks for this file. If it finds it, it executes the file.

b. Isys/dm/startup_login[.type] - If the DM cannot find the file in 'node_data, it uses this one.

The startup_login file is used to perform tasks that need to be invoked every time someone logs in to this node. These tasks include, specifying windows, creat-ing shells, and runncreat-ing user-specific scripts. The Isys/dm/startup_login file is supplied with the system. You should copy it to each node's 'node_data direc-tory. Then you can modify it specifically for each individual node.

3. As supplied, the startup_login file invokes -/user_data/startup_dm [. type] . This file, which contains commands private to the user to be executed at his login, is not supplied with the system, but must be created. To cause it to be executed, remove the pound sign (#) from the last line in the Isys/dm/startup_login file.

The line reads:

# cmdf user_data/startup_dm[.type]

The SPM does not execute this script during remote logins. See Using Your SysV Environment for more information about this start-up file.

Key Definitions

When a user logs in to the node, the DM sets the default key definitions for the node ac-cording to the system type specified in letc/environ or (if one exists) S(HOME)/.environ.

Three sets of standard key definitions exist, one for each environment. When the user logs out, the DM resets the key definitions to the system type specified in letc/environ.

3.8.9 Log-Out Script Processing

The DM processes log-out scripts. The log-out script must exist in either the Isys/dm or the 'node_data directory, and the script must be named startup_)ogout[.type], where .type is the appropriate display type suffix. You cannot start up new processes with the DM cp, cps, or cpo commands from this script.

Dans le document apollo System Software Managing (Page 93-100)