United States-English |
|
|
HP-UX Reference > Llogger(1)HP-UX 11i Version 3: February 2007 |
|
NAMElogger — make entries in the system log DESCRIPTIONThe logger command provides a program interface to the syslog() system log module (see syslog(3C)). A message can be given on the command line, which is logged immediately, or a file is read and each line is logged. If no file or message is specified, the contents of the standard input are logged. OptionsThe logger command recognizes the following command-line options and arguments:
EXTERNAL INFLUENCESEnvironment VariablesLC_MESSAGES determines the language in which messages are displayed. If LC_MESSAGES is not specified in the environment or is set to the empty string, the value of LANG is used as a default for each unspecified or empty variable. If LANG is not specified or is set to the empty string, a default of "C" (see lang(5)) is used instead of LANG. If any internationalization variable contains an invalid setting, logger behaves as if all internationalization variables are set to "C". See environ(5). EXAMPLESSend the message System rebooted to the syslogd daemon: logger System rebooted Send output from the users command (see users(1) to the syslogd daemon, marked as level info and facility local0. The message is tagged with the string USERS: users | logger -p local0.info -t USERS Send the message System going down immediately!!! to the syslog daemon, at the emerg level and user facility: logger -p user.emerg "System going down immediately!!!" WARNINGSThe logger command has no effect if the syslogd daemon (see syslogd(1M)) is not running on the system. Messages written in locales other than the POSIX/C locale are not supported. |
Printable version | ||
|