Make your own free website on Tripod.com
BACK

Router Connectivity Tools

TELNET

Telnet is a virtual terminal protocol that is part of the TCP/IP protocol suite.  Telnet allows you to make connections to remote devices, gather information, and run programs.  After your routers and switches are configured, you can use Telnet to configure and check your routers and switches remotely.  You can run telnet by typing telnet along with the IP address from the command line or just the IP address (an attempt will be made to open a telnet connection to the IP address).  Before you can login via telnet you will have to enable logins and set the VTY password.  Telnet allows a user at one site to establish a TCP connection to a login server at another site, and then passes the keystrokes from one system to the other. Telnet can accept either an IP address or a fully qualified domain name as the remote system address.  Telnet tests connectivity up to the application layer of the OSI model.
In short, Telnet offers three main services:

  • Network virtual terminal connection
  • Option negotiation
  • Symmetric connection
The Cisco Systems implementation of Telnet supports the following Telnet options:
  • Remote echo
  • Binary transmission
  • Suppress go ahead
  • Timing mark
  • Terminal type
  • Send location
  • Terminal speed
  • Remote flow control
  • X display location

Telnet to devices

Below is an example telnet session, I telneted from the router to a Linux server. {Never telnet and login as the root user, telnet sends passwords in plain text.  If you must login remotely to a server as root, use Secure Shell SSH instead}.

   Router_2>192.168.1.70
   Trying 192.168.1.70 ... Open

   Welcome to SuSE Linux (i386) - Kernel 2.4.5 (pts/0).
   
   suse login: lxuser
   Password:
   lxuser@suse~ > 

Below is an example telnet session, I telneted into another router.

   Router_2>192.168.1.1
   Trying 192.168.1.1 ... Open

   User Access Verification

   Password:
   Router3>

You can telnet into multiple devices simultaneously, telnet into the first device then switch back to the original device by pressing the following keys: [Ctrl]+[Shift]+6, let go and then press X.

Checking Telnet Users

You can list all active consoles and VTY ports in use with the show users command.  The asterisk denotes who entered the command.  Host(s) shows outgoing connections.  Idle is the time in minutes since a user has typed something.  Location is either the hardwired location for the line or, if there is an incoming connection, the host the incoming connection is from.

Router3#show users
        Line            User          Host(s)        Idle Location
        0 con 0                         idle
*       2 vty 0         mb              idle            0 SUSE.BELL.NET

Checking Telnet Sessions

To see the connections made from your router to a remote host, use the show sessions command.  The asterisk denotes the console was the last session used.  Host shows the remote connection to which the router is connected through a Telnet session.  Address is the address of the remote host.  Byte is the number of unread bytes that are waiting for the user to see on the connection.  Idle is the interval (in minutes) since data was last sent on the line.  Conn Name is the Assigned name of the connection.

   Router3#show sessions
   Conn Host           Address       Byte  Idle Conn Name
      1 192.168.1.1    192.168.1.1    0     0   192.168.1.1
   *  2 192.168.1.2    192.168.1.2    0     0   192.168.1.2

Ending Telnet Sessions

There are a couple of different ways to end telnet sessions.  They are the exit or
disconnect [session number, session name] commands.

You can disconnect users with the clear line [number] command, you can see the users with the show users command.

TRACE

Trace can be used to show the path a packet takes through the internetwork to a remote host.  Trace is similar to the windoze tracert command or the UNIX traceroute command.

PING

You can use ping to test network connectivity and test name resolution.

   Router_2#ping ?

     WORD       Ping destination address or hostname
     apollo     Apollo echo
     appletalk  Appletalk echo
     clns       CLNS echo
     decnet     DECnet echo
     ip         IP echo
     ipx        Novell/IPX echo
     vines      Vines echo
     xns        XNS echo
     <cr>

An example ping session.

   Router_2>en
   Router_2#ping 192.168.1.70

   Type escape sequence to abort.
   Sending 5, 100-byte ICMP Echos to 192.168.1.70, timeout is 2 seconds:
   !!!!!
   Success rate is 100 percent (5/5), round-trip min/avg/max = 4/4/4 ms

Name Resolution

In order to use hostnames instead of IP address to connect to remote devices, you need a method to resolve names.  One method is to use a host table and another is to use a DNS (Domain Name System) Server.

Host Table

The syntax for building a host table is: ip host [name] [tcp port #] [IP_address].  The command is used in global configuration mode (conf t) and you can assign up to eight IP address to a hostname.  To see the host table use the command show hosts.

DNS Server

If you have many devices and don't want to create a host table at each device, you can use a central DNS server to resolve hostnames.  DNS lookups are enabled by default and can be disabled with the following command in global configuration mode no ip domain-lookup.  To specify the DNS server to use, use the command
ip name-server [ip_address] in global configuration mode.  The last command you should use to enable DNS resolution of hostnames is to specify the domain you are in with the command ip domain-name [domain] since DNS server resolve FQDN (Fully Qualified Domain Names).
Here is how to set up a DNS server in Linux (BIND 8)
Here is how to set it up in NT 4.0.

   Router_2>en
   Router_2#conf t 
   Enter configuration commands, one per line.  End with CNTL/Z.
   Router_2(config)#ip domain-lookup
   Router_2(config)#ip name-server 192.168.1.70
   Router_2(config)#ip domain-name bell.net
   Router_2(config)#^Z

After entering the domain information, you can telnet and ping using the hostnames.  Every hostname will be cached for faster access next time.

BACK