cisco中的VLAN转发

网络工程 思科 路由 转变 局域网 顺式催化剂
2022-02-05 16:34:26

我们有一个 Cisco 3750X (L3) 作为核心交换机和 10 个 Cisco SG-300 (L2),每个交换机都在一个单独的 VLAN 中(包括核心交换机)现在我想在我的核心交换机上定义 VLAN 转发规则,所以所有客户端可以看到服务器,我该怎么做?

**3750X license:**
{Index 1 Feature: ipservices
        Period left: 8  weeks 4  days
        License Type: Evaluation
        License State: Active, Not in Use, EULA not accepted
        License Priority: None
        License Count: Non-Counted

Index 2 Feature: ipbase
        Period left: Life time
        License Type: Permanent
        License State: Active, In Use
        License Priority: Medium
        License Count: Non-Counted

Index 3 Feature: lanbase
        Period left: 0  minute  0  second}

**running config:**
{version 15.0
no service pad
service timestamps debug datetime msec
service timestamps log datetime msec
no service password-encryption
!
hostname ****
!
boot-start-marker
boot-end-marker
!
enable secret 5 ****************
enable password ****************
!
username ******* password ********
no aaa new-model
switch 1 provision ws-c3750x-24
system mtu routing 1500
!
!
ip domain-name *******
!
!
crypto pki trustpoint TP-self-signed-********2
 enrollment selfsigned
 subject-name cn=IOS-Self-Signed-Certificate-******2
 revocation-check none
 rsakeypair TP-self-signed-*******2
!
!
crypto pki certificate chain TP-self-signed-********2
 certificate self-signed 01
  ***************************************************
*****************************************************
*****************************************************
!
!
!
spanning-tree mode pvst
spanning-tree extend system-id
!
!
!
!
!
!
!
!
!
vlan internal allocation policy ascending
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0
 no ip address
 shutdown
!
interface GigabitEthernet1/0/1
!
interface GigabitEthernet1/0/2
!
interface GigabitEthernet1/0/3
!
interface GigabitEthernet1/0/4
!
interface GigabitEthernet1/0/5
!
interface GigabitEthernet1/0/6
!
interface GigabitEthernet1/0/7
!
interface GigabitEthernet1/0/8
!
interface GigabitEthernet1/0/9
!
interface GigabitEthernet1/0/10
!
interface GigabitEthernet1/0/11
!
interface GigabitEthernet1/0/12
!
interface GigabitEthernet1/0/13
!
interface GigabitEthernet1/0/14
!
interface GigabitEthernet1/0/15
!
interface GigabitEthernet1/0/16
!
interface GigabitEthernet1/0/17
!
interface GigabitEthernet1/0/18
!
interface GigabitEthernet1/0/19
!
interface GigabitEthernet1/0/20
!
interface GigabitEthernet1/0/21
!
interface GigabitEthernet1/0/22
!
interface GigabitEthernet1/0/23
!
interface GigabitEthernet1/0/24
!
interface GigabitEthernet1/1/1
!
interface GigabitEthernet1/1/2
!
interface GigabitEthernet1/1/3
!
interface GigabitEthernet1/1/4
!
interface TenGigabitEthernet1/1/1
!
interface TenGigabitEthernet1/1/2
!
interface Vlan1
 ip address 192.168.0.31 255.255.255.0
!
interface Vlan10
 ip address 10.0.1.1 255.255.255.224
!
interface Vlan20
 ip address 10.0.2.1 255.255.255.224
!
interface Vlan30
 ip address 10.0.3.1 255.255.255.224
!
interface Vlan40
 ip address 10.0.4.1 255.255.255.224
!
interface Vlan50
 ip address 10.0.5.1 255.255.255.224
!
interface Vlan60
 ip address 10.0.6.1 255.255.255.224
!
interface Vlan70
 ip address 10.0.7.1 255.255.255.240
!
interface Vlan80
 ip address 10.0.8.1 255.255.255.248
!
interface Vlan90
 ip address 10.0.9.1 255.255.255.224
!
interface Vlan100
 ip address 10.0.10.1 255.255.255.224
!
interface Vlan110
 ip address 10.0.11.1 255.255.255.224
!
interface Vlan200
 ip address 10.0.20.1 255.255.255.224
!
ip default-gateway 10.0.20.20
ip http server
ip http secure-server
!
!
!
snmp-server community public RO
!
!
line con *
line vty * *
 password ********
 login local
 transport input ssh
line vty * *
 password ********
 login local
 transport input ssh
!
end}
2个回答

ip routing您必须使用global 命令启用路由。

如果启用了路由,它只是一个第 3 层交换机。您实际上将它用作第 2 层交换机。

根据提供的配置,很明显,交换机虚拟接口 (SVI) 在 Cisco 3750 交换机中配置,并进一步连接所有第 2 层交换机 coreswitch 允许 coreswitch 和访问交换机之间的中继端口允许所有 Vlan

现在不同的Vlan通信流量到达coreswitch。通过启用 VLAN 间路由,可以在不同 Vlan 之间启用路由。根据我们的要求,可以通过访问列表配置限制或允许 VLAN 之间的 VLAN 流量。