简单网络架构配置实验

1、环境描述

1)核心交换机S5700(华为)

2)接入交换机S3700(华为)

2、要求

1)不同vlan之间不能相互访问,每个vlan只能属于一个部门

2)部门1两台终端机配置分别如下

终端1:192.168.162.2/24 网关是:192.168.162.254

终端2:192.168.162.3/24 网关是:192.168.162.254

3)部门2两台终端机配置分别如下

终端1:192.168.163.2/24 网关是:192.168.163.254

终端2:192.168.163.3/24 网关是:192.168.163.254

3、核心交换机的基本配置如下:

[Huawei]di
[Huawei]display cur
[Huawei]display current-configuration
#
sysname Huawei
#
vlan batch 21 1602 to 1603
#
cluster enable
ntdp enable
ndp enable
#
drop illegal-mac alarm
#
diffserv domain default
#
acl number 3089
rule 0 permit ip destination 255.255.255.255 0
rule 1 permit ip source 192.168.162.0 0.0.0.255 destination 192.168.162.0 0.0.0
.255
rule 2 deny ip
acl number 3090
rule 0 permit ip destination 255.255.255.255 0
rule 1 permit ip source 192.168.163.0 0.0.0.255 destination 192.168.163.0 0.0.0.255
rule 2 deny ip
#
traffic classifier 1602 operator and
if-match acl 3089
#
traffic behavior 1602
permit
#
traffic policy 1602
classifier 1602 behavior 1602
#
drop-profile default
#
vlan 1602
traffic-policy 1602 inbound
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin
local-user admin password simple admin
local-user admin service-type http
#
interface Vlanif1
#
interface Vlanif21
#
interface Vlanif1602
ip address 192.168.162.254 255.255.255.0
#
interface Vlanif1603
ip address 192.168.163.254 255.255.255.0
#
interface MEth0/0/1
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
user-interface con 0
user-interface vty 0 4
#
return

4、接入交换机的基本配置

[Huawei]display c
[Huawei]display cur
[Huawei]display current-configuration
#
sysname Huawei
#
vlan batch 1602 to 1603
#
cluster enable
ntdp enable
ndp enable
#
drop illegal-mac alarm
#
diffserv domain default
#
drop-profile default
#
aaa
authentication-scheme default
authorization-scheme default
accounting-scheme default
domain default
domain default_admin

local-user admin password simple admin
local-user admin service-type http
#
interface Vlanif1
#
interface MEth0/0/1
#
interface Ethernet0/0/1
port link-type access
port default vlan 1602
#
interface Ethernet0/0/2
port link-type access
port default vlan 1602
#
interface Ethernet0/0/3
port link-type access
port default vlan 1603
#
interface Ethernet0/0/4
port link-type access
port default vlan 1603
#
interface Ethernet0/0/5
#
interface GigabitEthernet0/0/1
port link-type trunk
port trunk allow-pass vlan 2 to 4094
#
interface GigabitEthernet0/0/2
#
interface NULL0
#
user-interface con 0
user-interface vty 0 4
#
return

5、实验结果:

点赞