Friday, 6 January 2012

Configuring The IOS

Using Lines to Configure The IOS: 

Lines identify ports that allow us to connect into, and then configure, Cisco devices. There are three methods (or lines) to configure cisco IOS devices.

1. Console ports: Nearly, every modern Cisco router or switch includes a console port, sometimes labeled on the device simply as con. The console port is generally a RJ-45 connector, and requires a rollover cable to connect to. The opposite side of the rollover cable connects to a PC's serial port using a serial terminal adapter.
             From the PC, software such as HyperTerminal is required to make a connection from the local serial port to the router console port. The following settings are necessary for a successful connection:
  • Bits per second - 9600
  • Data bits - 8
  • Parity -  None
  • Stop bits - 1
  • Flow Control - Hardware
2. Auxiliary port:  The auxiliary port can function similarly to a console port, and can be accessed using a rollover cable. Additionally, auxiliary ports support modem commands, thus providing dial-in access to Cisco Devices.


3. Telnet (VTY) ports:  Telnet, and now SSH, are the most common methods of remote access to routers and switches. The standard edition of the IOS supports up to 5 simultaneous VTY connections. Enterprise editions of the IOS supports up to 255 VTY connections.
                These are two requirements before a router/switch will accept a VTY connection:
a) An IP address must be configured on an interface.
b) Atleast one VTY port must be configured with a password.

Cisco IOS

The Cisco IOS is a command-line interface used by nearly all current Cisco routers and Catalyst switches. The IOS provides the mechanism to configure all layer 2 and layer 3 functions on Cisco devices.
                          The IOS is structured into several modes, which contain sets of commands specific to the function of that mode. Access to a specific mode (and specific commands) is governed by privilege mode.

The following is a representation of the IOS command-line interface, with an example command:

                       Router#show startup-config

Router--------------------> Hostname
# -------------------------> Mode
show ---------------------> Command
startup-config -------------> Argument

Hitting the "enter" key after a command will usually yield output specific to your command.

IOS version Numbers:
  IOS version numbers are formatted as follows:
                                  x.y(z)t
  • "x" designates a major revision number.
  • "y" designates a minor revision number.
  • "z" designates an individual release number.
  •  "t" designates a train identifier
Train Identifiers:
  • "T" or technology train is continously updated with new features and security fixes.
  • "E" or Enterprise train features and a command-set for specific equipment.
  • "S" or Service Provider train contains features and a command-set for specific ISP equipments.
The absence of a train identifier denotes a Mainline release. Security updates are releases for the mainline train, but new functionality is never added to the feature set.
The latest version of the IOS (as of this writing) is 24.4(11)T. To view the IOS version of your Cisco device:
           Router#show version

NOTE:
To practice configuring routers and switches, please download and install any network simulation program. i would recommend Cisco Packet Tracer.



Router Components

Processor: Cisco router has a CPU that execute the IOS (Inter-networking Operating System) commands.
for examples:
700 Series Intel 80386SL
800 Series Motorola PowerQUICC 8xx PowerPC core
1000 Series Motorola Dragonball
1600 Series Motorola Dragonball
2500 Series Motorola 680EC30
3100 Series Motorola 680EX30

ROM Monitor: It is used for manufacturing, testing and troubleshooting. It is a non-volatile memory. It stores bootstrap program.
                    Bootstrap program loads the IOS image for the router with the help of configuration register, this configuration register is a file that decide the boot mode for the IOS image, the register value is a set of 4 hexadecimal digit, the last hexadecimal digit decide the boot up process. The value for the image are:
  • 0*0  - boots the router into ROM monitor mode.
  • 0*1 - boots the router using the mini-IOS.
  • 0*2 - boots the router using the default boot sequence.
 RAM: It holds packet buffer, ARP cache, routing table, software and data structure that allows the router to function. It stores running-config of the router and it also stores decompressed IOS in later router models.

Flash Memory: It is an Electronically Erasable and Re-Programmable memory chip. The Flash memory contains the full Operating System Image (IOS, Internetwork Operating System). This allows you to upgrade the OS without removing chips. Flash memory retains content when router is powered down or restarted.

NVRAM: NVRAM (Non-volatile Random Access Memory) is used to store the startup configuration. This is the configuration file that IOS reads when the router boots up. It is extremely fast memory and retains its content when the router is restarted.

Mini-IOS: The mini-IOS is not present in every router. The mini-IOS components provides an alternative file for the router boot up. It can also perform a few other maintenance operations.

Router Boot Sequence
1. Router is powered on.

2. The bootstrap program (ROMmon) is loaded from ROM.

3. The bootstrap runs POST. 
               POST (Power On Self Test) checks for the basic functionality of router hardware and determines which interface are present or not. The POST is a series of 14 tests that runs in the reverse numerical order.

4. The bootstrap attempts to load the IOS from Flash.
          a) If the IOS is not found in the Flash, the bootstrap loads into RAM the basic IOS stored in ROM
          b) If the IOS is found in Flash, it is loaded into RAM.

5. The IOS attempts to load the startup-config file from NVRAM
          a) If the startup-config is not found in NVRAM, the IOS attempts to load a configuration file from TFTP.
          b) If no TFTP server responds, the router enters Initial Configuration Mode.
          c) If startup-config is found in NVRAM, it is loaded into RAM.

6. The startup-config becomes the running-config in RAM.