第一篇:關(guān)于路由器的一些常見(jiàn)問(wèn)題的歸納整理
一、Wan口無(wú)連接
二、Wan口有連接,但連接失敗。
三、寬帶正常,可以ping通,但無(wú)法打開(kāi)網(wǎng)頁(yè)
四、無(wú)線不能連接,但有線連接正常
五、頻繁掉線
五、安裝路由器后網(wǎng)速慢
六、不能獲取IP地址(不能獲取外網(wǎng)地址、不能獲取內(nèi)網(wǎng)地址)
七、IP地址沖突的調(diào)整
八、VPN連接
一、Wan口無(wú)連接。
Wan口無(wú)連接是安裝路由器時(shí)最常見(jiàn)的故障之一,處理起來(lái)看似簡(jiǎn)單,實(shí)際上有可能根本無(wú)解!Wan無(wú)連接主要有以下幾種情況:
1、線路沒(méi)有接正確!這是最應(yīng)該批評(píng)的疏忽大意!有時(shí)候路由器這邊Wan口倒是插上網(wǎng)線了,但是卻沒(méi)有連接到Modem上,LAN接入的沒(méi)有連接到墻壁上的模塊中。
2、網(wǎng)線連通性故障,主要是網(wǎng)線質(zhì)量差,或者線序都不正確。對(duì)于Modem接入的路由器,通常Modem距離路由器都不遠(yuǎn),只要線序沒(méi)有問(wèn)題,就算是很差的網(wǎng)線都可以正常連接。對(duì)于LAN接入的寬帶則要注意,如果樓道交換機(jī)到路由器之間距離比較遠(yuǎn),網(wǎng)線質(zhì)量必須過(guò)關(guān),否則會(huì)因?yàn)榫€路質(zhì)量差無(wú)法連通!這里網(wǎng)線不僅是網(wǎng)線本身,還包括水晶頭、進(jìn)戶(hù)弱電箱、墻壁上面板、模塊等一系列環(huán)節(jié),其中任意一個(gè)環(huán)節(jié)不穩(wěn)定都有可能導(dǎo)致WAN口無(wú)法連接!因此對(duì)于LAN接入的寬帶路由器WAN口無(wú)連接的,必須慢慢一個(gè)一個(gè)環(huán)節(jié)檢查。
3、速率不匹配。這個(gè)主要是對(duì)于LAN接入的方式的寬帶。部分ISP偷工減料,樓道交換機(jī)到桌面被限制在10M的速率上,不能達(dá)到100M的標(biāo)準(zhǔn)。而目前大多數(shù)普通路由器都不支持10M的連接速率,因此會(huì)因?yàn)樗俾什黄ヅ鋵?dǎo)致WAN無(wú)法連接!遇到這樣的情況,可以找市面上小部分支持10M WAN口連接的路由器測(cè)試就清楚了。
4、Modem不穩(wěn)定。這個(gè)情況很少遇到,但是一旦遇到則很難正確判斷.故障表現(xiàn)如下:Modem單獨(dú)連接電腦可以正常撥號(hào)上網(wǎng),Ping值正常,連接路由器,路由器WAN口顯示無(wú)連接,更換各個(gè)品牌路由器均無(wú)效果。因?yàn)閱为?dú)連接電腦可以正常上網(wǎng),則往往忽略Modem的問(wèn)題。實(shí)際上,這個(gè)情況Modem往往存在內(nèi)部元件損壞的故障,主要是供電電容爆漿,導(dǎo)致供電不穩(wěn)定,從而路由器連接失??!更換Modem解決故障!
5、ISP限制端口連接數(shù)。曾經(jīng)遇到一個(gè)非常典型的案例,客戶(hù)家跑了幾次,更換了幾個(gè)路由器,均顯示W(wǎng)an口無(wú)連接,只有發(fā)送沒(méi)有接受。原因是ISP限制客戶(hù)線路只能連接一臺(tái)終端,因此一旦接上路由器就出現(xiàn)故障。解決辦法:投訴工信部,或者威脅拆機(jī),不再使用他們的寬帶。遇到這樣的問(wèn)題很難處理,要知道,這里是天朝!
6、線序不對(duì)。這條與上邊第二條的線序不對(duì)有明顯區(qū)別,那是因?yàn)槭韬龃笠鈱?dǎo)致的線序故障,而此條則是線路維護(hù)員故意這樣搞的。極少數(shù)ISP的維護(hù)員故意將樓道交換機(jī)出來(lái)的網(wǎng)線線序按照他自己規(guī)定的做,這樣不能工作在100M下,但可以工作在10M下,問(wèn)題出來(lái)了!外邊自己買(mǎi)的路由器因?yàn)榇藛?wèn)題導(dǎo)致WAN口無(wú)連接,然后給維護(hù)員電話,維護(hù)員說(shuō)只要電腦能聯(lián)網(wǎng)就與他們無(wú)關(guān)。實(shí)際情況是,他們維護(hù)員自己帶路由器去客戶(hù)處安裝,安裝之前首先在交換機(jī)處按照正確的線序做好接頭,然后在客戶(hù)家重做水晶頭,當(dāng)然也是按照正確的做法,然后安裝路由器,收取顧客高價(jià),并將原有的技術(shù)員貶損一番。此故障我遇到過(guò)兩次,非常麻煩。
二、Wan口有連接,但連接失敗。
此種故障表現(xiàn)為,WAN口顯示有連接,但數(shù)據(jù)包只有發(fā)送沒(méi)有接收,或有接受到依然不能聯(lián)網(wǎng)。
1、寬帶欠費(fèi)
2、用戶(hù)名和密碼輸錯(cuò)
3、如果是綁定電話的,有可能綁定的電話欠費(fèi)停機(jī),導(dǎo)致寬帶跟著斷網(wǎng)。
4、之前顧客自己設(shè)置路由錯(cuò)誤輸入寬帶密碼,導(dǎo)致路由器使用錯(cuò)誤密碼頻繁撥號(hào),從而ISP后臺(tái)鎖死賬號(hào)。
5、ISP的接入服務(wù)器出現(xiàn)不穩(wěn)定故障,導(dǎo)致賬號(hào)莫名其妙的自動(dòng)鎖死。
6、MAC地址綁定。部分ISP對(duì)于MAC地址采取了綁定的策略,因此更換網(wǎng)卡或者添加路由器之后,檢測(cè)到MAC地址的變化,因此不予返回?cái)?shù)據(jù)。遇到這樣的情況,首先克隆正確的MAC,還不行的話,撥打ISP的客戶(hù)電話,讓對(duì)方在后臺(tái)刷新一下數(shù)據(jù),然后就可以正常調(diào)整路由器設(shè)置了。
7、網(wǎng)線質(zhì)量不過(guò)關(guān),發(fā)送數(shù)據(jù)和返回?cái)?shù)據(jù)出現(xiàn)大范圍丟包或者錯(cuò)誤包,導(dǎo)致連接失敗。更換水晶頭和網(wǎng)線后再次測(cè)試。
8、電話線路衰減過(guò)大,導(dǎo)致modem信號(hào)不穩(wěn)定,引起路由器撥號(hào)失敗。
二、寬帶正常,可以ping通公網(wǎng)地址,但無(wú)法打開(kāi)網(wǎng)頁(yè)。
路由器可以正常連接寬帶,電腦或者手機(jī)也可以正常訪問(wèn)路由器,但是不能訪問(wèn)外網(wǎng)。此種情況主要是DNS設(shè)置需要調(diào)整。
1、手機(jī)能訪問(wèn)外網(wǎng),電腦不能訪問(wèn):此種情況表明路由器已經(jīng)正常工作,但電腦的網(wǎng)卡需要設(shè)置DNS服務(wù)器地址,通常設(shè)置成所用的ISP的DNS服務(wù)器的地址,這樣是最優(yōu)化的方案,但實(shí)際應(yīng)用中,極少數(shù)會(huì)遇到運(yùn)營(yíng)商的DNS服務(wù)器不穩(wěn)定的故障,這個(gè)時(shí)候可以使用其它地區(qū)的公有DNS,個(gè)人比較推薦Google的DNS,可以說(shuō)是速度和穩(wěn)定性兼顧,8.8.8.8和8.8.4.4。
2、手機(jī)和電腦都不能訪問(wèn)外網(wǎng),但可以訪問(wèn)路由器。此種情況主要是路由器的DNS設(shè)置出現(xiàn)了問(wèn)題,雖然路由器連接上公網(wǎng)之后會(huì)自動(dòng)獲取DNS服務(wù)器地址,但是極少數(shù)情況下會(huì)出現(xiàn)獲取失敗的情況,因此導(dǎo)致終端訪問(wèn)故障。處理方式參考上邊第一條。
3、電腦能訪問(wèn)外網(wǎng),手機(jī)或者平板不能訪問(wèn)外網(wǎng),主這種情況其實(shí)不是路由器故障,大多數(shù)時(shí)候是被路由器防火墻限制了。請(qǐng)聯(lián)系路由器管理員?;蛘呗酚善髦匦聫?fù)位進(jìn)行設(shè)置。
4、操作系統(tǒng)故障。
三、無(wú)線不能連接,但有線連接正常
1、路由器故障,特別是無(wú)線模塊出現(xiàn)故障,可以更換路由器測(cè)試。
2、筆記本無(wú)線網(wǎng)卡驅(qū)動(dòng)異常,重新安裝驅(qū)動(dòng)。
3、找不到信號(hào),檢查無(wú)線開(kāi)關(guān)。
4、筆記本無(wú)線網(wǎng)卡接觸不良。
5、連接信號(hào)的時(shí)候始終顯示正在連接,一個(gè)是系統(tǒng)問(wèn)題,一個(gè)是無(wú)線密碼輸錯(cuò),特別是筆記本,因?yàn)殒I盤(pán)上數(shù)字鍵和字母鍵狀態(tài)不正確導(dǎo)致誤輸入。
6、無(wú)線路由器無(wú)線SSID最好別用中文。
7、信道受到外界干擾,導(dǎo)致連接失敗,可以嘗試著更換其它信道測(cè)試連接情況。
8、檢查筆記本中午無(wú)線網(wǎng)卡的屬性和路由器中是否一致,包括加密方式。
9、最低級(jí)的失誤,路由器中無(wú)線功能根本就沒(méi)有啟用!
五、頻繁掉線
1、檢查水晶頭是否氧化?是否松動(dòng)脫落?LAN接入的檢查入戶(hù)處接頭是否松動(dòng)?線路是否破損?
2、Modem接入的,檢查Modem到路由器之間的網(wǎng)線,以及Modem的電話線進(jìn)線,Modem以及路由器的電源適配器是否可靠接觸。
3、路由器是否處于按需連接的方式?此種方式在閑置一段時(shí)間后有可能會(huì)自動(dòng)斷開(kāi)連接。
4、Modem質(zhì)量問(wèn)題,導(dǎo)致頻繁掉線。
5、路由器質(zhì)量問(wèn)退,導(dǎo)致頻繁掉線。
6、路由器到電腦主機(jī)之間網(wǎng)線連通性和可靠性。包括墻壁模塊的可靠性。以及網(wǎng)線質(zhì)量是否過(guò)關(guān)??梢詫⒕W(wǎng)卡強(qiáng)制到10M來(lái)測(cè)試看是否頻繁掉線。正常情況下,網(wǎng)卡和路由器之間應(yīng)該保證100M全雙工模式。
7、如果是無(wú)線頻繁掉線,要檢查無(wú)線設(shè)置以及有無(wú)外來(lái)干擾。
8、電腦網(wǎng)卡和路由器之間的匹配問(wèn)題。
9、如果是Modem接入的,檢查一下分離器的地方是否電話線和Modem接線搞反了,以至于電話一響就斷線了。
10、在有多個(gè)交換機(jī)的復(fù)雜網(wǎng)絡(luò)中,有可能存在交換機(jī)多連接導(dǎo)致環(huán)路,引起IP地址沖突頻繁掉線。
11、各個(gè)終端之間有可能多臺(tái)電腦采用了同一個(gè)IP地址,或者有電腦中毒產(chǎn)生ARP欺騙。
12天朝特色,限制路由器。
六、不能獲取IP地址(不能獲取外網(wǎng)地址、不能獲取內(nèi)網(wǎng)地址)
A、不能獲取外網(wǎng)地址,這種情況其實(shí)在單位中很常見(jiàn)。
1、線路質(zhì)量不過(guò)關(guān)
2、設(shè)置不正確,特別是[敏感詞]部門(mén)的內(nèi)網(wǎng),特別多。主要是因?yàn)樗麄兊姆?wù)器基本上都是關(guān)閉DHCP,手動(dòng)分配IP地址的,甚至部分還采用手動(dòng)地址+MAC綁定的方式,既然新路由器上去,肯定是不能獲取IP地址。而路由器通常出廠都是動(dòng)態(tài)IP。
3、看看是否采用了VPN連接,這點(diǎn)在企業(yè)部門(mén)中很常見(jiàn),各個(gè)門(mén)店或分支機(jī)構(gòu)和總部之間多半采用的是VPN連接,而路由器設(shè)置不對(duì),甚至部分路由器不支持VPN連接。
4、上級(jí)路由器或者交換機(jī)(往往是三層交換機(jī))沒(méi)有啟用DHCP。
B、不能獲取內(nèi)網(wǎng)地址
1、線路質(zhì)量不過(guò)關(guān)。
2、沒(méi)有啟用DHCP,而客戶(hù)端也沒(méi)有按照規(guī)則手動(dòng)指定IP地址。
3、網(wǎng)卡和路由器不匹配。
4、系統(tǒng)故障。
七、IP地址沖突的調(diào)整
現(xiàn)在很多ISP贈(zèng)送的Modem或者光貓或者無(wú)線貓,自帶IP分配,而且往往和路由器的沖突,比如Modem分配給終端的是192.168.1.2,而路由器的默認(rèn)網(wǎng)關(guān)是192.168.1.1,這個(gè)時(shí)候就會(huì)出現(xiàn)問(wèn)題,可以把路由器的改為192.168.2.1,總之,無(wú)論怎么改,都不要產(chǎn)生同一個(gè)網(wǎng)關(guān)地址,根據(jù)實(shí)際情況調(diào)整,這里沒(méi)法細(xì)說(shuō),否則就要出書(shū)了。
八、VPN連接
VPN連接一般個(gè)人用戶(hù)使用很少,主要是單位和[敏感詞]部門(mén),單位主要是各個(gè)門(mén)店或者分支機(jī)構(gòu)和總部之間的聯(lián)系;[敏感詞]部門(mén)則是各個(gè)下級(jí)單位和上級(jí)部門(mén)的聯(lián)系,總之差不多,一個(gè)意思。設(shè)置VPN并不復(fù)雜,但是一定要注意對(duì)應(yīng)的IP地址和端口,或者網(wǎng)址鏈接,我曾經(jīng)遇到過(guò)復(fù)制網(wǎng)址的時(shí)候少了一個(gè)小數(shù)點(diǎn),導(dǎo)致始終連接失敗!
另外要注意的是,部分入門(mén)級(jí)路由器,不帶VPN撥號(hào)的功能,只能換其它型號(hào)。
至于普通用戶(hù)在電腦上設(shè)置VPN用于工作或翻墻,則是另外一回事,和路由器無(wú)關(guān)。
第二篇:申請(qǐng)路由器交換器
申請(qǐng)報(bào)告
公司領(lǐng)導(dǎo):
由于酒店主機(jī)房設(shè)備自開(kāi)業(yè)至今每天24小時(shí)運(yùn)行工作,已逐步出現(xiàn)老化情況,現(xiàn)影響網(wǎng)速慢的主要原因?yàn)椋?/p>
1、現(xiàn)主機(jī)房使用的路由器和交換機(jī)不是商業(yè)型的,無(wú)法控制每天電腦上網(wǎng)的流量,導(dǎo)致影響網(wǎng)路速度不均勻,造成客房?jī)?nèi)上網(wǎng)受到一定的影響,現(xiàn)需更換成商業(yè)型的路由器和交換機(jī)。(原路由器和交換機(jī)為百兆,現(xiàn)需更換為千兆的)。
2、原網(wǎng)絡(luò)光釬為4兆,根據(jù)目前的需求量,原流量無(wú)法滿(mǎn)足使用要求,現(xiàn)需將網(wǎng)絡(luò)光釬增加為10兆。(現(xiàn)4兆每年費(fèi)用為17200元,10兆每年費(fèi)用為37200元)
3、2012年工作計(jì)劃將9樓改為行政房,需增加電腦14臺(tái)。
根據(jù)以上情況,故特此申請(qǐng),望領(lǐng)導(dǎo)批準(zhǔn)為盼。
(備注:
1、商業(yè)路由器的作用是可以把整個(gè)網(wǎng)絡(luò)分配為多個(gè)網(wǎng)絡(luò)點(diǎn),也就是說(shuō),將每個(gè)上網(wǎng)端口分別做限量的網(wǎng)速,這樣的話,互相上網(wǎng)就不怕影響到其他用戶(hù)。目前來(lái)說(shuō),酒店的路由器沒(méi)有做網(wǎng)絡(luò)分流,也就是說(shuō)只要有一個(gè)用戶(hù)大流量使用網(wǎng)絡(luò),就會(huì)直接影響到其他用戶(hù)。
2、交換機(jī)的作用是將所有的網(wǎng)絡(luò)分配給各個(gè)端口)
第三篇:路由器 交換機(jī) 難點(diǎn)總結(jié)
目錄
難點(diǎn)包括:
MSTP VRRP NAT ACL 靜態(tài)路由
路由重發(fā)布
策略路由
多生成樹(shù)協(xié)議MSTP 第一步:配置接入層交換機(jī)S2126-A S2126-A(config)#spanning-tree
!開(kāi)啟生成樹(shù)
S2126-A(config)#spanning-tree mode mstp
!配置生成樹(shù)模式為MSTP 創(chuàng)建vlan10,20,40 S2126-A(config)#spanning-tree mst configuration
!進(jìn)入MSTP配置模式
S2126-A(config-mst)#instance 1 vlan 1,10
!配置instance 1(實(shí)例1)并關(guān)聯(lián)Vlan 1和10 S2126-A(config-mst)#instance 2 vlan 20,40
!配置實(shí)例2并關(guān)聯(lián)Vlan 20和40 S2126-A(config-mst)#name region1
!配置域名稱(chēng)
S2126-A(config-mst)#revision 1
!配置版本(修訂號(hào))
驗(yàn)證測(cè)試:驗(yàn)證MSTP配置
S2126-A#show spanning-tree mst configuration
!顯示MSTP全局配置
第二步:配置接入層交換機(jī)S2126-B S2126-B(config)#spanning-tree
!開(kāi)啟生成樹(shù)
S2126-B(config)#spanning-tree mode mstp
!采用MSTP生成樹(shù)模式 創(chuàng)建vlan10,20,40 S2126-B(config)#spanning-tree mst configuration
!進(jìn)入MSTP配置模式 S2126-B(config-mst)#instance 1 vlan 1,10
!配置instance 1(實(shí)例1)并關(guān)聯(lián)Vlan 1和10 S2126-B(config-mst)#instance 2 vlan 20,40
!配置實(shí)例2并關(guān)聯(lián)Vlan 20和40 S2126-B(config-mst)#name region1
!配置域名稱(chēng)
S2126-B(config-mst)#revision 1
!配置版本(修訂號(hào))
第三步:配置分布層交換機(jī)S3550-A S3550-A(config)#spanning-tree!開(kāi)啟生成樹(shù)
S3550-A(config)#spanning-tree mode mstp
!采用MSTP生成樹(shù)模式
S3550-A(config)#spanning-tree mst configuration
!進(jìn)入MSTP配置模式 S3550-A(config)#spanning-tree mst 1 priority 4096
!配置交換機(jī)S3550-A在instance 1中的優(yōu)先級(jí)為4096,缺省是32768,值越小越優(yōu)先成為該instance中的root switch S3550-A(config-mst)#instance 1 vlan 1,10
!配置實(shí)例1并關(guān)聯(lián)Vlan 1和10 S3550-A(config-mst)#instance 2 vlan 20,40
!配置實(shí)例2并關(guān)聯(lián)Vlan 20和40 S3550-A(config-mst)#name region1
!配置域名為region1 S3550-A(config-mst)#revision 1
!配置版本(修訂號(hào))
第四步:配置分布層交換機(jī)S3550-B S3550-B(config)#spanning-tree!開(kāi)啟生成樹(shù)
S3550-B(config)#spanning-tree mode mstp
!采用MSTP生成樹(shù)模式
S3550-B(config)#spanning-tree mst 2 priority 4096
!配置交換機(jī)S3550-B在instance 2(實(shí)例2)中的優(yōu)先級(jí)為4096,缺省是32768,值越小越優(yōu)先成為該region(域)中的root switch S3550-B(config)#spanning-tree mst configuration
!進(jìn)入MSTP配置模式 S3550-B(config-mst)#instance 1 vlan 1,10
!配置實(shí)例1并關(guān)聯(lián)Vlan 1和10 S3550-B(config-mst)#instance 2 vlan 20,40
!配置實(shí)例2并關(guān)聯(lián)Vlan 20和40
S3550-B(config-mst)#name region1
!配置域名為region1 S3550-B(config-mst)#revision 1
!配置版本(修訂號(hào))
第五步:驗(yàn)證交換機(jī)配置
S3550-A#show spanning-tree mst 1
!顯示交換機(jī)S3550-A上實(shí)例1的特性
【注意事項(xiàng)】
? 對(duì)規(guī)模很大的交換網(wǎng)絡(luò)可以劃分多個(gè)域(region),在每個(gè)域里可以創(chuàng)建多個(gè)instance? ? ?
(實(shí)例);
劃分在同一個(gè)域里的各臺(tái)交換機(jī)須配置相同的域名(name)、相同的修訂號(hào)(revision number)、相同的 instance—vlan 對(duì)應(yīng)表;
交換機(jī)可以支持65個(gè)MSTP instance,其中實(shí)例0是缺省實(shí)例,是強(qiáng)制存在的,其它實(shí)例可以創(chuàng)建和刪除;
將整個(gè)spanning-tree恢復(fù)為缺省狀態(tài)用命令spanning-tree reset。
VRRP VRRP單備份組配置示例
設(shè)備R1的配置:
進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 priority 120
Ruijie(config-if)# vrrp 1 timers advertise 3 Ruijie(config-if)# vrrp 1 ip 192.168.201.1 設(shè)備R2的配置:
進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 ip 192.168.201.1 Ruijie(config-if)# vrrp 1 timers advertise 3
使用VRRP監(jiān)視接口配置示例
設(shè)備R1的配置: 進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 priority 120
Ruijie(config-if)# vrrp 1 timers advertise 3 Ruijie(config-if)# vrrp 1 ip 192.168.201.1
Ruijie(config-if)# vrrp 1 track GigabitEthernet 2/1 30
設(shè)備R2的配置: 進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 ip 192.168.201.1 Ruijie(config-if)# vrrp 1 timers advertise 3
VRRP多備份組配置示例
設(shè)備R1的配置: 進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 timers advertise 3 Ruijie(config-if)# vrrp 1 ip 192.168.201.1 Ruijie(config-if)# vrrp 2 priority 120
Ruijie(config-if)# vrrp 2 timers advertise 3 Ruijie(config-if)# vrrp 2 ip 192.168.201.2
Ruijie(config-if)# vrrp 2 track GigabitEthernet 2/1 30
設(shè)備R2的配置: 進(jìn)入內(nèi)網(wǎng)端口
Ruijie(config-if)# vrrp 1 ip 192.168.201.1 Ruijie(config-if)# vrrp 1 timers advertise 3 Ruijie(config-if)# vrrp 1 priority 120
Ruijie(config-if)# vrrp 2 ip 192.168.201.2
Ruijie(config-if)# vrrp 2 timers advertise 3
NAT(網(wǎng)絡(luò)地址轉(zhuǎn)換)
利用動(dòng)態(tài) NAPT 實(shí)現(xiàn)局域網(wǎng)訪問(wèn)互聯(lián)網(wǎng)
在lan-router 上配置缺省路由
lan-router(config)#ip route 0.0.0.0 0.0.0.0 serial 1/2
配置動(dòng)態(tài)NAPT 映射。
lan-router(config)#interface fastEthernet 1/0 lan-router(config-if)#ip nat inside!定義F1/0 為內(nèi)網(wǎng)接口 lan-router(config-if)#exit lan-router(config)#interface serial 1/2 lan-router(config-if)#ip nat outside!定義S1/2 為外網(wǎng)接口
lan-router(config-if)#exit lan-router(config)#ip nat pool to_internet 200.1.8.7 200.1.8.7 netmask 255.255.255.0!定義內(nèi)部全局地址池
lan-router(config)#access-list 10 permit 172.16.1.0 0.0.0.255!定義允許轉(zhuǎn)換的地址
lan-router(config)#ip nat inside source list 10 pool to_internet overload!為內(nèi)部本地調(diào)用轉(zhuǎn)換地址池
驗(yàn)證測(cè)試。
1、在服務(wù)器63.19.6.2 上配置Web 服務(wù)(配置方法詳見(jiàn)選修實(shí)驗(yàn))。
2、在PC 機(jī)測(cè)試訪問(wèn)63.19.6.2 的網(wǎng)頁(yè)。
3、在路由器lan-router 查看NAPT 映射關(guān)系。
lan-router#show ip nat translations!查看NAPT 的動(dòng)態(tài)映射表
Pro Inside global Inside local Outside local Outside global tcp 200.1.8.7:2502 172.16.1.55:2502 63.19.6.2:80 63.19.6.2:80
利用 NAT 實(shí)現(xiàn)外網(wǎng)主機(jī)訪問(wèn)內(nèi)網(wǎng)服務(wù)器
在lan-router 上配置缺省路由
lan-router(config)#ip route 0.0.0.0 0.0.0.0 serial 1/2
配置反向NAT 映射。
lan-router(config)#interface fastEthernet 1/0 lan-router(config-if)#ip nat inside lan-router(config-if)#exit lan-router(config)#interface serial 1/2 lan-router(config-if)#ip nat outside lan-router(config-if)#exit lan-router(config)#ip nat pool web_server 172.16.8.5 172.16.8.5 netmask 255.255.255.0!定義內(nèi)網(wǎng)服務(wù)器地址池 lan-router(config)#access-list 3 permit host 200.1.8.7!定義外網(wǎng)的公網(wǎng)IP 地址
lan-router(config)#ip nat inside destination list 3 pool web_server!將外網(wǎng)的公網(wǎng)IP 地址轉(zhuǎn)換為Web 服務(wù)器地址。
lan-router(config)# ip nat inside source static tcp 172.16.8.5 80 200.1.8.7 80!定義訪問(wèn)外網(wǎng)IP 的80 端口時(shí)轉(zhuǎn)換為內(nèi)網(wǎng)的服務(wù)器IP 的80 端口
lan-router#show ip nat translations Pro Inside global Inside local Outside local Outside global tcp 200.1.8.7:80 172.16.8.5:80 63.19.6.2:1026 63.19.6.2:1026
ACL ACL時(shí)間控制
S1(config)#time-range nowww!定義周期性時(shí)間段 名字為nowww
S1(config-time-range)#periodic Daily 8:00 to 17:00!定義周期性時(shí)間段為每天的8點(diǎn)到17點(diǎn)
S1(config-time-range)#exit S1(config)#ip access-list extended notcp!進(jìn)入擴(kuò)展ACL 名字為notcp S1(config-ext-nacl)#deny tcp any any eq www time-range nowww S1(config-ext-nacl)#permit ip any any S1(config-time-range)#exit S1(config)#interface GigabitEthernet 0/28 S1(config-if)#ip access-group notcp in
ACL限制IP訪問(wèn)
S1(config)#access-list 1 deny 192.168.3.0 0.0.0.255!拒絕來(lái)自192.168.3.0網(wǎng)段的流量通過(guò) S1(config)#show access-lists 1!驗(yàn)證測(cè)試
S1(config)#interface fastEthernet 0/1 S1(config-if)#ip access-group 1 in!把訪問(wèn)控制列表在接口下應(yīng)用
靜態(tài)路由
Router2(config)#ip route 172.16.1.0 255.255.255.0 172.16.2.1 或:
Router2(config)#ip route 172.16.1.0 255.255.255.0 serial 1/2
驗(yàn)證測(cè)試:驗(yàn)證路由器接口的配置。Router1#show ip interface brief
注意:查看接口的狀態(tài)。Router1#show interface serial 1/2
PPP協(xié)議
PPP協(xié)議PAP加密
Ra=公司 Rb=ISP
先配置兩個(gè)端口的IP
Ra(config-if)#encapsulation ppp!接口下封裝PPP協(xié)議
Ra(config-if)#ppp pap sent-username Ra password 0 123!PAP認(rèn)證的用戶(hù)名、密碼
Rb(config)#username Ra password 0 123!驗(yàn)證方配置被驗(yàn)證方用戶(hù)名、密碼 Rb(config-if)#clock rate 64000 Rb(config-if)#encapsulation ppp!
Rb9config-if)#ppp authentication pap!ppp啟用PAP認(rèn)證方式
最后別忘no shutdown
PPP協(xié)議CHAP加密
Ra(config)#username Rb password 0 star!以對(duì)方的主機(jī)名作為用戶(hù)名,密碼和對(duì)
方的路由器一致
Ra(config)#interface serial 1/2 Ra(config-if)#encapsulation ppp Ra(config-if)#ppp authentication chap!PPP 啟用CHAP 方式驗(yàn)證
Rb(config)#username Ra password 0 star!以對(duì)方的主機(jī)名作為用戶(hù)名,密碼和對(duì)方的路由器一致
Rb(config)#interface serial 4/0 Rb(config-if)# encapsulation ppp
路由重發(fā)布
情況:三成交換機(jī)協(xié)議為RIP 路由器R2協(xié)議為OSPF 路由器R1配置路由重發(fā)布
R1(config)#route rip R1(config-router)#redistribute ospf 1 R1(config)#route ospf 1 R1(config-router)#redistribute rip subnets
策略路由
第一步:在路由器上配置 IP 路由選擇和IP 地址 RG(config)#interface serial 1/3 RG(config-if)#ip address 192.168.6.5 255.255.255.0 RG(config-if)# clock rate 64000 RG(config)#interface FastEthernet 1/0 RG(config-if)#ip address 10.1.1.1 255.0.0.0 RG(config)#interface FastEthernet 1/1 RG(config-if)#ip address 172.16.7.6 255.255.255.0 RG(config)# ip route 0.0.0.0 0.0.0.0 FastEthernet 1/1 RG(config)#ip route 0.0.0.0 0.0.0.0 serial 1/3 RG(config)#ip route 10.0.0.0 255.0.0.0 FastEthernet 1/0
第二步:定義訪問(wèn)列表
RG(config)# access-list 10 permit 10.1.0.0 0.0.255.255 RG(config)# access-list 20 permit 10.2.0.0 0.0.255.255
第三步:配置路由映射表
RG(config)#route-map ruijie permit 10 RG(config-route-map)#match ip address 10 RG(config-route-map)#set ip default next-hop 192.168.6.6
RG(config)#route-map ruijie permit 20 RG(config-route-map)#match ip address 20 RG(config-route-map)#set ip default next-hop 172.16.7.7 RG(config)#route-map ruijie permit 30 RG(config-route-map)#set interface Null 0
第四步:在接口上應(yīng)用路由策略 RG(config)# interface FastEthernet 1/0 RG(config-if)#ip policy route-map ruijie
第五步:驗(yàn)證測(cè)試
在 HOST A 上用PING 命令來(lái)測(cè)試路由映射。C:>ping 119.1.1.1 Pinging 119.1.1.1 with 32 bytes of data: Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Ping statistics for 119.1.1.1: Packets: Sent = 4, Received = 4, Lost = 0(0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms, Maximum = 0ms, Average = 0ms RG#sh route-map route-map ruijie, permit, sequence 10 Match clauses: ip address 10 Set clauses: ip default next-hop 192.168.6.6 Policy routing matches: 21 packets, 2304 bytes route-map ruijie, permit, sequence 20 Match clauses: ip address 20 Set clauses: ip default next-hop 172.16.7.7 Policy routing matches: 0 packets, 0 bytes route-map ruijie, permit, sequence 30 Match clauses: Set clauses: interface Null 0 Policy routing matches: 0 packets, 0 bytes 在 HOST B 上用PING 命令來(lái)測(cè)試路由映射。C:>ping 119.1.1.1 Pinging 119.1.1.1 with 32 bytes of data: Reply from 119.1.1.1: bytes=32 time<1ms TTL=64
Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Reply from 119.1.1.1: bytes=32 time<1ms TTL=64 Ping statistics for 119.1.1.1: Packets: Sent = 4, Received = 4, Lost = 0(0% loss), Approximate round trip times in milli-seconds: Minimum = 0ms, Maximum = 0ms, Average = 0ms RG#sh route-map route-map ruijie, permit, sequence 10 Match clauses: ip address 10 Set clauses: ip default next-hop 192.168.6.6 Policy routing matches: 21 packets, 2304 bytes route-map ruijie, permit, sequence 20 Match clauses: ip address 20 Set clauses: ip default next-hop 172.16.7.7 Policy routing matches: 9 packets, 576 bytes route-map ruijie, permit, sequence 30 Match clauses: Set clauses: interface Null 0 Policy routing matches: 0 packets, 0 bytes 把HOST B 的IP 地址改為10.3.1.1,用PING 命令來(lái)測(cè)試路由映射。C:>ping 119.1.1.1 Pinging 119.1.1.1 with 32 bytes of data: Pinging 17.1.1.1 with 32 bytes of data: Request timed out.Request timed out.Request timed out.Request timed out.RG#sh iroute-map route-map ruijie, permit, sequence 10 Match clauses: ip address 10 Set clauses: ip default next-hop 192.168.6.6 Policy routing matches: 21 packets, 2304 bytes route-map ruijie, permit, sequence 20 Match clauses: ip address 20 Set clauses:
ip default next-hop 172.16.7.7 Policy routing matches: 9 packets, 576 bytes route-map ruijie, permit, sequence 30 Match clauses: Set clauses: interface Null 0 Policy routing matches: 27 packets, 1728 bytes
第四篇:cisco 路由器 EZvpn 總結(jié)
實(shí)驗(yàn)拓?fù)鋱D:
PC2192.168.150.2/24分支機(jī)構(gòu)PC1192.168.100.0/24E0/3:.1R1192.168.100.2/24192.168.1.0/24E0/0:.1公司總部192.168.150.0/24192.168.2.0/24E0/3:.1E0/1:.2E0/0:.1E0/1:.2192.168.200.0/24E0/3:.1PC3R2R3192.168.200.2/24
實(shí)現(xiàn)目標(biāo)
分支機(jī)構(gòu)為不固定IP地址,分支機(jī)構(gòu)和公司總部實(shí)現(xiàn)VPN互聯(lián)。分支機(jī)構(gòu)能夠獲取公司總部的網(wǎng)絡(luò)資源。
基本配置:
EZvpn network-extension 模式 R1基本配置: R1# R1#show run
Building configuration...Current configuration : 1010 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R1!boot-start-marker boot-end-marker!noaaa new-model memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。。。。nterface Ethernet0/0 ip address 192.168.1.1 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex!interface Ethernet0/1 noip address shutdown half-duplex!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.100.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.1.2!ipnat inside source list 1 interface Ethernet0/0 overload!access-list 1 permit any!!control-plane?。。。。ine con 0 exec-timeout 0 0 line aux 0 linevty 0 4 login!end
R1#
R2的基本配置: R2# R2#show run
Building configuration...Current configuration : 825 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R2!boot-start-marker boot-end-marker!noaaa new-model memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。。。。nterface Ethernet0/0 ip address 192.168.2.1 255.255.255.0 half-duplex!interface Ethernet0/1 ip address 192.168.1.2 255.255.255.0 half-duplex!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.150.1 255.255.255.0 half-duplex!ip http server noip http secure-server!ip forward-protocol nd!!
!control-plane?。。。。ine con 0 exec-timeout 0 0 line aux 0 linevty 0 4 login!end R2#
R3的基本配置: R3# *Mar 1 00:13:56.891: %SYS-5-CONFIG_I: Configured from console by console R3# R3#show run Building configuration...Current configuration : 1010 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!noaaa new-model memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。。。?!interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 1 interface Ethernet0/1 overload!access-list 1 permit any!!control-plane?。。。?!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4 login!end
聯(lián)通性測(cè)試: 在R1上測(cè)試:
在R3上測(cè)試:
在PC1上測(cè)試
在PC2上測(cè)試
在PC3上測(cè)試
設(shè)定公司總部R3為Ezvpn Server,則R3上配置如下 R3# R3#show run
Building configuration...Current configuration : 1505 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!aaa new-model!aaa authorization network ezvpnauthor local!aaa session-id common memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3!?。。。。。。。?/p>
!cryptoisakmp policy 1 authentication pre-share group 2!cryptoisakmp client configuration group group1 key cisco!cryptoipsec transform-set mysetesp-des esp-md5-hmac!crypto dynamic-map dymap 1 set transform-set myset reverse-route!crypto map vpnmapisakmp authorization list ezvpnauthor crypto map vpnmap client configuration address respond crypto map vpnmap 1 ipsec-isakmp dynamic dymap!!
interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex crypto map vpnmap!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!
ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 1 interface Ethernet0/1 overload!access-list 1 permit any!!control-plane?。。。。?/p>
line con 0 exec-timeout 0 0 line aux 0 linevty 0 4!End
公司分部R1為remote角色,在Ezvpn Remote 上面配置 R1# R1#sho run
Building configuration...Current configuration : 1244 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R1!boot-start-marker boot-end-marker!noaaa new-model memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。。。?!!
cryptoipsec client ezvpn client1 connect auto group group1 key cisco mode network-extension peer 192.168.2.2 xauthuserid mode interactive!!!interface Ethernet0/0 ip address 192.168.1.1 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex cryptoipsec client ezvpn client1!interface Ethernet0/1 noip address shutdown half-duplex!
interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.100.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex cryptoipsec client ezvpn client1 inside!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.1.2!ipnat inside source list 1 interface Ethernet0/0 overload!access-list 1 permit any!
!control-plane!?。。。ine con 0 exec-timeout 0 0 line aux 0 linevty 0 4 login!end
R1#
查看R1的vpn狀態(tài)
在PC1上測(cè)試
我們發(fā)現(xiàn),vpn隧道雖然建立起來(lái)了,但是,外網(wǎng)和總部?jī)?nèi)網(wǎng)都ping不通了。這是由于PC1的數(shù)據(jù)都經(jīng)由隧道了,包括訪問(wèn)公網(wǎng)的數(shù)據(jù)包,都被導(dǎo)入隧道中。我們將隧道進(jìn)行分離,讓訪問(wèn)公網(wǎng)的數(shù)據(jù)能正常被NAT成R1的公網(wǎng)地址。
R3#
show run Building configuration...Current configuration : 1568 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!aaa new-model!aaa authorization network ezvpnauthor local!aaa session-id common memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。?!
!cryptoisakmp policy 1 authentication pre-share group 2!cryptoisakmp client configuration group group1 key cisco acl 100!cryptoipsec transform-set mysetesp-des esp-md5-hmac!crypto dynamic-map dymap 1 set transform-set myset reverse-route!crypto map vpnmapisakmp authorization list ezvpnauthor crypto map vpnmap client configuration address respond crypto map vpnmap 1 ipsec-isakmp dynamic dymap!!
!interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex crypto map vpnmap!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 1 interface Ethernet0/1 overload!access-list 1 permit any access-list 100 permit ip 192.168.200.0 0.0.0.255 any!!control-plane?。。?!
!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4!end
R3#
在R1上重建VPN
在R1上查看Vpn狀態(tài),我們發(fā)現(xiàn),隧道被成功分離,只有去往192.168.200.0/24的數(shù)據(jù)才會(huì)經(jīng)由隧道。
這個(gè)時(shí)候,我們?cè)赑C1上進(jìn)行測(cè)試
發(fā)現(xiàn),可以正常訪問(wèn)公網(wǎng),但是還不能訪問(wèn)vpn對(duì)端內(nèi)網(wǎng),怎么回事呢?我們查看R3的NAT表。
在R3上面查看NAT表
發(fā)現(xiàn),R3內(nèi)網(wǎng)192.168.200.2機(jī)器icmp reply 全部被NAT成R3的公網(wǎng)接口192.168.2.2地址了。
在R3上修正NAT問(wèn)題 R3# R3#show run Building configuration...Current configuration : 1678 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!aaa new-model!aaa authorization network ezvpnauthor local!aaa session-id common memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3!?。。。。。。?!
!cryptoisakmp policy 1 authentication pre-share group 2!cryptoisakmp client configuration group group1 key cisco acl 100!cryptoipsec transform-set mysetesp-des esp-md5-hmac!crypto dynamic-map dymap 1 set transform-set myset reverse-route!crypto map vpnmapisakmp authorization list ezvpnauthor crypto map vpnmap client configuration address respond crypto map vpnmap 1 ipsec-isakmp dynamic dymap!!
!interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex crypto map vpnmap!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 111 interface Ethernet0/1 overload!access-list 1 permit any access-list 100 permit ip 192.168.200.0 0.0.0.255 any access-list 111 deny
ip 192.168.200.0 0.0.0.255 192.168.100.0 0.0.0.255 access-list 111 permit ip any any!!control-plane!!!
??!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4!end
R3#
我們通過(guò)ACL,先限制源地址192.168.200.0去往192.168.100.0地址進(jìn)行NAT轉(zhuǎn)換,然后允許其它流量轉(zhuǎn)換。在PC1上重新測(cè)試
在PC3上進(jìn)行測(cè)試
OK,VPN實(shí)現(xiàn)成功,總部和分支機(jī)構(gòu)內(nèi)部訪問(wèn)外網(wǎng)和對(duì)端網(wǎng)絡(luò)都正常。
Ezvpn Client模式 R3上配置 R3# R3#show run
Building configuration...Current configuration : 1811 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!aaa new-model!aaa authorization network ezvpnauthor local!aaa session-id common memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。。。。?/p>
!cryptoisakmp policy 1 authentication pre-share group 2!cryptoisakmp client configuration group group1 key cisco poolezvpnpool acl 100!cryptoipsec transform-set set1 esp-des esp-md5-hmac!crypto dynamic-map dymap 1 set transform-set set1 reverse-route!crypto map vpnmapisakmp authorization list ezvpnauthor crypto map vpnmap client configuration address respond crypto map vpnmap 1 ipsec-isakmp dynamic dymap!
!interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex crypto map vpnmap!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip local pool ezvpnpool 10.10.10.1 10.10.10.100 ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 111 interface Ethernet0/1 overload!access-list 1 permit any access-list 100 permit ip 192.168.200.0 0.0.0.255 any access-list 111 deny
ip 192.168.200.0 0.0.0.255 10.10.10.0 0.0.0.255 access-list 111 deny
ip 192.168.200.0 0.0.0.255 192.168.100.0 0.0.0.255 access-list 111 permit ip any any!!control-plane!!
?。?!!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4!end
R3#
R1上的配置 R1#show run
Building configuration...Current configuration : 1396 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R1!boot-start-marker boot-end-marker!noaaa new-model memory-sizeiomem 5!ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3!?。。。。。。。。?!!
cryptoipsec client ezvpn client1 connect auto group group1 key cisco mode client peer 192.168.2.2 xauthuserid mode interactive cryptoipsec client ezvpn client connect auto mode network-extension xauthuserid mode interactive??!!interface Loopback0 ip address 10.10.10.1 255.255.255.255!interface Ethernet0/0 ip address 192.168.1.1 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex cryptoipsec client ezvpn client1!interface Ethernet0/1 noip address shutdown half-duplex!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.100.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex cryptoipsec client ezvpn client1 inside!ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.1.2!ipnat inside source list 1 interface Ethernet0/0 overload!access-list 1 permit any!!control-plane?。。。?!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4 login!end
R1#
在R1上查看vpn狀態(tài)
我們看到,當(dāng)R1為client模式的時(shí)候,它將獲取地址池中的一個(gè)地址,為10.10.10.7,所有vpn流量,都會(huì)用這個(gè)地址進(jìn)行nat轉(zhuǎn)換。我們看R1上的show ipnat translation
在R1上測(cè)試網(wǎng)絡(luò)連通性
在R3上測(cè)試聯(lián)通性
由于R1內(nèi)部機(jī)器地址都會(huì)被NAT成10.10.10.7,所以,對(duì)于R3內(nèi)部用戶(hù)來(lái)說(shuō)是不可訪問(wèn)的。
配置xauth認(rèn)證 R3的配置 R3# R3#show run
Building configuration...Current configuration : 1941 bytes!version 12.4 service timestamps debug datetimemsec service timestamps log datetimemsec no service password-encryption!hostname R3!boot-start-marker boot-end-marker!aaa new-model!aaa authentication login ezvpnlogin local aaa authorization network ezvpnauthor local!aaa session-id common memory-sizeiomem 5!
ipcef noip domain lookup!ipauth-proxy max-nodata-conns 3 ip admission max-nodata-conns 3?。。。。。?!!username cisco password 0 cisco!
!!cryptoisakmp policy 1 authentication pre-share group 2!cryptoisakmp client configuration group group1 key cisco poolezvpnpool acl 100!cryptoipsec transform-set set1 esp-des esp-md5-hmac!crypto dynamic-map dymap 1 set transform-set set1 reverse-route!crypto map vpnmap client authentication list ezvpnlogin crypto map vpnmapisakmp authorization list ezvpnauthor crypto map vpnmap client configuration address respond crypto map vpnmap 1 ipsec-isakmp dynamic dymap!!interface Ethernet0/0 noip address shutdown half-duplex!interface Ethernet0/1 ip address 192.168.2.2 255.255.255.0 ipnat outside ip virtual-reassembly half-duplex crypto map vpnmap!interface Ethernet0/2 noip address shutdown half-duplex!interface Ethernet0/3 ip address 192.168.200.1 255.255.255.0 ipnat inside ip virtual-reassembly half-duplex!ip local pool ezvpnpool 10.10.10.1 10.10.10.100 ip http server noip http secure-server!ip forward-protocol nd ip route 0.0.0.0 0.0.0.0 192.168.2.1!ipnat inside source list 111 interface Ethernet0/1 overload!access-list 1 permit any access-list 100 permit ip 192.168.200.0 0.0.0.255 any access-list 111 deny
ip 192.168.200.0 0.0.0.255 10.10.10.0 0.0.0.255 access-list 111 deny
ip 192.168.200.0 0.0.0.255 192.168.100.0 0.0.0.255 access-list 111 permit ip any any!!control-plane?。。。?!line con 0 exec-timeout 0 0 line aux 0 linevty 0 4!end
R3#
R1上的過(guò)程
提示輸入crypto ipsec client ezvpnxauth,并輸入用戶(hù)名和密碼,VPN則認(rèn)證成功。另外,cisco VPN Clint 支持Ezvpn client模式。
新建連接信息如下圖所示:
第五篇:電信寬帶限制路由器解決方案
電信寬帶限制路由器解決方案
由于廣州電信用寬帶都限制路由器共享,一般都只能共享2臺(tái)電腦,多于2臺(tái)有可能會(huì)被電信限制帶寬,經(jīng)常彈出寬帶共享提示等。而一般用寬帶共享4臺(tái)機(jī)以下都屬于正??山邮?chē)?,但部分客?hù)反應(yīng)里只使用了兩三臺(tái)電腦都會(huì)有共享提示,那怎么解決呢?解決方法一:不使用無(wú)線路由器WF上網(wǎng)。使用無(wú)線路由器容易被人“蹭網(wǎng)”,就算加密技術(shù)多好都有可能被人破解連網(wǎng),導(dǎo)致電信機(jī)房檢測(cè)共享增多而出現(xiàn)錯(cuò)誤。解決方法二:不啟用路由器內(nèi)置DHCP服務(wù),進(jìn)入路由器設(shè)置頁(yè)面,選擇不啟用,如下圖(各路由器頁(yè)面不同,但設(shè)置相似):然后進(jìn)入電腦控制面板,網(wǎng)絡(luò)連接,點(diǎn)本地連接——右鍵點(diǎn)——屬性,按下面設(shè)置:按以上設(shè)置好后重啟電腦、DE、路由器,最好等幾小時(shí)后再重新連線。解決辦法三:如果確實(shí)需要共享很多臺(tái)電腦,建議安裝商務(wù)寬帶,或者裝多幾條寬帶。目前廣州電信寬帶推出優(yōu)惠套餐——89元包月4,可以裝多幾臺(tái),具體套餐介紹可以本站聯(lián)系在線客服。