思科交换机配置指令
指令 |
简写 |
功能 |
enable |
en |
进入特权模式 |
configure terminal |
config t |
配置模式 |
hostname xxxx |
ho xxx |
交换机命名 |
interface f0/0 |
int f0/0 |
f0/0 接口配置模式 |
no shutdown |
n sh |
开启端口 |
exit |
ex |
退出 |
0x01配置使能密码
switch> en
switch# config t
switch(conf)# ho xxx
xxx(conf)#enable password cisco
0x02配置vlan
Switch>en
Switch#config t
Enter configuration commands, one per line. End with CNTL/Z.
Switch(config)#vlan 2
Switch(config-vlan)#ex
Switch(config)#int rang fastEthernet 0/13 - 24
Switch(config-if-range)#switchport access vlan 2
Switch(config-if-range)#ex
Switch(config)#ex
Switch#
%SYS-5-CONFIG_I: Configured from console by console
Switch#show vlan
VLAN Name Status Ports
---- -------------------------------- --------- -------------------------------
1 default active Fa0/1, Fa0/2, Fa0/3, Fa0/4
Fa0/5, Fa0/6, Fa0/7, Fa0/8
Fa0/9, Fa0/10, Fa0/11, Fa0/12
2 VLAN0002 active Fa0/13, Fa0/14, Fa0/15, Fa0/16