实验拓扑
获取地址
项目连接
实验步骤
SW1
配置的接口
配置的DHCP
配置缺省路由
interface GigabitEthernet0/0/1 port link-type access port default vlan 10 interface GigabitEthernet0/0/2 port link-type trunk port trunk allow-pass vlan 2 to 4094 DHCP配置在交换机SW2上 1.dhcp enable 2.ip pool 1 network 192.168.1.0 mask 255.255.255.0 dns-list 192.168.4.1 gateway-list 192.168.1.254 3.vlan batch 10 20 4.int vlanif 10 ip address 192.168.1.254 255.255.255.0 dhcp select global 5.display ip pool
AR1
配置接口
配置nat
配置地址组
配置acl
进入端口使用acl
配置缺省路由
配置静态路由
acl number 2000 rule 5 permit source 192.168.0.0 0.0.255.255 nat address-group 1 202.1.1.3 202.1.1.5 interface GigabitEthernet0/0/0 ip address 192.168.3.2 255.255.255.0 interface GigabitEthernet0/0/1 ip address 202.1.1.1 255.255.255.0 nat outbound 2000 address-group 1 ip route 0.0.0.0 0.0.0.0 202.1.1.2 ip route 192.168.0.0 16 192.168.3.1 SW2 interface Vlanif1 interface Vlanif10 ip address 192.168.1.254 255.255.255.0 dhcp select global interface Vlanif20 ip address 192.168.2.254 255.255.255.0 dhcp select global interface Vlanif30 ip address 192.168.3.1 255.255.255.0 interface Vlanif40 ip address 192.168.4.254 255.255.255.0 interface MEth0/0/1 interface GigabitEthernet0/0/1 port link-type trunk port trunk allow-pass vlan 2 to 4094 interface GigabitEthernet0/0/2 port link-type access port default vlan 30 interface GigabitEthernet0/0/3 port link-type trunk port trunk allow-pass vlan 2 to 4094 interface GigabitEthernet0/0/4 port link-type access port default vlan 40 ip route-static 0.0.0.0 0.0.0.0 192.168.3.2
SW4
interface Vlanif10 ip address 202.1.1.2 255.255.255.0 interface Vlanif20 ip address 66.66.66.254 255.0.0.0 interface MEth0/0/1 interface GigabitEthernet0/0/1 port link-type access port default vlan 10 interface GigabitEthernet0/0/2 port link-type access port default vlan 20 ip route-static 202.1.1.0 24 66.66.66.254
sw3
interface GigabitEthernet0/0/1 port link-type access port default vlan 20 interface GigabitEthernet0/0/2 port link-type trunk port trunk allow-pass vlan 2 to 4094
DNS配置
DHCP 抓包
pc5 ping www.baicu.com
原文链接:https://blog.csdn.net/weixin_45640148/article/details/124871759
© 版权声明
声明📢本站内容均来自互联网,归原创作者所有,如有侵权必删除。
本站文章皆由CC-4.0协议发布,如无来源则为原创,转载请注明出处。
THE END