Switch A config
hostname
super password
#
radius scheme system
server-type huawei
primary authentication 127.0.0.1 1645
primary accounting 127.0.0.1 1646
user-name-format without-domain
domain system
radius-scheme system
access-limit disable
state active
idle-cut disable
domain default enable system
#
local-server nas-ip 127.0.0.1 key huawei
#
vlan 1
ip address 192.168.100.1 255.0.0.0
ip route-static (default gateway) 192.168.100.1
#
interface Aux0/0
#
interface Ethernet0/1
vlan :1
#
interface Ethernet0/2
vlan :2
#
interface Ethernet0/3
vlan :2
#
interface Ethernet0/4
vlan :2
#
interface Ethernet0/5
vlan :2
#
interface Ethernet0/6
vlan :2
#
interface Ethernet0/7
port link-type trunk
port trunk permit vlan: all dot1q: yes
interface Ethernet0/8
vlan :3
#
interface NULL0
#
#
user-interface aux 0
password
user-interface vty 0 4
password
return
Swtich B config
hostname
super password
#
radius scheme system
server-type huawei
primary authentication 127.0.0.1 1645
primary accounting 127.0.0.1 1646
user-name-format without-domain
domain system
radius-scheme system
access-limit disable
state active
idle-cut disable
domain default enable system
#
local-server nas-ip 127.0.0.1 key huawei
#
vlan 1
ip address 192.168.100.2 255.0.0.0
ip route-static (default gateway) 192.168.100.2
#
interface Aux0/0
#
interface Ethernet0/1
port link-type trunk
port trunk permit vlan: all dot1q: yes
interface Ethernet0/2
vlan :3
#
interface Ethernet0/3
vlan :3
#
interface Ethernet0/4
vlan :3
#
interface Ethernet0/5
vlan :3
#
interface Ethernet0/6
vlan :3
#
interface Ethernet0/7
vlan :3
#
interface Ethernet0/8
vlan :3
#
interface NULL0
#
#
user-interface aux 0
password
user-interface vty 0 4
password
return
PC A config
eth0 inet addr: 192.168.2.1 mask: 255.0.0.0
loopback inet addr: 127.0.0.1 mask: 255.0.0.0
[root@PCA root]# route
default gateway: 192.168.100.2
PC B config
eth0 inet addr: 192.168.1.2 mask: 255.0.0.0
loopback inet addr: 127.0.0.1 mask: 255.0.0.0
[root@PCB root]# route
default gateway: 192.168.100.1
|