[Okta Webinar] Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 10146
  • Last Modified:

How to disconnect idle user on vty line?

After running the 'show users' command in the Cisco IOS, it appears on one of our Cisco 3560 switches, I have a user who has been idle on 'vty 0' for many weeks (we don't reload the switches often).  What command can I run to disconnect them? I am currently logged in over telnet to vty1 - they are connected to vty 0
0
davis
Asked:
davis
  • 3
  • 3
  • 2
2 Solutions
 
luc_royCommented:
disconnect [session number]
0
 
rfc1180Commented:
try:

clear line 0
0
 
luc_royCommented:
sorry that is for suspended session

clear line vty [#]

will kick the user out.
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
davisAuthor Commented:
luc roy - What do you mean by suspended session?  I am not sure if I have a 'suspended' or 'idle' session?  
0
 
luc_royCommented:
clear line vty [#]
 will do it without haveing to first suspend it
0
 
rfc1180Commented:
as I stated in the begging:

edge01.lax01#show user
*Aug 21 16:22:18.959: %SYS-5-CONFIG_I: Configured from console by console
    Line       User       Host(s)              Idle       Location
*  0 con 0                idle                 00:00:00  
   2 vty 0                idle                 00:00:04 192.168.1.30

  Interface    User               Mode         Idle     Peer Address

edge01.lax01#clear line 2
[confirm]
 [OK]
edge01.lax01#show user
    Line       User       Host(s)              Idle       Location
*  0 con 0                idle                 00:00:00  

  Interface    User               Mode         Idle     Peer Address
0
 
davisAuthor Commented:
worked perfectly - thanks!
0
 
rfc1180Commented:
just to add, luc roy provides a better solution as the VTY is the correct method for telnet/ssh sessions. I have just always used clear line # as it has always worked in the past. clear line # may not work on all versions, as it honestly applies to async lines.

Billy
0

Featured Post

Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

  • 3
  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now