Learn Cisco CLI – Part 5 – Remote Access via Telnet

Table of Contents
Learn Cisco CLI - Part 5

Remote Access via Telnet

These blog posts I created to help me as a reference tool, as well as a way of retaining the knowledge. If you find it useful that’s just a plus.

Telnet is a protocol that allows you to connect to remote devices over a network using a command-line interface. It operates on port 23 and provides an unencrypted communication method, which means that data, including passwords, is sent in plain text. Because of this, Telnet is often used in lab environments or situations where security is not a concern.

Configuration Commands

Line VTY 0 4

Enters configuration mode for virtual terminal (VTY) lines. VTY lines are used for Telnet sessions.

				
					Syntax:
line vty 0 4
				
			

Example:

				
					Router1>enable
Router1#configure terminal
Router1(config)#line vty 0 4
Router1(config-line)#
				
			
Password

Specifies the password required to log in via Telnet.

				
					Syntax:
password <password>
				
			

Example:

				
					Router1>enable
Router1#configure terminal
Router1(config)#line vty 0 4
Router1(config-line)#password p4ssw0rd!
				
			

Login

Enables password checking at login for Telnet sessions.

				
					Syntax:
login
				
			

Example:

				
					Router1>enable
Router1#configure terminal
Router1(config)#line vty 0 4
Router1(config-line)#login
				
			

IP Address

Assigns an IP address to an interface, necessary for enabling remote access.

				
					Syntax:
ip address <ip-address> <subnet-mask>
				
			

Example:

				
					Router1>enable
Router1#show cdp
Router1(config)#interface GigabitEthernet 0/1 
Router1(config-if)#ip address 192.168.1.1 255.255.255.0
				
			

No Shutdown

Enables an interface that was previously shut down, making it active.

				
					Syntax:
no shutdown
				
			

Example:

				
					Router1>enable
Router1#show cdp
Router1(config)#interface GigabitEthernet 0/1 
Router1(config-if)#no shutdown
				
			

Telnet Access Commands

Telnet

Starts the terminal emulation program from a PC, router, or switch, allowing you to access devices remotely over the network.

				
					Syntax:
telnet [ip-address]
				
			

Example:

				
					Router1>enable
Router1#telnet 192.168.1.1
				
			

Show Sessions

Displays information about active LAT, Telnet, or rlogin connections.

				
					Syntax:
show sessions
				
			

Example:

				
					Router1>enable
Router1#show sessions
				
			

Disconnect

Closes an active console port or Telnet session.

				
					Syntax:
disconnect [session-number]
				
			

Example:

				
					Router1>enable
Router1#disconnect 1 
				
			

Resume

Switches to an open local-area transport (LAT), Telnet, rlogin, or PAD session.

				
					Syntax:
resume [connection]
				
			

Example:

				
					Router1>enable
Router1#resume 1 
				
			

Show Running-Config

Displays the active configuration file, allowing you to verify Telnet settings and other configurations.

				
					Syntax:
show running-config
				
			

Example:

				
					Router1>enable
Router1#show running-config
				
			

Leave a Comment