取消
显示结果 
搜索替代 
您的意思是: 
cancel
10849
查看次数
0
有帮助
11
回复

3750交换机双线接入问题

yafun
Level 1
Level 1
各位好,刚入论坛,有个问题请教,我有一台3750三层交换机,划分多个vlan,gi1/0/1和gi1/0/2分别接两台防火墙(移动和电信),我想让其中的一个vlan20上网走移动的线路,其他vlan都是默认走电信的线路,我的gi1/0/1端口ip为192.168.1.1,gi1/0/2的端口ip为192.168.2.1,gi1/0/1对端防火墙的ip是192.168.1.10,gi1/0/2对端防火墙的ip是192.168.2.10,请教我该如何设置才能达到上述要求。谢谢!
11 条回复11

one-time
Level 13
Level 13
感谢您的提问,会有小伙伴为您解答的!:):handshake

yafun
Level 1
Level 1
我的三层上的部分配置如下:
interface GigabitEthernet1/0/1
no switchport
ip address 192.168.1.1 255.255.255.192
!
interface GigabitEthernet1/0/2
no switchport
ip address 192.168.2.1 255.255.255.192
!
省略
interface Vlan20
ip address 192.168.6.65 255.255.255.192
ip policy route-map yidong

省略
ip route 0.0.0.0 0.0.0.0 192.168.1.10
ip route 0.0.0.0 0.0.0.0 192.168.2.10
省略
access-list 10 permit 192.168.6.64 0.0.0.63
省略
!
route-map yidong permit 10
match ip address 10
set ip next-hop 192.168.2.10
!
!
end
先我在vlan20上应用ip policy route-map yidong这个语句,vlan20的内外都不能访问了,这是何原因,我该符合修改我的配置。谢谢

yafun
Level 1
Level 1
我的3750的版本:Cisco IOS Software, C3750 Software (C3750-ADVIPSERVICESK9-M), Version 12.2(35)SE5, RELEASE SOFTWARE (fc1)

huoran1234
Spotlight
Spotlight
听需求应该是使用PBR实现,先用ACL匹配vlan20的流量,然后放到route-map里,set next-hop 移动的防火墙互联地址。然后再调用到vlan 20的SVI上,其他的流量就用默认路由就好了。
我记得3750如果要启用PBR的话,如果是3750-X是有license要求的,而且还需要启用sdm prefer routing。

Mansur
Spotlight
Spotlight
这就看你的三层交换能不能支持PBR,不然只能用这个交换机做二层隔离,网关放到防火墙:)

yafun
Level 1
Level 1
各位好,sdm prefer routing这我已启用了
show sdm prefer
The current template is "desktop IPv4 and IPv6 routing" template.
The selected template optimizes the resources in
the switch to support this level of features for
8 routed interfaces and 1024 VLANs.
number of unicast mac addresses: 1.5K
number of IPv4 IGMP groups + multicast routes: 1K
number of IPv4 unicast routes: 2.75K
number of directly-connected IPv4 hosts: 1.5K
number of indirect IPv4 routes: 1.25K
number of IPv6 multicast groups: 1K
number of directly-connected IPv6 addresses: 1.5K
number of indirect IPv6 unicast routes: 1.25K
number of IPv4 policy based routing aces: 0.25K
number of IPv4/MAC qos aces: 0.5K
number of IPv4/MAC security aces: 0.5K
number of IPv6 policy based routing aces: 0.25K
number of IPv6 qos aces: 0.5K
number of IPv6 security aces: 0.5K

On next reload, template will be "desktop routing" template.
还请各位多多帮助,谢谢!

Mansur
Spotlight
Spotlight
yafun 发表于 2016-11-4 11:49 back.gif
各位好,sdm prefer routing这我已启用了
show sdm prefer
The current template is "desktop IPv4 and ...

ip route 0.0.0.0 0.0.0.0 192.168.2.10//删除这条,不然影响其他vlan选路,PBR优先级是高于路由表的
内网不通问题,你可以思考下,你是不是吧vlan20所有的流量的下一跳都指到移动防火墙了。
所以,需要修改下acl(假设你的内网其他vlan都是192.168.0.0/16)
access-list 100 deny ip 192.168.6.64 0.0.0.63 192.168.0.0 0.0.255.255 //内网流量选路不被route-map影响,走本地路由表
access-list 100 permit ip 192.168.6.64 0.0.0.63 any
外网不通问题,你看看是不是移动的防火墙是不是没写vlan20回来的路由

yafun
Level 1
Level 1
maguanghua2013 发表于 2016-11-4 12:21 back.gif
ip route 0.0.0.0 0.0.0.0 192.168.2.10//删除这条,不然影响其他vlan选路,PBR优先级是高于路由表的
...

谢谢,我等会试试。

yafun
Level 1
Level 1
maguanghua2013 发表于 2016-11-4 12:21 back.gif
ip route 0.0.0.0 0.0.0.0 192.168.2.10//删除这条,不然影响其他vlan选路,PBR优先级是高于路由表的
...

我的两台防火墙的路由是这么写的,电信的防火墙的路由是:192.168.0.0/255.255.192.0 192.168.1.1,移动的线路防火墙的路由是192.168.6.64/255.255.255.192 192.168.2.1,这么写对吗?谢谢

Mansur
Spotlight
Spotlight
yafun 发表于 2016-11-4 12:36 back.gif
我的两台防火墙的路由是这么写的,电信的防火墙的路由是:192.168.0.0/255.255.192.0 192.168.1.1,移动的 ...

嗯,可以啊,只要去往内网的流量到达这个防火墙的时候,路由表能查到就行

aisike
Spotlight
Spotlight
谢谢楼主,支持分享
入门指南

使用上面的搜索栏输入关键字、短语或问题,搜索问题的答案。

我们希望您在这里的旅程尽可能顺利,因此这里有一些链接可以帮助您快速熟悉思科社区:









快捷链接