Skip to Content
Cisco IOS Cookbook, 2nd Edition
book

Cisco IOS Cookbook, 2nd Edition

by Kevin Dooley, Ian Brown
December 2006
Intermediate to advanced
1188 pages
72h 8m
English
O'Reilly Media, Inc.
Content preview from Cisco IOS Cookbook, 2nd Edition

Changing the Default Log Facility

Problem

You want to change the default logging facility.

Solution

Use the logging facility configuration command to change the syslog facility that the router sends error messages to:

Router#configure terminal
Enter configuration commands, one per line.  End with CNTL/Z.
Router(config)#logging host 172.25.1.1
Router(config)#logging facility local6
Router(config)#end 
Router#

The default syslog facility setting is local7.

Discussion

By default, the router will forward all syslog messages to the server’s local7 log facility. You can modify this behavior and forward all of your router’s syslog messages to another facility by utilizing the logging facility configuration command. Table 18-3 illustrates the possible logging facilities that a router will accept.

Table 18-3. Cisco logging facility types

FacilityDescription
AuthAuthorization system
CronCron/at facility
DaemonSystem daemons
KernKernel
local0Local use
local1Local use
local2Local use
local3Local use
local4Local use
local5Local use
local6Local use
local7Local use (Default facility for Cisco routers)
LprLine printer system
MailMail system
NewsUSENET news
sys9System use
sys10System use
sys11System use
sys12System use
sys13System use
sys14System use
SyslogSyslog itself
UserUser process
UucpUnix-to-Unix copy system

Tip

We generally recommend that you choose one of the “local” facilities, as these are intended specifically for this type of use.

There are a number of reasons why it can be quite useful to choose a facility other than the ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

IP Routing on Cisco IOS, IOS XE, and IOS XR: An Essential Guide to Understanding and Implementing IP Routing Protocols

IP Routing on Cisco IOS, IOS XE, and IOS XR: An Essential Guide to Understanding and Implementing IP Routing Protocols

Brad Edgeworth, Aaron Foss, Ramiro Garza Rios
Cisco Software-Defined Access

Cisco Software-Defined Access

Srilatha Vemula, Jason Gooley, Roddie Hasan

Publisher Resources

ISBN: 0596527225Supplemental ContentErrata Page