Logging In to UNIX Systems
An ANSI X3.64-compliant (UNIX) console session begins sending console messages to the Operations Sentinel server immediately after a session is established. However, SP-AMS must log in to the UNIX system before SP-AMS can send commands to the system. A UNIX system normally displays a login prompt requesting that a user-id be entered. Therefore, any input is assumed to be in response to the outstanding login prompt.
Requirements
SP-AMS must be logged in to the system when it sends unsolicited input, starts a process running, or requests information from the system. SP-AMS can also perform many actions without logging in to the system. For example, it can
Respond to outstanding prompts
Perform event report actions such as logging messages, raising and clearing alerts, and changing component attributes in Operations Sentinel
Activate and deactivate SP-AMS databases
Logging in to a system can be done either manually or automatically. A manual login requires that the operator type a response to the login prompt and to the password prompt from the system's console session in Operations Sentinel Console. The operator must do this for each system you want to automate. Additionally, the operator must do this each time a system is restarted.
Automating UNIX Login
SP-AMS can automatically log in to a system if the active SP-AMS database contains patterns that match the login and password requests. When SP-AMS matches the requests, it sends the appropriate user-id and password to the UNIX system. A complete login sequence might require patterns to match other prompts that are generated during login or to recognize abnormal conditions, such as an expired password or other conditions.
Automating Several UNIX Systems
If you are automating several UNIX systems, the login and password can be different for each system. In this case, you must either create unique patterns for each system you want to monitor, or use conditional logic within two patterns to supply the correct login and password for each system. You can test the variable _HOSTID within conditional logic to supply the correct login and password.
You can use a TOKEN HOSTID command in a pattern to match a message from a specific system. See 2.10.
The text of the login and password messages themselves can differ from host to host. If you are using the examples in the sample database spastart.bld, you may need to change the patterns to match the login and password messages produced by each of your hosts.
Example
The following example matches the password prompt from the UNIX system DP23 and sends the password "oper-01A" to the system:
DEFINE "LOGIN-MSGS" MESSAGE "Password:" TOKEN KEYWORD 1 "Password:" TOKEN HOSTID "DP23" ACTION PASSWORD "oper-01A" END
The sample database spastart.bld supplied with Operations Sentinel contains examples of patterns used during login sequences.