Switchport Monitoring

Answered Question
Aug 25th, 2009

All,

Is there a way to see the last time a switchport was active/connected? I have a 48 port switch with all ports connected to the patch panel but only about 20 ports are active. I would like to see when the last time a port was active so I know if it is safe to use the port for another purpose. Not sure if there are any logs to view to see this. Thanks for any help.

Ken

I have this problem too.
0 votes
Correct Answer by John Blakley about 7 years 4 months ago

There are a couple of ways that I know of:

sh int g0/1 summary

sh int g0/1 | inc 5 minute|Last input

The last one will show you when the last frame was received on the port:

Last input never, output 00:00:01, output hang never

5 minute input rate 615000 bits/sec, 53 packets/sec

5 minute output rate 79000 bits/sec, 94 packets/sec

HTH,

John

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Loading.
Correct Answer
John Blakley Tue, 08/25/2009 - 09:19

There are a couple of ways that I know of:

sh int g0/1 summary

sh int g0/1 | inc 5 minute|Last input

The last one will show you when the last frame was received on the port:

Last input never, output 00:00:01, output hang never

5 minute input rate 615000 bits/sec, 53 packets/sec

5 minute output rate 79000 bits/sec, 94 packets/sec

HTH,

John

tohoken Tue, 08/25/2009 - 09:24

Thanks John. This is what I needed. Do you know if you can view a range of interfaces this way?

John Blakley Tue, 08/25/2009 - 09:28

Hmm, only way that I know how would be to show all interfaces and then filter the same results but include interface names like:

sh int | inc 5 minute|Last input|line protocol

That should show you all interfaces, but as far as using a range, I don't think it can be done with a show command like "show int range etc."

HTH,

John

iyde Sat, 09/05/2009 - 08:10

Be aware, though, that in some switches a bug (in hardware, as far as I know)makes this unuable, because the show command always says last input never, even though you can see a lot of data passing through.

So in other words, it's unfortunately not always a help for you do do like that.

Another safer way to do it is to clear the counters and then look again at a later time to see if they have incremented or still are at zero.

HTH

Leo Laohoo Sun, 09/06/2009 - 14:47

If you have a 4500-based chassis or 4900 switch, you can use the sh interface link:

Gi1/13 13 weeks, 23 hours, 41 minutes 42 secs 23:03:52 Sat Jun 6 2009

Hope this helps.

Actions

This Discussion