Date created: Thursday, December 13, 2012 9:40:19 AM. Last modified: Monday, September 2, 2019 7:51:31 AM

TCP/SSH/VTY Sessions

Show active TCP sessions. BGP and MPLS peerings, and Telnet:

ar01#show tcp brief 
TCB       Local Address       Foreign Address             (state)
327D5834  lo0.ar01.net.54277  lo0.pe01.net.646             ESTAB
3572702C  gi0-0.ar01et.20808  fa0-1.mai.179                ESTAB
37F96638  lo0.ar01.net.49363  lo0.thelon-pe02.vostr.179    ESTAB
3918E5C8  lo0.ar01.net.48167  lo0.thelon-pe01.vostr.646    ESTAB
2D29C68C  r01.lon0.13103      r02.lon.179                  ESTAB
32266D64  2A01:4:::1.52237    2A01:4::2.179                ESTAB
30E0C4D8  lo0.ar01.net.646    lo0.cr01.vostr.2192          ESTAB
34032124  lo0.ar01.net.23     fw01.net.50448               ESTAB
3654BF1C  lo0.ar01.net.23     fw01.net.20648               ESTAB

Show active user sessions. 1 SSH user and 1 PPPoA ADSL line up:

cpe>who
    Line       User       Host(s)              Idle       Location
*194 vty 0     bensley    idle                 00:00:00 fw01.net

  Interface    User               Mode         Idle     Peer Address
  Vi2                             PPPoATM      00:00:01 1.2.3.4

cpe#show user  
    Line       User       Host(s)              Idle       Location
*194 vty 0     bensley    idle                 00:00:00 fw01.net

  Interface    User               Mode         Idle     Peer Address
  Vi2                             PPPoATM      00:00:30 1.2.3.4

Disconnect VTY user:

castle-cpe#disconnect ssh 0
Connection to 1.2.3.5 closed by remote host.
Connection to 1.2.3.5 closed. 
r1#who 
    Line       User       Host(s)              Idle       Location
 194 vty 0     bensley    idle                 00:00:19 fw01.net
*195 vty 1     bensley    idle                 00:00:00 fw01.net

r1#clear line 194
[confirm]
 [OK]
r1#who           
    Line       User       Host(s)              Idle       Location
*195 vty 1     bensley    idle                 00:00:00 fw01.net

! ---OR-----

r1#who 
    Line       User       Host(s)              Idle       Location
 194 vty 0     bensley    idle                 00:00:19 fw01.net
*195 vty 1     bensley    idle                 00:00:00 fw01.net

r1#clear line vty 0
[confirm]
 [OK]
r1#who           
    Line       User       Host(s)              Idle       Location
*195 vty 1     bensley    idle                 00:00:00 fw01.net