Cisco路由器配置入門知識大全

路由器是計算機網絡技術中重要的.組成設備,小編剛剛接觸cisco路由配置,下面是小編學習的筆記分享給大家,感覺命令還是多敲才能熟悉,希望對你有幫助

Cisco路由器配置入門知識大全

  一、 所處狀態各類

router>

用戶處於用戶命令狀態,可以查看網絡和主機

router#

用戶處於特權模式,可以查看狀態,還可以看到和更改路由器的設置內容

router(config)#

全局配置狀態,可以設置路由的全局參數

router(config-if)#;router(config-line)#;router(config-router)#.....

處於局部配置狀態,可以設置路由的局部參數

  二、配置端口ip

命令

en

config t //全局模式

interface f0/0

ip address //設置端口ip

no shu //生效

exit

interface f0/1

ip address

no shu

exit

end

disable

  三、配置靜態路由

命令

en

config t //全局模式

ip route //到通過接口

end

show ip route //可以看到前面標明S,即爲靜態路由

  四、配置動態路由(RIP)

命令

en

config t //全局模式

no route rip //禁止rip協議

route rip

network //network參數爲路由的兩個端口對應的網絡地址

network

exit

end

disable

  五、配置DHCP

命令

en

config t //全局模式

ip dhcp excluded-address //需要排除的ip地址

ip dhcp pool gr-dhcp-pool //ip地址池名

default-server //指定dhcp服務器

network //配置網絡

dns-server //配置dns服務器

exit

end

disable

可以通過 ip helper-address指定 DHCP中繼代理

interface FastEthernet0/1

ip address

ip helper-address 配置DHCP中繼代理,DHCP

  六、配置NAT

命令

en

config t //全局模式

interface f0/0

ip address

ip nat inside //內部端口

no shu

exit

interface f0/1

ip address

ip nat outside //外部端口

no shu

exit

access-list 1 permit any //設置一個可訪問列表

ip nat pool gr-nat-pool netmask //設置分配池

ip nat inside resource list 1 pool gr-nat-pool overload

show ip nat traslations

clear ip nat traslation *