请输入您要查询的百科知识:

 

词条 华为交换机配置模板
释义

说明:该模板只能满足华为接入层交换机所需的基本配置要求。

///////// 配置主机名、登录验证//////////////

system-view

sysname HuaWei_test

super password level 1 cipher 456123

super password level 2 cipher 456123

super password level 3 cipher 456123

user-interface console 0

authentication-mode password

set authentication password cipher 456123

user privilege level 1

quit

user-interface vty 0 4

authentication-mode password

set authentication password cipher 456123

user privilege level 1

quit

///////// 配置主机名、登录验证//////////////

/////////配置Vlan ////////////////

system-view

vlan batch 2 to 6 9

quit

///////// 配置Vlan ////////////////

///////// 配置管理地址 ////////////

system-view

undo interface Vlanif 1

int Vlanif 2

ip address 192.168.2.1 255.255.255.0

undo shutdown

qu

qu

///////// 配置管理地址 ////////////

/////////配置access端口//////////////

system-view

interface Ethernet0/0/6

undo port link-type

undo port trunk allow-pass vlan all

undo port default vlan

port link-type access

port default vlan 6

undo negotiation auto

speed 100

quit

/////////配置access端口//////////////

/////////配置Trunk端口//////////////

system-view

interface Ethernet0/0/6

undo port link-type

undo port trunk allow-pass vlan all

undo port default vlan

port link-type trunk

port trunk allow-pass vlan 2 to 3 6 7

quit

/////////配置Trunk端口//////////////

////////////////配置某一VLAN通过DHCP分配IP///////////////////

system-view

dhcp snooping enable

vlan 6

################## DHCPIP-MAC绑定#############################

dhcp snooping bind-table static ip-address 192.168.6.254 mac-address 0000-1111-1234 interface Ethernet 0/0/2

################## DHCPIP-MAC绑定#############################

dhcp snooping enable

dhcp snooping trusted interface GigabitEthernet 0/0/1

dhcp option82 insert enable interface Ethernet 0/0/2 to 0/0/3

quit

////////////////配置某一VLAN通过DHCP分配IP///////////////////

////////////////清除启动配置文件、存盘、重启///////////////////

reset saved-configuration

save

reboot

////////////////清除启动配置文件、存盘、重启///////////////////

随便看

 

百科全书收录4421916条中文百科知识,基本涵盖了大多数领域的百科知识,是一部内容开放、自由的电子版百科全书。

 

Copyright © 2004-2023 Cnenc.net All Rights Reserved
更新时间:2025/2/24 8:50:16