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

[原创] 有牛人吗,帮忙看下我这个实验有啥问题?

[复制链接]
发表于 2013-4-4 22:55:24 | 显示全部楼层 |阅读模式
为啥vlan间ping不通啊?

要求:
1.        配置网络中的各台设备,包括设备名、特权模式密码、开启Telnet功能
2.        配置VLAN、Trunk、RIP路由,实现全网互通
3.        配置ACL,允许vlan10用户访问FTP服务器,不允许vlan20用户访问.

如上图所示:
A.        各接口连线如上图所示
其中PC1和PC 4和FTPserver用桥接PC,PC2,3用虚拟PC模拟

B.各接口IP地址规划方案:
交换机名称        F0/0接口地址|vlan        F0/1接口地址/vlan        F0/2接口地址/vlan        F0/3接口地址/vlan
SW1        192.1.1.10/24 |10        无        192.1.2.10/24 |20        无
SW2        192.1.3.10/24        无        192.1.1.20/24 |10        192.1.2.20/24 |20

交换机名称        F0/0接口地址        F1/0接口地址
R1        192.1.5.1/24        192.1.4.20/24
R2        192.1.3.20/24        192.1.4.10/24
C.vlan IP地址
vlan名称        网关IP
Vlan10        192.1.1.1/24
Vlan20        192.1.2.1/24


C.虚拟PC IP地址
PC1:192.1.1.10/24  GW:192.1.1.1
PC2:192.1.2.10/24  GW:192.1.2.1
PC3:192.1.1.20/24  GW:192.1.1.1
PC4:192.1.2.20/24  GW:192.1.2.1
FTPserver:2.1.5.10/24  GW:2.1.5.1

1.配置网络中的各台设备,包括设备名、特权模式密码、开启Telnet功能

SW1:
en
conf t
no ip domain lookup
line console 0
exec-t 0 0
logg sync
exit
ho SW1
enable secret cisco
end
conf t
line vty 0 3
password cisco
login
exit
do show running-config

SW2:
en
conf t
no ip domain lookup
line console 0
exec-t 0 0
logg sync
exit
ho SW2
enable secret cisco
exit
show running-config

R1:
en
conf t
no ip domain lookup
line console 0
exec-t 0 0
logg sync
exit
ho R1
enable secret cisco
end
conf t
line vty 0 3
password cisco
login
exit
do show running-config

R2:
en
conf t
no ip domain lookup
line console 0
exec-t 0 0
logg sync
exit
ho R2
enable secret cisco
end
conf t
line vty 0 3
password cisco
login
exit
do show running-config

2.vlan间通信

SW1:
end
conf t
int f0/1
switchport mode trunk
end
show int f0/1 switchport

vlan database
vlan 10
vlan 20
exit
conf t
no ip routing
int f0/2
switchport mode access
switchport access vlan 10
spanning-tree portfast
no cdp enable
exit
int f0/3
switchport mode access
switchport access vlan 20
spanning-tree portfast
no cdp enable
exit

show vlan-sw b

SW2:
end
conf t
int f0/1
switchport mode trunk
end
show int f0/1 switchport
vlan database
vlan 10
vlan 20
exit
conf t
no ip routing
int f0/0
switchport mode access
switchport access vlan 10
spanning-tree portfast
no cdp enable
exit
int f0/2
switchport mode access
switchport access vlan 20
no cdp enable
exit
show vlan-sw b

验证vlan内通信
PC1能ping通PC3,PC2能ping通PC4.
SW1:
end
conf t
ip routing
int vlan 10
ip address 192.1.1.1 255.255.255.0
no shutdown
exit
int vlan 20
ip address 192.1.2.1 255.255.255.0
no shutdown
exit
show ip int brief

验证vlan间通信:
PC1,2,3,4能互相ping通.
3.配置各设备端口IP

SW1:
end
conf t
int f0/0
ip address 192.1.3.10 255.255.255.0
full
no shutdown
exit
do sh ip int b

R1:
end
conf t
int f0/0
ip address 192.1.5.1 255.255.255.0
full
no shutdown
exit
int f1/0
ip address 192.1.4.20 255.255.255.0
full
no shutdown
exit
do sh ip int b

R2:
end
conf t
int f0/0
ip address 192.1.3.20 255.255.255.0
full
no shutdown
exit
int f1/0
ip address 192.1.4.10 255.255.255.0
full
no shutdown
exit
do sh ip int b
4.配置RIP,确保全网互通
SW1:
end
conf t
router rip
network 192.1.3.0
exit
do sh ip route
R1:
end
conf t
router rip
network 192.1.4.0
network 192.1.5.0
exit
do sh ip route
R2:
end
conf t
router rip
network 192.1.3.0
network 192.1.4.0
exit
do sh ip route
5. FTPserver服务器允许vlan10用户访问,禁止vlan20用户访问。
R1:
end
conf t
ip access-list extended R1
deny ip 192.1.2.0 0.0.0.255 192.1.5.0 0.0.0.255
permit ip 192.1.1.0 0.0.0.255 any
exit
int f0/0
ip access-group R1 out
exit
do sh ip int f0/0
do sh access-list
do wr

配置图

配置图
发表于 2013-4-4 23:10:01 | 显示全部楼层
这个 想要在vlan间通信 要么起单臂路由 要么开三层交换 根据LZ配置显然什么都没有 如何能vlan间通信?要在SW1和SW2上配置SVI起三层交换 或者在R2上做单臂路由
沙发 2013-4-4 23:10:01 回复 收起回复
回复 支持 反对

使用道具 举报

发表于 2013-4-4 23:18:30 | 显示全部楼层
我现在估计你3 4能互通 但是1 2 或则1 4不能互通 SW2上也要起iprouting 还有SW1和SW2之间的trunk有没有允许vlan 10 20?
板凳 2013-4-4 23:18:30 回复 收起回复
回复 支持 反对

使用道具 举报

发表于 2013-4-4 23:23:06 | 显示全部楼层
单臂路由 或者三层交换机 ip routing  Vlan间通信
地板 2013-4-4 23:23:06 回复 收起回复
回复 支持 反对

使用道具 举报

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

本版积分规则

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

GMT+8, 2025-2-24 13:33 , Processed in 0.067210 second(s), 25 queries , Redis On.  

  Powered by Discuz!

  © 2001-2025 HH010.COM

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