Monday, March 14, 2011

7 Steps to Router Heaven

1. Name your router:
router> enable // (ena) enable the router
router# configure terminal // (config t) go into configuration mode
router(config)# hostname B1 // assign hostname to router
B1(config)# no hostname // remove hostname from router

2. Enable passwords:
// Enable password for Console 0
B1(config-line)# line con 0 // tell it you're configuring console 0
B1(config-line)# password cisco // assign the password to console 0
B1(config-line)# login // set password
B1(config-line)# no logging synchronous // (no logging sync) Do not log error messages

// Enable password for Telnet (sessions 0 through 5)
B1(config-line)# line vty 0 5 // 0 5 == virtual terminals 0 through 5
B1(config-line)# password cisco // assign password to vty 0-5
B1(config-line)# login // set password
B1(config-line)# exit // get out of password set

B1(config)# enable password cisco // enables normal login password
B1(config)# enable secret cisco // enables encrypted password (never other passwords!)

3. Configure Network Interfaces
B1(config)# interface s0/0 // (int s0/0) configure interface serial fa0/0
B1(config-if)# ip address // (ip add) give IP address
B1(config-if)# no shutdown // (no shut) turn on the interface
B1(config-if)# clock rate 500000 // set clock rate for DCE interface

4. Description of Interfaces
B1(config-if)# description fa0/0 Lan Building 1 Connection   // describe interface fa0/0
B1(config-if)# exit // exit the config-if and back to config

5. Message of the Day
B1(config)# banner motd #Unlawful Use of this Router will get you TERMINATED!!!!!# // warns you that you're trying to login

B1(config)# banner login #You are logged into this router now!#  // tells you that you're logged in

6. Turn on/off services/daemons
B1(config)# no ip domain-lookup // turn off domain lookup service (DNS)
B1(config)# ip host B1  // add routes to the host table
B1(config)# exit

7. Test the router from another router!!!
B2# ping B1 // ping the router
B2# telnet // telnet into the router

Other useful tips:
B1# ? // gives you list of available commands
B1# banner ? // gives you list of commands to use with banner

No comments: