SSH Reference Manual
Destinations for Log Messages 
The SSH2 component can log to the following destinations: 
•  A file configured with the LOGFILE parameter. 
•  An process-internal memory cache for log message (parameters LOGLEVELCACHE, LOGCACHESIZE) 
•  A device configured with the LOGCONSOLE parameter. 
•  An event collector process configured with the LOGEMS parameter. 
By default, the SSH2 component logs messages only to the home terminal. Logging to a file or EMS is not enabled by 
default. It is possible to log to multiple destinations. Which combination is best will depend on your operative 
environment. The following shows some examples on how to combine the log destinations in different scenarios: 
•  Getting used to SSH2, "experimenting": It may be easiest to start SSH2 with the default settings. In that case 
SSH2 will issue log messages to the home terminal only, making it easy to view the messages. Note that you 
cannot start the SSH2 component NOWAIT this way. It may be helpful to raise the LOGLEVEL to 100 in that 
case. 
LOGFILE * 
LOGEMS * 
LOGLEVELCONSOLE 100 
LOGCONSOLE % 
•  Log to EMS and only log startup and severe messages:  
LOGFILE * 
LOGCONSOLE * 
LOGEMS $0 
LOGLEVELEMS 30 
•  Log normal operations to a file and startup and severe messages to EMS:  
LOGCONSOLE * 
LOGFILE $vol.subvol.logfile 
LOGLEVELFILE 50 
LOGEMS $0 
LOGLEVELEMS 30 
•  Log normal operations to a file and startup and severe messages to EMS, log detail information to log cache 
and write content to the log file via SSHCOM command FLUSH LOGCACHE only after specific events:  
LOGCONSOLE * 
LOGFILE $vol.subvol.logfile 
LOGLEVELFILE 50 
LOGEMS $0 
LOGLEVELEMS 30 
LOGLEVELCACHE 85 
Writing to the log cache causes the least overhead. If detailed log messages need to be analyzed, then it is often best to 
set the value of LOGLEVELCACHE to a higher value (e.g. via SSHCOM command SET LOGLEVELCACHE) and 
leave the parameter LOGLEVELFILE at the default level. After the event occurred that is of interest the messages in the 
log cache should then be written to the log file using SSHCOM command FLUSH LOGCACHE (see section "SSHCOM 
Command Reference"). The SSHCOM command ROLLOVER LOGFILE can be used to force the log file rollover 
allowing to keep the log file small. 
HP NonStop SSH Reference Manual  Monitoring and Auditing • 309 










