www.delorie.com/gnu/docs/inetutils/inetutils_39.html   search  
Buy GNU books!

GNU networking utilities

[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

12.1 Invoking

The options are as follows :

Log the process ID of the logger process with each line.

Log the message to standard error, as well as the system log. This option might not be supported on all systems.

`-f FILE'
Log the content of the specified file.

Enter the message with the specified priority. The priority may be specified numerically or as a `facility.level' pair. For example, `-p local3.info' logs the message at the informational level in the `local3' facility. The default is `user.notice'.

The actual list of supported facilities and levels is system specific.

`-t TAG'
Mark every line in the log with the specified tag.

The options are followed by the message which should be written to the log. If not specified, and the -f flag is not provided, standard input is logged.

The logger utility exits 0 on success, and >0 if an error occurs.

The following examples illustrate the usage of the logger command.

logger System rebooted

logger -p local0.notice -t HOSTIDM -f /dev/idmc

  webmaster     delorie software   privacy  
  Copyright 2003   by The Free Software Foundation     Updated Jun 2003