CCNP1--靜態綜合實驗

靜態綜合實驗圖如下:
在這裏插入圖片描述

具體實驗要求如下:
1. ISP路由上只能配置IP地址,不得再進行其他任何操作
2. ISP的直連網段已經被規定,其餘內網所有設備ip地址192.168.1.0/24劃分
3. R1-R4每臺設備存在兩個環回
4. P0/P1自動獲取IP地址
5. R1-R4均可ping通PC2
6. PC2可以通過域名www.baidu.com訪問HTTP服務器
7. PC2在TelnetR5的ip地址時,實際登錄到R1上
8. VLAN2的所在網段只有PC0不能訪問PC2

網絡組建步驟

  1. 拓撲規劃–IP地址的規劃
  2. 配置
    1)底層IP的配置
    2)路由- -全網可達
    3)策略
    4)測試
    5)優化
  3. 維護
  4. 升級

具體規劃與實現
根據拓撲圖和實驗要求,我將192.168.1.0/24劃分爲6個子網

  1. 第一個子網爲骨幹網,即每兩個路由器之間的IP地址,圖中骨幹網由6條鏈路構成,分別是:R1-R2R1-R3R2-R4R3-R4R4-R5兩條鏈路 共六條
  2. 第二個子網爲R1,該子網下根據題意還有兩個環回,故還要在子網基礎上再分爲2個子網
  3. 第三個子網爲R2,該子網下根據題意還有兩個環回,故還要在子網基礎上再分爲2個子網
  4. 第四個子網爲R3,該子網下根據題意還有兩個環回,故還要在子網基礎上再分爲2個子網
  5. 第五個子網爲R4,該子網下根據題意還有兩個環回,故還要在子網基礎上再分爲2個子網
  6. 第六個子網爲R5,該子網下根據題意還有兩個VLAN,故還要在子網基礎上再分爲2個子網

網段劃分:
在這裏插入圖片描述

圖中標識出具體網段:
在這裏插入圖片描述

具體配置:

  1. 配置內網VLAN部分,以及配置DHCP池塘
switch0

interface FastEthernet0/1
 switchport access vlan 2
 switchport mode access
interface FastEthernet0/2
 switchport access vlan 2
 switchport mode access
interface FastEthernet0/3
 switchport access vlan 3
 switchport mode access
interface FastEthernet0/24
 switchport mode trunk

R5

interface FastEthernet1/1
 no shutdown
interface FastEthernet1/1.1
 encapsulation dot1Q 2
 ip address 192.168.1.161 255.255.255.240
interface FastEthernet1/1.2
 encapsulation dot1Q 3
 ip address 192.168.1.177 255.255.255.240
ip dhcp pool v2
 network 192.168.1.160 255.255.255.240
 default-router 192.168.1.161
 dns-server 114.114.114.114
  1. 將內網的ip地址按照規劃的地址進行配置,然後將內網的四臺路由器:R1R2R3R4分別配置缺省路由,指向邊界路由器所在的方向
R1

ip route 0.0.0.0 0.0.0.0 192.168.1.2 
ip route 0.0.0.0 0.0.0.0 192.168.1.6 

R2

ip route 0.0.0.0 0.0.0.0 192.168.1.10

R3

ip route 0.0.0.0 0.0.0.0 192.168.1.14

R4- -浮動靜態路由

ip route 0.0.0.0 0.0.0.0 192.168.1.18
ip route 0.0.0.0 0.0.0.0 192.168.1.22 2
  1. 檢查內網路由器的缺省路由有沒有到不了路由或者通過缺省路由進行訪問不太合理的,再添加靜態路由進行補充
R1

ip route 192.168.1.64 255.255.255.224 192.168.1.2 
ip route 192.168.1.96 255.255.255.224 192.168.1.6 

R2

ip route 192.168.1.32 255.255.255.224 192.168.1.1 
ip route 192.168.1.4 255.255.255.252 192.168.1.1 
ip route 192.168.1.96 255.255.255.224 192.168.1.1 
ip route 192.168.1.96 255.255.255.224 192.168.1.10 

R3

ip route 192.168.1.32 255.255.255.224 192.168.1.5 
ip route 192.168.1.0 255.255.255.252 192.168.1.5 
ip route 192.168.1.64 255.255.255.224 192.168.1.5 
ip route 192.168.1.64 255.255.255.224 192.168.1.14 

R4

ip route 192.168.1.64 255.255.255.224 192.168.1.9 
ip route 192.168.1.0 255.255.255.252 192.168.1.9 
ip route 192.168.1.96 255.255.255.224 192.168.1.13 
ip route 192.168.1.4 255.255.255.252 192.168.1.13 
ip route 192.168.1.32 255.255.255.224 192.168.1.9 
ip route 192.168.1.32 255.255.255.224 192.168.1.13 


R5

ip route 192.168.1.0 255.255.255.0 192.168.1.17 
ip route 192.168.1.0 255.255.255.0 192.168.1.21 2
  1. 對存在路由黑洞隱患的路由器,在其上配置空接口防環路由
R1

ip route 192.168.1.32 255.255.255.224 Null0

R2

ip route 192.168.1.64 255.255.255.224 Null0 

R3

ip route 192.168.1.96 255.255.255.224 Null0 

R4

ip route 192.168.1.128 255.255.255.224 Null0 

R5

ip route 192.168.1.0 255.255.255.0 Null0 
  1. 邊界路由器訪問外網,在R5上配置缺省指向ISP並且配置地址轉換(NAT)
R5

ip route 0.0.0.0 0.0.0.0 12.1.1.2 
access-list 1 permit 192.168.1.0 0.0.0.255
ip nat inside source list 1 interface FastEthernet1/0 overload
interface FastEthernet 1/0
ip nat outside
interface FastEthernet 0/0
ip nat inside
interface FastEthernet 0/1
ip nat inside
interface FastEthernet 1/1.1
ip nat inside
interface FastEthernet 1/1.2
ip nat inside
  1. 在R5上對內網的HTTP服務器進行端口映射,因爲PC2只能訪問到邊界路由器的外部接口
R5

ip nat inside source static tcp 192.168.1.178 80 12.1.1.1 80 
  1. 在R1上開啓telnet,並且在R5上進行端口映射
R1

username ccnp privilege 15 secret 123456
line vty 0 4
login local

R5

ip nat inside source static tcp 192.168.1.33 23 12.1.1.1 23 
  1. 在R5上制定acl,禁止PC0訪問PC2,並調用在接口上
ip access-list extended ccnp
 deny ip host 192.168.1.162 any
 permit ip any any
interface FastEthernet 1/1.1
 ip access-group ccnp in
發佈了88 篇原創文章 · 獲贊 7 · 訪問量 4819
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章