[Contents] [Prev] [Next] [Index] [Report an Error]

## Configuring Log Severity for Individual and Systemwide Logs

You can change the severity setting for individual logs and the systemwide value.

When working with log severities, keep the following in mind:

- All log event categories have a default. However, the default values can vary for each category. For example, most event categories have a default severity of Error. However, some event categories may have a default severity of Notice, Warning, Info, and so on.
- Log event categories have two states—unassigned (default) and assigned. How a log event category reacts to the log severity command depends on its current state.
- You can change log severities for event categories at a systemwide level or an individual level. Systemwide changes are those that modify a large number of unassigned event categories at one time; for example, the command log severity debug off. Individual changes are those that indicate an explicit event category that you want to change; for example, the command log severity notice clicommand.
- Changes to log event categories at an individual level take precedence over those made at the systemwide level.
- Changes to log event categories at the systemwide level take precedence over the default.
- Assigning a log severity to an individual event category changes its state to Assigned. This means that you cannot change the severity of that event category using systemwide level commands until you return the event category to its default, unassigned state by using the no log severity eventCategory command.
- To return all logs, systemwide and individual, to their default, unassigned severity level, use the no log severity * command.
- To see whether individual or systemwide severity and verbosity settings are in effect, use the show log configuration command.

Example

The following example demonstrates the effects of event category state in regard to using systemwide commands:

1. In Configuration mode and having made no changes to the severity settings of any event categories, view the log configuration:

       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           no log severity

             category         severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          ERROR      low
       aaaEngineGeneral       ERROR      low
       aaaServerGeneral       ERROR      low
       aaaUserAccess          ERROR      low
       addressServerGeneral   ERROR      low
       ar1AaaServerGeneral    ERROR      low
       atm                    ERROR      low
       atm1483                ERROR      low
       atmAal5                ERROR      low

   Notice that the atm event category has a default severity of Error.

2. Change all event categories to Warning, systemwide, and view the log configuration:

       host1(config)#log severity warning
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           log severity WARNING

             category         severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          WARNING    low                   1
       aaaEngineGeneral       WARNING    low                   1
       aaaServerGeneral       WARNING    low                   1
       aaaUserAccess          WARNING    low                   1
       addressServerGeneral   WARNING    low                   1
       ar1AaaServerGeneral    WARNING    low                   1
       atm                    WARNING    low                   1
       atm1483                WARNING    low                   1
       atmAal5                WARNING    low                   1

3. Change the atm category to have a log severity of Emergency and view the log configuration:

       host1(config)#log severity emergency atm
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           log severity WARNING

       category               severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          WARNING     low                   1
       aaaEngineGeneral       WARNING     low                   1
       aaaServerGeneral       WARNING     low                   1
       aaaUserAccess          WARNING     low                   1
       addressServerGeneral   WARNING     low                   1
       ar1AaaServerGeneral    WARNING     low                   1
       atm                    EMERGENCY   low                   2
       atm1483                WARNING     low                   1
       atmAal5                WARNING     low                   1

4. Change all event categories to Alert, systemwide, and view the log configuration:

       host1(config)#log severity alert
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           log severity ALERT

       category               severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          ALERT       low                   1
       aaaEngineGeneral       ALERT       low                   1
       aaaServerGeneral       ALERT       low                   1
       aaaUserAccess          ALERT       low                   1
       addressServerGeneral   ALERT       low                   1
       ar1AaaServerGeneral    ALERT       low                   1
       atm                    EMERGENCY   low                   2
       atm1483                ALERT       low                   1
       atmAal5                ALERT       low                   1

   Notice that the atm event category that you individually assigned in Step 3 does not change.

5. Turn off log notification, systemwide, and view the log configuration:

       host1(config)#log severity off
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           log severity OFF

             category         severity    verbosity   filters   notes
       --------------------   ---------   ---------   -------   -----
       aaaAtm1483Cfg          OFF         low                   1
       aaaEngineGeneral       OFF         low                   1
       aaaServerGeneral       OFF         low                   1
       aaaUserAccess          OFF         low                   1
       addressServerGeneral   OFF         low                   1
       ar1AaaServerGeneral    OFF         low                   1
       atm                    EMERGENCY   low                   2
       atm1483                OFF         low                   1
       atmAal5                OFF         low                   1

   Notice that the atm event category does not change.

6. Remove the assigned status of the atm event category and view the log configuration:

       host1(config)#no log severity atm
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           log severity OFF

             category         severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          OFF        low                   1
       aaaEngineGeneral       OFF        low                   1
       aaaServerGeneral       OFF        low                   1
       aaaUserAccess          OFF        low                   1
       addressServerGeneral   OFF        low                   1
       ar1AaaServerGeneral    OFF        low                   1
       atm                    OFF        low                   1
       atm1483                OFF        low                   1
       atmAal5                OFF        low                   1

   Notice that the atm event category follows the systemwide severity level of OFF. The systemwide setting takes precedence over the atm event category default of Error.

7. Change all event categories, systemwide, to their default/unassigned levels, and view the log configuration:

       host1(config)#no log severity *
       Please wait....
       host1(config)#run show log config
           log destination console severity WARNING
           log destination nv-file severity CRITICAL
           log destination syslog 10.10.4.240 facility 7 severity DEBUG
           no log engineering
           log fields timestamp instance no-calling-task
           no log here

       Warning: Logging to this terminal is disabled
           no log severity

             category         severity   verbosity   filters   notes
       --------------------   --------   ---------   -------   -----
       aaaAtm1483Cfg          ERROR      low
       aaaEngineGeneral       ERROR      low
       aaaServerGeneral       ERROR      low
       aaaUserAccess          ERROR      low
       addressServerGeneral   ERROR      low
       ar1AaaServerGeneral    ERROR      low
       atm                    ERROR      low
       atm1483                ERROR      low
       atmAal5                ERROR      low

[Contents] [Prev] [Next] [Index] [Report an Error]