Solved

Nexus 7K Logging Information Setup

Posted on 2013-06-27
20
1,992 Views
Last Modified: 2013-07-17
Hello Experts,

Can someone show me how to configure our nexus 7k so that I can see all logging information.

I would like to see all logs that appear in the device while in terminal monitor mode.

Do I need to configure something like  >logging console debugging 7-debug?

If that is correct, I get the following message:

Or is it logging monitor 7?

Either way I would like to see all information that is logged to the NK7 no matter the severity level


Cheers

Carlton
0
Comment
Question by:cpatte7372
  • 11
  • 9
20 Comments
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39281855
logging console 7 (for the console port)

or

logging monitor 7 (for SSH or Telnet)
0
 

Author Comment

by:cpatte7372
ID: 39282659
Donjohnston,

Thanks for responding.

I issued the command logging monitor 7, however I get the following on some of more Nexus devices:

vmm                     5                       5
vntag_mgr               6                       6
vpc                     2                       6
vshd                    5                       5
xmlma                   3                       6
zschk                   2                       2

0(emergencies)          1(alerts)       2(critical)
3(errors)               4(warnings)     5(notifications)
6(information)          7(debugging)

2013 Jun 27 15:51:31 MX-N5K2 last message repeated 4 times
2013 Jun 27 15:55:33 MX-N5K2 last message repeated 2 times
2013 Jun 27 16:00:35 MX-N5K2 last message repeated 4 times
2013 Jun 27 16:05:41 MX-N5K2 last message repeated 4 times

As you can see, there are 6(information), 5(notifications), 2(critical) etc. however the output of show logg just gives me the repeated messages.

On another Nexus device I get the following after issuing the show logg


xmlma                   3                       3

0(emergencies)          1(alerts)       2(critical)
3(errors)               4(warnings)     5(notifications)
6(information)          7(debugging)

Do you know why I'm not seeing all the logging information?

Cheers

Carlton
0
 
LVL 50

Accepted Solution

by:
Don Johnston earned 500 total points
ID: 39282723
Nexus switches have limited buffer capacity for logging. Best practice is to use a syslog server.  

But if memory serves, I believe the command you need is "show logging nvram", "show logging <logfile>" or "show logging last <number of messages>".

But like I said, I've always used syslog on Nexus switches since there's usually more messages than can fit in the buffer.
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 

Author Comment

by:cpatte7372
ID: 39282747
don,

I'm going to try your logging suggestions now..
0
 

Author Comment

by:cpatte7372
ID: 39282793
don,

I understand the best approach is to use a syslog server. However, out of interest why does nvarm only show loggs up to Jun 19, see below.

2013 Jun 19 13:55:24 MX-N5K1 %$ VDC-1 %$ %VPC-2-PEER_KEEP_ALIVE_RECV_FAIL: In domain 98, VPC peer keep-alive receive has failed

Cheers
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39282802
Because that's when the logging destination was changed?

Sorry, I don't understand the question.
0
 

Author Comment

by:cpatte7372
ID: 39282812
don

I'm also seeing the following

last message repeated x times

How can I tell what the message is?

Cheers
0
 

Author Comment

by:cpatte7372
ID: 39282821
Sorry, I didn't make myself the show logging nvram specifies the the last log message as:

2013 Jun 19 13:55:24 MX-N5K1 %$ VDC-1 %$ %VPC-2-PEER_KEEP_ALIVE_RECV_FAIL: In domain 98, VPC peer keep-alive receive has failed

However, when I do show logging last 5 get:

MX-N5K1# show logging last 5
2013 Jun 27 21:20:58 MX-N5K1 last message repeated 4 times
2013 Jun 27 21:26:31 MX-N5K1 last message repeated 4 times
2013 Jun 27 21:30:40 MX-N5K1 last message repeated 2 times
2013 Jun 27 21:35:41 MX-N5K1 last message repeated 4 times
2013 Jun 27 21:40:39 MX-N5K1 last message repeated 4 times

This show logging last 5 shows the actual last message i.e.

2013 Jun 27 21:40:39 MX-N5K1 last message repeated 4 times

Not sure why logging last nvram also doesn't show:

2013 Jun 27 21:40:39 MX-N5K1 last message repeated 4 times

Cheers
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39282861
I dunno. There was a bug about the "last message repeated" message but I'm pretty sure that was fixed with 5.0 code.

Then again, it could be a result of the limited capacity of the buffer and NVRAM.
0
 

Author Comment

by:cpatte7372
ID: 39282976
I really would like to find a way to prevent the repeated logs appearing and have the actual logs appear.
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39284250
Are you logging to a defined logfile or to the buffer?

You really should log to a syslog server.  It solves all logging problems.
0
 

Author Comment

by:cpatte7372
ID: 39284296
DON,

Thanks for responding. I don't mind configuring a syslog server if it means that I won't get the repeated messages.....

If the 'repeated messages' changed into the actual log message then that would be fine....

Do you know what I mean?
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39284346
Yep.

I don't recall seeing the "repeated message" line when I've looked a syslog files on 5K or 7K switches.  And, like I said, I've never seen a Nexus in production that wasn't logging to a syslog server.

I think that the prudent approach is to use syslog for the logging.  Trying to make internal logging work is just an exercise in... futility. :-)
0
 

Author Comment

by:cpatte7372
ID: 39284372
The problem is, I need to be connected to the device when certain events appear in the log so as to execute a command.

For example, I use SecureCRT. When an event such as %OSPF-6-AREACHG: appears on the router SecureCRT automatically runs the command show ip ospf neighbor on the router and sends me the results in text file.

I don't think there are any syslog servers out there that can do that ....
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39284502
Oh...

For that type of thing, on a Nexus, I use EEM.
0
 

Author Comment

by:cpatte7372
ID: 39286559
Hi Don,

I've configured a syslog server but still getting the repeated messages as feared... see attachment.

I'm beginning to wonder if its a Nexus feature that I need to turn off or on?

What do you think?

Cheers
repeats.png
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39286663
Please send me the entire log.
0
 

Author Comment

by:cpatte7372
ID: 39286902
Hi Don,

Attached is the entire log and the running config
17-32-55--MX-N7K1-AGG1-10.44.248.txt
17-33-14--MX-N7K1-AGG1-10.44.248.txt
0
 
LVL 50

Expert Comment

by:Don Johnston
ID: 39287051
Do you have Kiwi set to a small file size?
0
 

Author Closing Comment

by:cpatte7372
ID: 39333339
Cheers
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Destination host unreachable 12 92
Line cards, Supervisor, Control plane 7 33
Cisco switch suggestion 5 42
VLAN Question! 9 42
Quality of Service (QoS) options are nearly endless when it comes to networks today. This article is merely one example of how it can be handled in a hub-n-spoke design using a 3-tier configuration.
I recently attended Cisco Live! in Las Vegas, a conference that boasted over 28,000 techies in attendance, and a week of hands-on learning hosted by a solid partner with which Concerto goes to market.  Every year, Cisco displays cutting-edge technol…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…
After creating this article (http://www.experts-exchange.com/articles/23699/Setup-Mikrotik-routers-with-OSPF.html), I decided to make a video (no audio) to show you how to configure the routers and run some trace routes and pings between the 7 sites…

815 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

8 Experts available now in Live!

Get 1:1 Help Now