Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Announcements

Welcome to Cisco Support Community. We would love to have your feedback.

For an introduction to the new site, click here. If you'd prefer to explore, try our test area to get started. And see here for current known issues.

New Member

Syslog message customization

Hey guys,

I have a question about syslog messages. When syslog messages are received on a syslog server, they usually look like this:

<syslog-count>: <sequence-number>: <timestamp>:%<facility>-<severity>-<mnemonic>:<message-text>
For example: 24:000024:02:18:37:%SYS-5-CONFIG_I:Configured from console by console

I want to get rid of <syslog-count> and <sequence-number> values. I've found a way to omit the <sequence-number> value by using the "no service sequence-numbers" global configuration command. But I still can't find a way to get rid of the <syslog-count> value. I tried to use Embedded Syslog Manager (ESM), but no luck. If someone knows how to do that your help will be greatly appreciated.

Everyone's tags (1)
7 REPLIES
Cisco Employee

Re: Syslog message customization

Configure the following:

no logging message-counter syslog

New Member

Re: Syslog message customization

Thank you, jclarke. Helpful as always.

New Member

Re: Syslog message customization

Hello... I have the exact same problem, but unfortunately on a IOS Version 12.2(18)SXF7 fitted at a cisco WS-C6509-E (R7000)... the command "no logging message-counter syslog" is not available on this IOS version... any ideas on how-to disable syslog message counter?

Thank you and regards

Re: Syslog message customization

without seeing a syslog message as an example, I can just assume that you don't have syslog message counters enabled, but only sequence numbers. Try

    no service sequence-numbers

to get rid of them.

Cisco Employee

Re: Syslog message customization

I was just going to say that :-).

New Member

Re: Syslog message customization

yep, sure...

here the log message received:

Feb 16 17:01:41 172.22.1.1 78: 000096: Feb 16 17:01:05: %SYS-5-CONFIG_I: Configured from console by admin onvty0 (172.22.3.22)

78 is the number I want to get ride of.

the syslog message should be received like this [ taken from a C2960 with IOS 12.2(55)SE1 ]:

Feb 16 17:00:38 172.21.1.11 : 038306: Feb 16 17:00:37: %LINEPROTO-5-UPDOWN: Line protocol on Interface GigabitEthernet0/4, changed state to up

on the 2960 the no logging message-counter syslog did the job

New Member

Re: Syslog message customization

the "no service sequence-numbers" removed the sequence number

log w/service sequence-numbers
Feb 16 17:01:41 172.22.1.1 78: 000096: Feb 16 17:01:05: %SYS-5-CONFIG_I: Configured from console by admin onvty0 (172.22.3.22)


log w/no service sequence-numbers
Feb 16 17:09:33 172.22.1.1 79: Feb 16 17:08:57: %SYS-5-CONFIG_I: Configured from console by admin onvty0 (172.22.3.22)
3564
Views
10
Helpful
7
Replies