国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 學(xué)院 > 網(wǎng)絡(luò)通信 > 正文

OSPF詳細(xì)配置

2019-11-04 11:16:56
字體:
供稿:網(wǎng)友
OSPF具體配置
啟用OSPF動(dòng)態(tài)路由協(xié)議
router ospf 進(jìn)程號(hào)

進(jìn)程號(hào)可以隨意設(shè)置,只標(biāo)識(shí)ospf為本路由器內(nèi)的一個(gè)進(jìn)程

定義參與ospf的子網(wǎng).該子網(wǎng)屬于哪一個(gè)OSPF路由信息交換區(qū)域。
network ip 子網(wǎng)號(hào) 通配符 area 區(qū)域號(hào)

路由器將限制只能在相同區(qū)域內(nèi)交換子網(wǎng)信息,不同區(qū)域間不交換路由信息。另外,區(qū)域0為主干OSPF區(qū)域。不同區(qū)域交換路由信息必須經(jīng)過區(qū)域0。一般地,某一區(qū)域要接入OSPF0路由區(qū)域,該區(qū)域必須至少有一臺(tái)路由器為區(qū)域邊緣路由器,即它既參與本區(qū)域路由又參與區(qū)域0路由。

OSPF區(qū)域間的路由信息總結(jié)
假如區(qū)域中的子網(wǎng)是連續(xù)的,則區(qū)域邊緣路由器向外傳播給路由信息時(shí),采用路由總結(jié)功能后,路由器就會(huì)將所有這些連續(xù)的子網(wǎng)總結(jié)為一條路由傳播給其它區(qū)域,則在其它區(qū)域內(nèi)的路由器看到這個(gè)區(qū)域的路由就只有一條。這樣可以節(jié)省路由時(shí)所需網(wǎng)絡(luò)帶寬。

設(shè)置對(duì)某一特定范圍的子網(wǎng)進(jìn)行總結(jié):area 區(qū)域號(hào) range 子網(wǎng)范圍掩碼

指明網(wǎng)絡(luò)類型 在需要進(jìn)行OSPF路由信息的端口中,設(shè)置:
ip ospf network broadcast或non-broadcast或point-to -mutlipoint

一般地,對(duì)于 DDN,幀中繼和X.25屬于非廣播型的網(wǎng)絡(luò),即non-broadcast

對(duì)于非廣播型的網(wǎng)絡(luò)連接,需指明路由器的相鄰路由器
neighbor 相鄰路由器的相鄰端口的IP地址

通過以上配置,路由器之間就可以完成交換路由信息了,其它設(shè)置,為了防止路由信息被竊取,可以對(duì)OSPF進(jìn)行安全設(shè)置,只有合法的同一區(qū)域的路由器之間才能交換路由信息。

設(shè)置步驟

設(shè)置某區(qū)域使用安全設(shè)置md5方式
area 區(qū)域標(biāo)號(hào) autherfication message-digest

可以采用明文方式 ,但建議采用MD5方式,較安全。

設(shè)置某端口驗(yàn)證其相鄰路由器相鄰端口時(shí)的MD5口令,在端口設(shè)置模式下
ip ospf message-digest-key 口令標(biāo)號(hào) MD5 口令字符串

其中,在同一區(qū)域的相鄰路由器的相鄰端口的口令標(biāo)號(hào)及口令字符串必須相同,同一路由器的不同端口的MD5口令可以不同,也可以某些端口使用安全設(shè)置,某些端口不使用安全設(shè)置。

 
實(shí)例1 無安全,無路由總結(jié)的OSPF設(shè)置

2511-1的設(shè)置

Current configuration:



version 11.3

no service passWord-encryption

!

hostname 2511-1

!

enable password cisco

!

interface Ethernet0

ip address 192.4.1.1 255.255.255.0

!

interface Serial0

ip address 192.3.1.1 255.255.255.0

encapsulation frame-relay IETF

no ip mroute-cache

bandwidth 2000

frame-relay map ip 192.3.1.2 100 broadcast

frame-relay lmi-type cisco

!

interface Serial1

ip address 192.1.1.1 255.255.255.0

encapsulation ppp

bandwidth 64

!

router ospf 1

passive-interface Ethernet0

network 192.1.1.0 0.0.0.255 area 0

network 192.3.1.0 0.0.0.255 area 0

network 192.4.1.0 0.0.0.255 area 0

neighbor 192.1.1.2 PRiority 1

neighbor 192.3.1.2 priority 1

!

ip classless

!

line con 0

line 1 8

line aux 0

line vty 0 4

!

end

2505的設(shè)置

Current configuration:

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname 2505

!

enable secret 5 $1$GbYT$OR05giiLZxI4hEAO0F8kV1

!

hub ether 0 1

link-test

auto-polarity

!

hub ether 0 2

link-test

auto-polarity

!

hub ether 0 3

link-test

auto-polarity

!

hub ether 0 4

link-test

auto-polarity

!

hub ether 0 5

link-test

auto-polarity

!

hub ether 0 6

link-test

auto-polarity

!

hub ether 0 7

link-test

auto-polarity

!

hub ether 0 8

link-test

auto-polarity

!

interface Ethernet0

ip address 192.1.4.1 255.255.255.0

!

interface Serial0

ip address 192.1.2.1 255.255.255.0

ip ospf network non-broadcast

bandwidth 2000

clockrate 2000000

!

interface Serial1

ip address 192.1.1.2 255.255.255.0

enpsuration ppp

ip ospf network non-broadcast

bandwidth 64

clockrate 64000

!

router ospf 1

passive-interface Ethernet0

network 192.1.1.0 0.0.0.255 area 0

network 192.1.2.0 0.0.0.255 area 2

network 192.1.4.0 0.0.0.255 area 2

neighbor 192.1.1.1 priority 1

neighbor 192.1.2.2 priority 1

!

no ip classless

ip ospf name-lookup

!

line con 0

line aux 0

line vty 0 4

login

!

end

internal -2的設(shè)置

Current configuration :

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname internal-2

!

enable secret 5 $1$KX00$rTI/2TvDokWxT4xC6wvmi/

!

interface Ethernet0

no ip address

shutdown

!

interface Serial0

ip address 192.1.2.2 255.255.255.0

ip ospf network non-broadcast

!

interface Serial1

no ip address

shutdown

!

router ospf 1

network 192.1.2.0 0.0.0.255 area 2

neighbor 192.1.2.1 priority 1

!

no ip classless

!

line con 0

line 1 16

line aux 0

line vty 0 4

!

end

 

2514的設(shè)置

Current configuration :

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname 2514

!

enable secret 5 $1$uoHU$Vks/lY CRi33z4TXs4qekI0

!

frame-relay switching

!

interface Ethernet0

ip address 192.5.1.1 255.255.255.0

!

interface Ethernet1

no ip address

shutdown

!

interface Serial0

ip address 192.3.1.2 255.255.255.0

encapsulation frame-relay IETF

bandwidth 2000

clockrate 2000000

frame-relay map ip 192.3.1.1 100 broadcast

frame-relay intf-type dce

!

interface Serial1

ip address 192.2.1.1 255.255.255.0

no ip mroute-cache

encapsulation X25 dce

bandwidth 64

x25 address 1234

x25 htc 16

x25 nvc 4

x25 map ip 192.2.1.2 5678 broadcast

clockrate 64000

!

router ospf 1

passive-interface Ethernet0

network 192.3.1.0 0.0.0.255 area 0

network 192.2.1.0 0.0.0.255 area 0

network 192.5.1.0 0.0.0.255 area 0

neighbor 192.2.1.2 priority 1

neighbor 192.3.1.1 priority 1

!

no ip classless

!

line con 0

line aux 0

line vty 0 4

login

!

end

 

2511-2的設(shè)置

Building configuration ...

Current configuration:

!

version 11.3

no service password-encryption

!

hostname 2511-2

!

enable secret 5 $1$7o5F$MSyFWzVf6JBgnjLJghHSB.

!

interface Ethernet0

ip address 192.2.4.1 255.255.255.0

!

interface Serial0

ip address 192.2.1.2 255.255.255.0

encapsulation x25

no ip mroute-cache

x25 address 5678

x25 htc 16

x25 nvc 4

x25 map ip 192.2.1.1 1234 broadcast

!

interface Serial1

ip address 192.2.2.1 255.255.255.0

ip ospf network non-broadcast

no ip mroute-cache

bandwidth 2000

clockrate 2000000

!

router ospf 1

passive-interface Ethernet0

network 192.2.2.0 0.0.0.255 area 1

network 192.2.4.0 0.0.0.255 area 1

network 192.2.1.0 0.0.0.255 area 0

neighbor 192.2.1.1 piority 1

neighbor 192.2.2.2 piority 1

!

ip classless

!

line con 0

line 1 8

line aux 0

line vty 0 4

!

end

internal -1的設(shè)置

Building configuration...

Current configuration:

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname internal-1

!

enable secret 5 $1$cF2M$z2T8Ohij5q/yn2RsiVaGE/

!

interface Ethernet0

no ip address

shutdown

!

interface Serial0

ip address 192.2.2.2 255.255.255.0

ip ospf network non-broadcast

!

interface Serial1

no ip address

shutdown

!

router ospf 10

network 192.2.2.0 0.0.0.255 area 1

neighbor 192.2.2.1 priority 1

!

no ip classless

!

line con 0

line 1 16

line aux 0

line vty 0 4

login

!

end

 

實(shí)例2 有安全,路由總結(jié)的OSPF設(shè)置

 

 


  internal-2的設(shè)置

Current configuration :

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname internal-2

!

enable secret 5 $1$KX00$rTI/2TvDokWxT4xC6wvmi/

!

interface Ethernet0

no ip address

shutdown

!

interface Serial0

ip address 192.1.2.2 255.255.255.0

ip ospf message-digest-key 1 md5 cisco

ip ospf network non-broadcast

!

interface Serial1

no ip address

shutdown

!

router ospf 1

network 192.1.2.0 0.0.0.255 area 2

neighbor 192.1.2.1 priority 1

area 2 authentication message-digest

!

no ip classless

!

line con 0

line 1 16

line aux 0

line vty 0 4

login

!

end

2505的設(shè)置

Current configuration:

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname 2505

!

enable secret 5 $1$b43o$CpEYSTC2EPwnR1QGvIm//

!

username 2511-1 password 7 104D000A0618

!

hub ether 0 1

link-test

auto-polarity

!

hub ether 0 2

link-test

auto-polarity

!

hub ether 0 3

link-test

auto-polarity

!

hub ether 0 4

link-test

auto-polarity

!

hub ether 0 5

link-test

auto-polarity

!

hub ether 0 6

link-test

auto-polarity

!

hub ether 0 7

link-test

auto-polarity

!

hub ether 0 8

link-test

auto-polarity

!

interface Ethernet0

ip address 192.1.4.1 255.255.255.0

!

interface Serial0

ip address 192.1.2.1 255.255.255.0

ip ospf message-digest –key 1 md5 cisco

ip ospf network non-broadcast

bandwidth 2000

clockrate 2000000

!

interface Serial1

ip address 192.7.1.2 255.255.255.0

enpsulation ppp

ip ospf message-digest -key 1 md5 kim

ip ospf network non-broadcast

bandwidth 64

clockrate 64000

ppp authentication chap

!

router ospf 1

passive-interface Ethernet0

network 192.1.2.0 0.0.0.255 area 2

network 192.1.4.0 0.0.0.255 area 2

network 192.7.1.0 0.0.0.255 area 0

neighbor 192.7.1.1 priority 1

neighbor 192.1.2.2 priority 1

area 0 authentication message-digest

area 2 authentication message-digest

area 2 range 192.1.0.0 255.255.0.0

!

no ip classless

ip ospf name-lookup

!

line con 0

line aux 0

line vty 0 4

login

!

end

2511-1的設(shè)置

Current configuration:



version 11.3

no service password-encryption

!

hostname 2511-1

!

enable password cisco

!

username 2505 passweord 0 cisco

no ip domain-lookup

!

interface Ethernet0

ip address 192.4.1.1 255.255.255.0

!

interface Serial0

ip address 192.3.1.1 255.255.255.0

encapsulation frame-relay IETF

ip ospf message-digest-key 1 md5 kim

no ip mroute-cache

bandwidth 2000

frame-relay map ip 192.3.1.2 100 broadcast

frame-relay lmi-type cisco

!

interface Serial1

ip address 192.7.1.1 255.255.255.0

encapsulation ppp

ip ospf message-digest-key 1 md5 kim

ip ospf network non-broadcast

bandwidth 64

ppp authentication chap

!

router ospf 1

passive-interface Ethernet0

network 192.3.1.0 0.0.0.255 area 0

network 192.4.1.0 0.0.0.255 area 0

network 192.7.1.0 0.0.0.255 area 0

neighbor 192.7.1.2 priority 1

neighbor 192.3.1.2 priority 1

area 0 authentication message-digest

!

no ip classless

!

line con 0

line 1 8

line aux 0

line vty 0 4

login

!

end

2514的設(shè)置

Current configuration :

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname 2514

!

enable secret 5 $1$uoHU$Vks/lY CRi33z4TXs4qekI0

!

frame-relay switching

!

interface Ethernet0

ip address 192.5.1.1 255.255.255.0

!

interface Ethernet1

no ip address

shutdown

!

interface Serial0

ip address 192.3.1.2 255.255.255.0

encapsulation frame-relay IETF

ip ospf message-digest-key 1 md5 kim

bandwidth 2000

clockrate 2000000

frame-relay map ip 192.3.1.1 100 broadcast

frame-relay intf-type dce

!

interface Serial1

ip address 192.8.1.1 255.255.255.0

no ip mroute-cache

encapsulation X25 dce

ip ospf message-digest-key 2 md5 cisco

bandwidth 64

x25 address 1234

x25 htc 16

x25 nvc 4

x25 map ip 192.8.1.2 5678 broadcast

clockrate 64000

!

router ospf 1

network 192.3.1.0 0.0.0.255 area 0

network 192.5.1.0 0.0.0.255 area 0

network 192.8.1.0 0.0.0.255 area 0

neighbor 192.8.1.2 priority 1

neighbor 192.3.1.1 priority 1

area 0 authentication message-digest

!

no ip classless

!

line con 0

line aux 0

line vty 0 4

login

!

end

2511-2的設(shè)置

Current configuration :

version 11.3

no service password-encryption

!

hostname 2511-2

!

enable secret 5 $1$7o5F$MSyFWzVf6JBgnjLJghHSB.

!

!

interface Ethernet0

ip address 192.2.4.1 255.255.255.0

!

interface Serial0

ip address 192.8.1.2 255.255.255.0

encapsulation x25

ip ospf message-digest-key 2 md5 cisco

no ip mroute-cache

x25 address 5678

x25 htc 16

x25 nvc 4

x25 map ip 192.8.1.1 1234 broadcast

!

interface Serial1

ip address 192.2.2.1 255.255.255.0

ip ospf authentication-key kim

ip ospf network non-broadcast

no ip mroute-cache

bandwidth 2000

clockrate 2000000

!

router ospf 1

passive-interface Ethernet0

network 192.2.2.0 0.0.0.255 area 1

network 192.2.4.0 0.0.0.255 area 1

network 192.8.1.0 0.0.0.255 area 0

neighbor 192.8.1.1 priority 1

neighbor 192.2.2.2 priority 1

area 0 authentication message-digest

area 1 authentication (疑應(yīng)加上message-digest,但原文如此)

area 1 range 192.2.0.0 255.255.0.0

!

ip classless

!

line con 0

line 1 8

line aux 0

line vty 0 4

login

!

end

internal -1的設(shè)置

Building configuration...

Current configuration:

!

version 11.2

no service udp-small-servers

no service tcp-small-servers

!

hostname internal-1

!

enable secret 5 $1$cF2M$z2T8Ohij5q/yn2RsiVaGE/

!

interface Ethernet0

no ip address

shutdown

!

interface Serial0

ip address 192.2.2.2 255.255.255.0

ip ospf authentication-key kim

ip ospf network non-broadcast

!

interface Serial1

no ip address

shutdown

!

router ospf 1

network 92.2.2.0 0.0.0.255 area 1

neighbor 192.2.2.1 priority 1

area 1authentication

!

no ip classless

!

line con 0

line 1 16

line aux 0

line vty 0 4

login

!

end




發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 额尔古纳市| 偏关县| 黑河市| 乐清市| 即墨市| 墨竹工卡县| 汽车| 潼南县| 常德市| 共和县| 霸州市| 海宁市| 尼木县| 大荔县| 隆德县| 娄底市| 桐庐县| 喀喇沁旗| 裕民县| 洪湖市| 洮南市| 黎城县| 资源县| 蓬溪县| 汝南县| 吴忠市| 凤城市| 图们市| 永修县| 景谷| 民和| 镇康县| 友谊县| 将乐县| 镇赉县| 内黄县| 宜川县| 沙田区| 阿拉尔市| 肃宁县| 肃宁县|