设为首页收藏本站language 语言切换
查看: 2509|回复: 7
收起左侧

[已解决] 模拟器练习,3层交换机运行DHCP Server,划分3个VLAN。vlan之间不能互访,可上网

[复制链接]
发表于 2016-11-3 00:21:05 | 显示全部楼层 |阅读模式
3鸿鹄币
  技术小白。看了很多前辈的资料,自己也画了个简单的拓扑,总算成功了。大家看看对不对。
捕获2.JPG






规划:

1:2811路由器一台

2:下级联Cisco 3560 交换机(需分2个Vlan,开启DHCPServer)PC端自动获取IP地址

3:vlan之间不能互访。但可同时上网。

==============================================
路由器接口配置
interface FastEthernet0/0
no ip address
duplex auto
speed auto
!
interface FastEthernet0/0.1
encapsulation dot1Q 2
ip address 192.168.1.1 255.255.255.0
!
interface FastEthernet0/0.2
description for internet
encapsulation dot1Q 3
ip address 10.10.10.1 255.255.255.0
!


=================================================
交换机配置

DHCP配置
ip dhcp pool DHCPServer1
network 192.168.1.0 255.255.255.0
default-router 192.168.1.1
dns-server 192.168.1.1
ip dhcp pool DHCPServer-2
network 10.10.10.0 255.255.255.0
default-router 10.10.10.1
dns-server 10.10.10.1


VLAN 配置
interface Vlan201
description for PC
ip address 192.168.1.1 255.255.255.0
!
interface Vlan301
description for IT
ip address 10.10.10.1 255.255.255.0
!


VLAN 配置
201  VLAN0201                         active    Fa0/1, Fa0/2, Fa0/3, Fa0/4
                                                Fa0/5, Fa0/6, Fa0/7, Fa0/8
                                                Fa0/9
301  IT                               active    Fa0/11, Fa0/12, Fa0/13, Fa0/14
                                                Fa0/15, Fa0/16, Fa0/17, Fa0/18
                                                Fa0/19, Fa0/20, Fa0/21, Fa0/22
                                                Fa0/23, Fa0/24


最佳答案

查看完整内容

interface FastEthernet0/0.1 encapsulation dot1Q 2 ip address 192.168.1.1 255.255.255.0 ! interface FastEthernet0/0.2 description for internet encapsulation dot1Q 3 ip address 10.10.10.1 255.255.255.0 ! VLAN 配置 interface Vlan201 description for PC ip address 192.168.1.1 255.255.255.0 ! interface Vlan301 description for IT ip address 10.10.10.1 255.255.255.0 ! VLAN 配置 201 ...
发表于 2016-11-3 00:21:06 | 显示全部楼层
interface FastEthernet0/0.1
encapsulation dot1Q 2
ip address 192.168.1.1 255.255.255.0
!
interface FastEthernet0/0.2
description for internet
encapsulation dot1Q 3
ip address 10.10.10.1 255.255.255.0
!
VLAN 配置
interface Vlan201
description for PC
ip address 192.168.1.1 255.255.255.0
!
interface Vlan301
description for IT
ip address 10.10.10.1 255.255.255.0
!


VLAN 配置
201  VLAN0201                         active    Fa0/1, Fa0/2, Fa0/3, Fa0/4
                                                Fa0/5, Fa0/6, Fa0/7, Fa0/8
                                                Fa0/9
301  IT                               active    Fa0/11, Fa0/12, Fa0/13, Fa0/14
                                                Fa0/15, Fa0/16, Fa0/17, Fa0/18
                                                Fa0/19, Fa0/20, Fa0/21, Fa0/22
                                                Fa0/23, Fa0/24

红色的vlan要相同,路由器和交换机之间要配trunk
沙发 2016-11-3 00:21:06 回复 收起回复
回复

使用道具 举报

发表于 2016-11-3 07:47:47 | 显示全部楼层
板凳 2016-11-3 07:47:47 回复 收起回复
回复

使用道具 举报

发表于 2016-11-3 15:01:23 | 显示全部楼层
感谢楼主分享!
地板 2016-11-3 15:01:23 回复 收起回复
回复

使用道具 举报

 楼主| 发表于 2016-11-3 21:50:24 | 显示全部楼层
shenxian 发表于 2016-11-3 18:26
interface FastEthernet0/0.1
encapsulation dot1Q 2
ip address 192.168.1.1 255.255.255.0

前辈意思是说路由器的F0/0.1和f0/0.2也需要配置vlan201和301么?
5# 2016-11-3 21:50:24 回复 收起回复
回复

使用道具 举报

 楼主| 发表于 2016-11-3 21:50:46 | 显示全部楼层
本帖最后由 xlzcjj 于 2016-11-3 21:53 编辑
shenxian 发表于 2016-11-3 18:26
interface FastEthernet0/0.1
encapsulation dot1Q 2
ip address 192.168.1.1 255.255.255.0

前辈意思是说路由器的F0/0.1和f0/0.2也需要配置vlan201和301么?

trunk口在这里

interface FastEthernet0/10
switchport mode trunk

6# 2016-11-3 21:50:46 回复 收起回复
回复

使用道具 举报

 楼主| 发表于 2016-11-3 21:57:07 | 显示全部楼层
解决了哇
7# 2016-11-3 21:57:07 回复 收起回复
回复

使用道具 举报

发表于 2016-11-7 23:16:48 | 显示全部楼层
感觉你配置了单臂路由 又配置了三层路由 感觉可以设置单臂路由  不同van 获取不同地址的地址,用访问控制列表限制VLAN不可以互相访问 . 说的可能不对 但是我感觉这样配置好一些
8# 2016-11-7 23:16:48 回复 收起回复
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 论坛注册

本版积分规则

QQ|Archiver|手机版|小黑屋|sitemap|鸿鹄论坛 ( 京ICP备14027439号 )  

GMT+8, 2025-2-8 02:48 , Processed in 0.068083 second(s), 14 queries , Redis On.  

  Powered by Discuz!

  © 2001-2025 HH010.COM

快速回复 返回顶部 返回列表