errdemon Daemon

Purpose

Starts error logging daemon (errdemon) and writes entries to the error log.

Syntax

errdemon [ [  -B BufferSize ]  [  -d  |  -D ] [  -i File ]  [  -s LogSize ]  [  -t Time ] [  -m MaxDups ] |  -l ]

Description

The error logging daemon reads error records from the /dev/error file and creates error log entries in the system error log. Besides writing an entry to the system error log each time an error is logged, the error logging daemon performs error notification as specified in the error notification database. The /etc/objrepos/errnotify file is the error notification database. The default system error log is maintained in the /var/adm/ras/errlog file. The last error entry is placed in nonvolatile random access memory (NVRAM). During system startup, this last error entry is read from NVRAM and added to the error log when the error logging daemon is started.

The error logging daemon does not create an error log entry for the logged error if the error record template specifies Log=FALSE.

If you use the error logging daemon without flags, the system restarts the error logging daemon using the configuration values stored in the error log configuration database. By default, the errdemon daemon removes duplicate error log entries when they are logged very rapidly. This is to prevent run away error logging from adversely effecting system performance. The number of duplicate entries can be seen with a detailed error report.

If the PowerHA® pureScale® error logging is enabled, error log entries are sent to the PowerHA pureScale logstream, in addition to the local system error log. The PowerHA pureScale error logging status and logstream name are specified with the errlg_pscale_enabled and errlg_pscale_logstream values of the error log configuration database. The PowerHA pureScale client fileset must be installed on the system and bindings information for the service named CentralizedLogService must be setup. The log space and log stream objects specified as the PowerHA pureScale logstream must exist.

Use the errclear command to remove entries from the system error log.

Attention: The error logging daemon is normally started during system initialization. Stopping the error logging daemon can cause error data temporarily stored in internal buffers to be overwritten before it can be recorded in the error log file.

Flags

Item Description
-B BufferSize Uses the number of bytes specified by the BufferSize parameter for the error log device driver's in-memory buffer. The specified buffer size is saved in the error log configuration database. If the BufferSize parameter is larger than the buffer size currently in use, the in-memory buffer is immediately increased. If the BufferSize parameter is smaller than the buffer size currently in use, the new size is put into effect the next time the error logging daemon is started after the system is rebooted. The buffer cannot be made smaller than the hard-coded default of 8KB.

If this parameter is not specified, the error logging daemon uses the buffer size from the error log configuration database.

The size you specify is rounded up to the next integral multiple of the memory page size (4KB). The memory used for the error log device driver's in-memory buffer is not available for use by other processes. (The buffer is pinned). Be careful not to impact your system's performance by making the buffer excessively large. On the other hand, if you make the buffer too small, the buffer can become full if error entries arrive faster than they can be read from the buffer and put into the log file. When the buffer is full, new entries are discarded until space becomes available in the buffer. When this situation occurs, the error logging daemon creates an error log entry to inform you of the problem. You can correct the problem by enlarging the buffer.

-d Specifies that duplicate error log entries cannot be removed. The default behavior is to remove duplicates, which is indicated with the -D flag.
-D Specifies that duplicate entries are to be removed. This is the default.
-i File Uses the error log file specified by the File variable. The specified file name is saved in the error log configuration database and is immediately put into use.
-l Displays the values for the error log file name, file size, buffer size, and duplicate handling values from the error log configuration database.
-m MaxDups Specifies the maximum number of duplicate entries allowed before a duplicate error is forced out. The default is 1000. When an error has been duplicated the number of times that is specified in MaxDups, a duplicate error is written just as it would be if a unique error was logged. The values allowed for MaxDups are 1 to 2147483647.
-s LogSize Uses the size specified by the LogSize variable for the maximum size of the error log file. The specified log file size limit is saved in the error log configuration database, and it is immediately put into use. If the log file size limit is smaller than the size of the log file currently in use, the error logging daemon renames the current log file by appending .old to the file name. The error logging daemon creates a new log file with the specified size limit. Generate a report from the old log file using the -i flag of the errpt command.

If this parameter is not specified, the error logging daemon uses the log file size from the error log configuration database.

-t Time Specifies the approximate time interval (in milliseconds) within which an error is considered a duplicate if it is identical to the previous error. Errors occurring after this time interval are not considered duplicates even if they are identical to the previous error. The default interval is 10000, or 10 seconds. The values allowed for Time are 1 to 2147483647.

Note: This flag eliminates duplicate entries in the case of an error logger rapidly logging the same error, this usually indicates a loop condition. It is not intended to catch all duplicate errors for which there may be error notification objects. Making this value sufficiently large may compromise error notification by eliminating too many errors. See the errpt command for a description of eliminating duplicate errors in an error report.

Security

Access Control: Only the root user can run this daemon.

Examples

  1. To start the error-logging daemon, enter:
    /usr/lib/errdemon
  2. To view the current maximum error-log size, enter:
    /usr/lib/errdemon -l
  3. To change the current maximum error-log size from 1MB to 64KB, enter:
    /usr/lib/errdemon -s 65536
  4. To only consider errors that are logged within the last 10 milliseconds to be duplicates, enter
    /usr/lib/errdemon -t 10

Files

Item Description
/dev/error Source of error records.
/var/adm/ras/errtmplt Contains the error template repository.
/usr/lib/errdemon Contains the errdemon daemon.
/etc/objrepos/SWservAt Contains the software service aids attributes object class; that is, the error log configuration database.