sys
sysname XXXXX
telnet server enable #打开telnet远程;
#删除默认虚拟VLAN;
interface Vlan-interface 1
undo dhcp client identifier
undo ip address dhcp-alloc
quit
undo interface Vlan-interface 1
#建立管理VLAN,将1-22端口加入指定业务VLAN;
vlan 2
vlan 941
port GigabitEthernet 1/0/1 to GigabitEthernet 1/0/22
quit
#给管理VLAN配置远程IP;
interface Vlan-interface 2
ip address 192.168.0.7 24
quit
#配置入口trunk和透传vlan;
interface GigabitEthernet 1/0/23
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
interface GigabitEthernet 1/0/24
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
interface GigabitEthernet 1/0/25
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
interface GigabitEthernet 1/0/26
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
interface GigabitEthernet 1/0/27
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
interface GigabitEthernet 1/0/28
port link-type trunk
port trunk permit vlan 2 941
undo port trunk permit vlan 1
quit
#指定路由;
ip route-static 0.0.0.0 0 192.168.77.1
password-control length 6 #密码长度;
#设置远程用户和密码;
line vty 0 4
user-role network-admin
user-role network-operator
set authentication password simple 123456789
quit
#保存退出;
save
y