*nix Documentation Project
·  Home
 +   man pages
·  Linux HOWTOs
·  FreeBSD Tips
·  *niX Forums

  man pages->HP-UX 11i man pages -> logger (1)              
Title
Content
Arch
Section
 

Contents


 logger(1)                                                         logger(1)




 NAME    [Toc]    [Back]
      logger - make entries in the system log

 SYNOPSIS    [Toc]    [Back]
      logger [-t tag] [-p pri] [-i] [-f file] [message...]

 DESCRIPTION    [Toc]    [Back]
      The 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.

    Options    [Toc]    [Back]
      The logger command recognizes the following command-line options and
      arguments:

           -t tag         Mark every line in the log with the specified tag.
                          The default is the value returned by getlogin()
                          (see getlogin(3C)).  If getlogin() returns NULL,
                          syslog is the default.

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

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

           -f file        Log the contents of the specified file.

           message        The message to log; if not specified, the file
                          specified by the -f option or standard input is
                          logged.

 EXTERNAL INFLUENCES    [Toc]    [Back]
    Environment Variables
      LC_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



 Hewlett-Packard Company            - 1 -   HP-UX 11i Version 2: August 2003






 logger(1)                                                         logger(1)




      "C".  See environ(5).

    International Code Set Support    [Toc]    [Back]
      Single- and multi-byte character code sets are supported.

 EXAMPLES    [Toc]    [Back]
      Send 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!!!"

 WARNINGS    [Toc]    [Back]
      The 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.

 AUTHOR    [Toc]    [Back]
      logger was developed by the University of California, Berkeley.

 SEE ALSO    [Toc]    [Back]
      syslogd(1M), getlogin(3C), syslog(3C).

 STANDARDS CONFORMANCE    [Toc]    [Back]
      logger: XPG4, POSIX.2


 Hewlett-Packard Company            - 2 -   HP-UX 11i Version 2: August 2003
[ Back ]
      
      
 Similar pages
Name OS Title
logger Tru64 Makes entries in the system log
man IRIX print entries from the on-line reference manuals; find manual entries by keyword
bptojdb Tru64 Converts bootptab entries into permanent, static IP entries for JOIN databases.
getdirentries FreeBSD get directory entries in a file system independent format
msgmap HP-UX number of entries in the System V IPC message space resource map
semume HP-UX maximum number of System V IPC undo entries per process
getdirentries Tru64 Get directory entries in a file-system independent format.
getdents FreeBSD get directory entries in a file system independent format
VFS_START FreeBSD make a file system operational
getdents IRIX read directory entries and put in a file system independent format
Copyright © 2004-2005 DeniX Solutions SRL
newsletter delivery service