假设现在有3个VLAN分别为10 20 30,给用户使用
1.创建vlanif接口
interface vlan 10
ip add 192.168.10.1 24
interface vlan 20
ip add 192.168.20.1 24
interface vlan 30
ip add 192.168.30.1 24
2.创建dhcp地址池
dhcp server ip-pool vlan10
network 192.168.10.0 mask 255.255.255.0
gateway 192.168.10.1
dns 223.5.5.5
VLAN20 30的地址池同上
创建VLAN100用于和路由器互联
interface vlan 100
ip add 192.168.100.2 24
静态路由指向路由器
ip route-static 0.0.0.0 0 192.168.100.1
路由器配置
1.配置内网接口192.168.100.1/255.255.255.0
2.配置静态路由
192.168.10.0 255.255.255.0 192.168.100.2
192.168.20.0 255.255.255.0 192.168.100.2
192.168.30.0 255.255.255.0 192.168.100.2
暂无评论