Thursday, October 22, 2009

CCNA2 Cisco command

Router#erase startup-config
Router#reload
Router#debug ip routing
Router#debug ip rip
Router#undebug all

Router(config)# hostname R1
Router(config)# enable secret 1234password
Router(config)# banner motd &

************
!! Authorised ACCESS ONLY!
************
&

R1(config)#line console 0
R1(config-line)#login
R1(config-line)#password 123
R1(config-line)#logging synchronous
R1(config-line)#exec-timeout 0 0

R1(config)#line vty 4 0
R1(config-line)#login
R1(config-line)#password 123
R1(config-line)#logging synchronous
R1(config-line)#exec-timeout 0 0

//Disable domain lookup
R1(config)#no ip domain-lookup

//Clock rate set at DCE
Router(config)#interface serial 1/1
Router(config-if)#ip address 192.168.1.1 255.255.255.0
Router(config-if)#no ip address 192.168.1.1 255.255.255.0
Router(config-if)# clock rate 64000
Router(config-if)#no shutdown


//Static route need to set for both router
Router(config)#ip route 172.16.0.0 255.255.255.0 192.168.1.1

//Default route
Router(config)# ip route 0.0.0.0 0.0.0.0 Next_Hop_Add
Router(config)# ip route 192.3.5.5 255.255.255.255 serial 1/1
Router#show interface serial 1/1

//RIP
Router(config)#router rip
Router(config-router)#network 192.168.1.1
Router(config-router)#network 172.12.1.1

//prevent the updates send to FE 0/0,save bandwidth
Router(config-router)#passive-interface fastethernet 0/0

//configure the router to include the static route with it RIP updates
Router(config-router)#default-information originate
Router(config-router)#ctrl-Z
Router #show ip protocols

Router#show running-config
Router#copy running-config startup-config
Router#show startup-config

//Trobleshoot
Router# show interface
Router#show ip protocols
Router#show ip route
Router#show ip interfaces brief

//CDP
Router(config)#cdp run
Router(config)#int ethernet 0/1
Router(config-if)#cdp enable
Router(config-if)#no cdp enable
Router(config)#no cdp run

//OSPF
R1(config)#router ospf 1
R1(config-router)#

Router(config-router)#network network-address wildcard-mask area area-id
Router(config-router)#network 172.16.1.16 0.0.0.15 area 0

Router(config-router)#router-id ip-address
Router#clear ip ospf process // modify router id detection OR reload the router

Router(config)#interfaceloopback number
Router(config-if)#ip address ip-address subnet-mask

Router(config)#interface loopback 0
Router(config-if)#ip address 10.1.1.1 255.255.255.255

///////////////////\\\\\\\\\\\\\\\\\

Router(config-if)#bandwidth bandwidth-kbps
Router(config-if)#bandwidth 56

or

Router(config-if)#ip ospf cost 1562 //bypass the calcultion but input the direct value

////////////////\\\\\\\\\\\\\\\\\\\

Router(config-if)#ip ospf priority {0 - 255} //to set the DR or BDR

Router(config-if)#ip ospf hello-interval seconds
Router(config-if)#ip ospf dead-interval seconds

R1(config)#ip route 0.0.0.0 0.0.0.0 loopback 1 //default route

R1(config-router)#auto-cost reference-bandwidth ? //1-4294967 The reference bandwidth in terms of Mbits per second

R1(config-router)#auto-cost reference-bandwidth 10000

R1#show ip protocols
R1#show ip ospf neighbor
R1#show ip ospf
R1#show ip ospf interface serial /0/0/0

No comments:

Post a Comment