Home Cisco Basic configuration of Cisco IOS for routers and switches
Basic configuration of Cisco IOS for routers and switches

Basic configuration of Cisco IOS for routers and switches

0
0

In this page we will discuss some important and basic terminology and configuration of Cisco switches and routers

  • CLI: Command Line Interface that is used to configure Cisco routers and Switches
  • IOS: Internetwork Operating System is the name of the operating system that is installed on the Cisco devices.

Different ways to connect to a router:

  • Telnet/SSH
  • Dialup connection through a modem attached to the auxiliary port (Straight cable is required)
  • Console connection: Console Cable (Rollover cable) is an eight-wire cable that the wires are connected in an special order (pinouts of one end, are reserved on the other, as if the wire is rolled over and you are viewing it from the other side)

 

Access modes to a router/Switch:

  • User exec mode: basic show commands are enabled in this mode and prevents the users from changing any configuration.

Router1>  ( the “>” sign shows that you are in user mode)

  • Privileged mode: All commands are available in this mode and administrators can configure the router.

Router1#    (the “# shows that you are in privileged mode)

  • Configuration Terminal mode is a sub-mode of privileged mode that enables the interface for most of the configurations to happen. Interface configurations, routing settings and many more.

 

How to switch between user and privileged mode:

  • Router1>enable

Router1#

 

  • Router1#disable

Router1>

 

Change hostname of a router:

Router1>enable

Router1#configure terminal

Enter configuration commands, one per line.  End with CNTL/Z.

Router1(config)#Hostname ITPerfection-Router

ITPerfection-Router(config)#

 

Set a password for the console port:

 

ITPerfection-Router>enable

ITPerfection-Router#configure terminal

Enter configuration commands, one per line.  End with CNTL/Z.

ITPerfection-Router(config)#line console 0

Hudhaya-Router(config-line)#login

% Login disabled on line 0, until ‘password’ is set

Hudhaya-Router(config-line)#password Hudhaya.com

 

Return back one level:

ITPerfection-Router(config-line)#exit

ITPerfection-Router(config)#exit

 

# terminal monitor 

Shows the console messages while connecting to the router.

 

#logging synchronous 

Prevents annoying console messages from interrupting you during typing a command

Example:

Config# line console 0

Config-line# logging synchronous

 

Some important Show commands:

#show ip interface brief 

Displays brief information about the interfaces, IP-address and the status of all interfaces on a Cisco switch or router

#show history  (Displays the last entered commands by the user)

 

“LINE” command:

Virtual terminal lines are the telnet/ssh logical lines that allow administrators to configure the switches and routers

#line vty

#n line vty (negates the restriction that was implemented in the previous command)

#session-limit 5 (Configures the maximum number of terminal sessions)

#no session-limit (negates the restriction that was implemented in the previous command)

#show line (Displays all connected console and vty sessions)

#Clear line vty3 (disconnects the connected VTY session)

 

 

ceo