華為交換機配置模板

基本介紹

  • 中文名:華為交換機配置模板
  • 類型:模板
  • 對象:華為接入層交換機
  • 國家:中國
說明,配置,

說明

該模板只能滿足華為接入層交換機所需的基本配置要求。
配置主機名、登錄驗證
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 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
reboot
////////////////清除啟動配置檔案、重啟///////////////////

相關詞條

熱門詞條

聯絡我們