You are on page 1of 3

1 s cu lnh cu hnh c bn v cu hnh cc giao thc nh tuyn trn router.

+ Cc ch cu hnh: Router> (ch user mode) Router>enable (vo ch Privileged EXEC Mode) Router#configure terminal (vo ch Configuration Mode) + Cu hnh t tn v password cho router: Router(config)#hostname tn_mun_t (t tn cho router) Router(config)#enable password pass_mun t (cu hnh pass ko m ha) Router(config)#enable secret pass_mun_t (cu hnh pass c m ha bng MD5) + Cu hnh cc ng truy cp (console, aux v vty) - Cu hnh cng console: Router(config)#line console 0 Router(config-line)#password pass_cho_cng_console (c th khc pass ca router) Router(config-line)#login (bt buc phi c ch t pass cho cng console c hiu lc) - Cu hnh cng aux: Router(config)#line aux 0 Router(config-line)#password pass_cho_cng_aux (c th khc pass ca router) Router(config-line)#login (bt buc phi c ch t pass cho cng console c hiu lc) - Cu hnh cng vty (cng telnet) Router(config)#line vty 0 4 (ch cu hnh 5 ng telnet trong 1 thi im). Router(config-line)#password pass_cho_cng_vty (c th khc pass ca router) Router(config-line)#login (bt buc phi c ch t pass cho cng vty c hiu lc) + Cu lnh m ha tt c mt khu: Router(config)#service password-encryption + Cu hnh a ch ip cho interface: Router(config)#interface tn_cng (vo interface) Router(config-if)#no shutdown (cho php interface hot ng) Router(config-if)#clock rate 64000 (t thi gian ng b gia 2 router, ch dng vi ng serial) Router(config-if)#ip address a_ch_ip subnet_mask (t a ch ip cho interface) + Cu hnh static route: C 2 cch cu hnh Static Route, l cu hnh theo "next hop"address v exit interface. - Cu hnh theo "next hop" address: Router(config)#ip route a_ch_mng_mun_qung_b subnet_mask a_ch_ip_ca_interface_ni_vi_mng _mun_qung_b. - Cu hnh theo exit interface: Router(config)#ip route a_ch_mng_mun_qung_b subnet_mask interface_ni_vi_mng_mun_qung_b. + Cu hnh ng default route: Router(config)#ip route 0.0.0.0 0.0.0.0 [exit interface/ip address].

+ Cu hnh RIP: Router(config)#router rip (dng giao thc nh tuyn RIP) Router(config-router)#network a_ch_ip (a ch mng mun qung b bng giao thc RIP) Router(config-router)#passive-interface tn_cng (thng tin nh tuyn RIP ko c gi ra cng ny) Router(config-router)#version 2 (dng RIP version 2,mc nh l version 1) + Cu hnh EIGRP : 1.Cu hnh c bn. Router(config)#router eigrp eigrp_mun_t ( 1->65535) Router(config-router)#network IP_mng_mun_qung_b Router(config-router)#no auto-summary (ko t ghp cc di a ch IP thnh 1 di ln) - Thay i bng thng v t tng hp tuyn trong interface Router(config-if)#bandwidth kilobits Router(config-if)#ip summary-address protocol AS network number subnets mask - Cn bng ti trong EIGRP Router(config-router)#variance number - Qung b default route Cch 1: Router(config)#ip route 0.0.0.0 0.0.0.0 [interface/nexthop] Router(config)#redistribute static Cch 2: Router(config)#ip default-network network number Cch 3: Router(config-if)#ip summary-network eigrp AS number 0.0.0.0 0.0.0.0 - Qung b cc tuyn khc trong EIGRP (khng phi l default) Router(config-router)#redistribute giao_thc_mun_qung_b ID_metrics k1 k2 k3 k4 k5 V d: Router(config-router)#redistribute ospf metrics 100 100 100 100 100 - Chia s traffic trong EIGRP Router(config-router)#traffic share {balanced/min} - Cc lnh kim tra cu hnh EIGRP show ip eigrp neighbor show ip eigrp interface show ip eigrp topology show ip eigrp traffic debug eigrp fsm debug eigrp packet + OSPF: - Cu hnh c bn Router(config)#router ospf ospf_mun_chn ( 1->65535) Router(config-router)#network di_i_ch_mun_qung_b Wildcard_mask area_ID (thng l area 0)

- Cu hnh priority cc interface bu DR v BDR Priority cng ln th kh nng c bu lm DR cng cao, ngc vi bu Root brige ca Switch, cng nh th li cng c bu. Router(config)#interface fastethernet 0/0 Router(config-int)#ip ospf priority 55 Sau khi cu hnh xong priority c th kim tra bng lnh. Router# show ip ospf interface f0/0 - Chnh sa li OSPF cost metric trong mi interface Cost cng nh th tuyn cng c coi l best path Router(config-int)#ip ospf cost 1 - Cu hnh OSPF Authentication cc interface v p dng vo router Authentication key c hiu nh l password cc router trong cng mt vng chia s vi nhau. a. Cu hnh authentication n gin Router(config-if)#ip ospf authentication-key password Router(config-router)#area area number authentication b. Cu hnh authentication theo dng m ho, bo mt cao. Router(config-if)ip ospf message-digest-key key ID md5 encryption-type key Router(config-router)#area area ID authentication message-digest - Cu hnh OSPF timer trong cc interface Router(config-if)ip ospf hello-interval timer Router(config-if)ip ospf dead-interval timer - Cu hnh qung b mt tuyn mc nh trong OSPF Router(config-router)#default-information originate - Qung b mt tuyn khc (khng phi l default) Router(config-router)#redistribute protocols subnets - Cc lnh show dng kim tra cu hnh OSPF show ip protocol show ip route show ip ospf show ip ospf interface show ip ospf database show ip ospf neighbor detail clear ip route * debug ip ospf events debug ip ospf adj

You might also like