跨交换间不同VLAN通信
2012-06-27 12:44
162 查看
跨交换间不同VLAN通信
拓扑如下
在SW1增加VLAN30的网关即可
SW1配置文件
SW1#show run
Building configuration...
Current configuration : 1479 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname SW1
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/1
switchport access vlan 10
!
interface FastEthernet0/2
switchport access vlan 20
!
interface FastEthernet0/3
!
interface FastEthernet0/4
!
interface FastEthernet0/5
!
interface FastEthernet0/6
!
interface FastEthernet0/7
!
interface FastEthernet0/8
!
interface FastEthernet0/9
!
interface FastEthernet0/10
!
interface FastEthernet0/11
!
interface FastEthernet0/12
!
interface FastEthernet0/13
!
interface FastEthernet0/14
!
interface FastEthernet0/15
!
interface FastEthernet0/16
!
interface FastEthernet0/17
!
interface FastEthernet0/18
!
interface FastEthernet0/19
!
interface FastEthernet0/20
!
interface FastEthernet0/21
!
interface FastEthernet0/22
!
interface FastEthernet0/23
!
interface FastEthernet0/24
!
interface GigabitEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan10
ip address 192.168.1.1 255.255.255.0
!
interface Vlan20
ip address 192.168.2.1 255.255.255.0
!
interface Vlan30
ip address 192.168.3.2 255.255.255.0
!
router ospf 1
log-adjacency-changes
network 192.168.1.0 0.0.0.255 area 0
network 192.168.2.0 0.0.0.255 area 0
network 192.168.3.0 0.0.0.255 area 0
!
ip classless
!
!
!
!
!
!
!
line con 0
line vty 0 4
login
!
!
!
en
SW2 配置
SW2#show run
Building configuration...
Current configuration : 1282 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname SW2
!
!
!
!
!
!
!
!
!
!
!
!
no ip domain-lookup
!
!
!
!
!
!
interface FastEthernet0/1
switchport access vlan 30
!
interface FastEthernet0/2
!
interface FastEthernet0/3
!
interface FastEthernet0/4
!
interface FastEthernet0/5
!
interface FastEthernet0/6
!
interface FastEthernet0/7
!
interface FastEthernet0/8
!
interface FastEthernet0/9
!
interface FastEthernet0/10
!
interface FastEthernet0/11
!
interface FastEthernet0/12
!
interface FastEthernet0/13
!
interface FastEthernet0/14
!
interface FastEthernet0/15
!
interface FastEthernet0/16
!
interface FastEthernet0/17
!
interface FastEthernet0/18
!
interface FastEthernet0/19
!
interface FastEthernet0/20
!
interface FastEthernet0/21
!
interface FastEthernet0/22
!
interface FastEthernet0/23
!
interface FastEthernet0/24
!
interface GigabitEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan30
ip address 192.168.3.1 255.255.255.0
!
router ospf 1
log-adjacency-changes
network 192.168.3.0 0.0.0.255 area 0
!
ip classless
!
!
!
!
!
!
!
line con 0
line vty 0 4
login
!
!
!
end本文出自 “追风少年” 博客,请务必保留此出处http://angf2.blog.51cto.com/278451/910486
拓扑如下
在SW1增加VLAN30的网关即可
SW1配置文件
SW1#show run
Building configuration...
Current configuration : 1479 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname SW1
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
!
interface FastEthernet0/1
switchport access vlan 10
!
interface FastEthernet0/2
switchport access vlan 20
!
interface FastEthernet0/3
!
interface FastEthernet0/4
!
interface FastEthernet0/5
!
interface FastEthernet0/6
!
interface FastEthernet0/7
!
interface FastEthernet0/8
!
interface FastEthernet0/9
!
interface FastEthernet0/10
!
interface FastEthernet0/11
!
interface FastEthernet0/12
!
interface FastEthernet0/13
!
interface FastEthernet0/14
!
interface FastEthernet0/15
!
interface FastEthernet0/16
!
interface FastEthernet0/17
!
interface FastEthernet0/18
!
interface FastEthernet0/19
!
interface FastEthernet0/20
!
interface FastEthernet0/21
!
interface FastEthernet0/22
!
interface FastEthernet0/23
!
interface FastEthernet0/24
!
interface GigabitEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan10
ip address 192.168.1.1 255.255.255.0
!
interface Vlan20
ip address 192.168.2.1 255.255.255.0
!
interface Vlan30
ip address 192.168.3.2 255.255.255.0
!
router ospf 1
log-adjacency-changes
network 192.168.1.0 0.0.0.255 area 0
network 192.168.2.0 0.0.0.255 area 0
network 192.168.3.0 0.0.0.255 area 0
!
ip classless
!
!
!
!
!
!
!
line con 0
line vty 0 4
login
!
!
!
en
SW2 配置
SW2#show run
Building configuration...
Current configuration : 1282 bytes
!
version 12.2
no service timestamps log datetime msec
no service timestamps debug datetime msec
no service password-encryption
!
hostname SW2
!
!
!
!
!
!
!
!
!
!
!
!
no ip domain-lookup
!
!
!
!
!
!
interface FastEthernet0/1
switchport access vlan 30
!
interface FastEthernet0/2
!
interface FastEthernet0/3
!
interface FastEthernet0/4
!
interface FastEthernet0/5
!
interface FastEthernet0/6
!
interface FastEthernet0/7
!
interface FastEthernet0/8
!
interface FastEthernet0/9
!
interface FastEthernet0/10
!
interface FastEthernet0/11
!
interface FastEthernet0/12
!
interface FastEthernet0/13
!
interface FastEthernet0/14
!
interface FastEthernet0/15
!
interface FastEthernet0/16
!
interface FastEthernet0/17
!
interface FastEthernet0/18
!
interface FastEthernet0/19
!
interface FastEthernet0/20
!
interface FastEthernet0/21
!
interface FastEthernet0/22
!
interface FastEthernet0/23
!
interface FastEthernet0/24
!
interface GigabitEthernet0/1
switchport trunk encapsulation dot1q
switchport mode trunk
!
interface GigabitEthernet0/2
!
interface Vlan1
no ip address
shutdown
!
interface Vlan30
ip address 192.168.3.1 255.255.255.0
!
router ospf 1
log-adjacency-changes
network 192.168.3.0 0.0.0.255 area 0
!
ip classless
!
!
!
!
!
!
!
line con 0
line vty 0 4
login
!
!
!
end本文出自 “追风少年” 博客,请务必保留此出处http://angf2.blog.51cto.com/278451/910486
相关文章推荐
- 在一台三层交换上,通过配置dhcp和路由实现不同VLAN相互通信
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 配置在一台三层交换上,不同VLAN相互通信
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 三层交换不同VLAN间通信
- 不同VLAN之间相互通信的两种方式 (单臂路由、三层交换)
- 配置在一台三层交换上,不同VLAN相互通信 推荐
- 三层交换实现不同VLAN间的通信[神州数码设备]
- 不同VLAN之间相互通信的两种方式(方式二:三层交换)
- 不同VLAN之间相互通信的两种方式 (单臂路由、三层交换)
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 三层交换实现不同VLAN通信
- 不同VLAN之间相互通信的两种方式(单臂路由、三层交换)
- 三层交换实现不同VLAN之间的通信
- 三层交换实现不同VLAN之间的通信
- CCNP交换.三层交换路由 不同VLAN间通信
- 三层交换实现不同VLAN之间的通信 推荐
- 使用路由器实现不同VLAN间通信_路由交换