CISCO基本命令集.docx

上传人:b****5 文档编号:4568772 上传时间:2022-12-06 格式:DOCX 页数:16 大小:22.92KB
下载 相关 举报
CISCO基本命令集.docx_第1页
第1页 / 共16页
CISCO基本命令集.docx_第2页
第2页 / 共16页
CISCO基本命令集.docx_第3页
第3页 / 共16页
CISCO基本命令集.docx_第4页
第4页 / 共16页
CISCO基本命令集.docx_第5页
第5页 / 共16页
点击查看更多>>
下载资源
资源描述

CISCO基本命令集.docx

《CISCO基本命令集.docx》由会员分享,可在线阅读,更多相关《CISCO基本命令集.docx(16页珍藏版)》请在冰豆网上搜索。

CISCO基本命令集.docx

CISCO基本命令集

CISCO基本命令集

showprotocols

showmem

showiproute

showstartup-config

showrunning-config

showflash

showinterfaces

二、基本路由配置命令

进入:

configterminal/memory/network

配置网络时常采用的命令:

copy和load

1.标识:

hostname标识名

2.启动标识:

banner启动标识

3.接口:

interface端口号

4.密码:

line06

login

passwd口令

enablepassword/secret口令

5.接口:

1)配置端口

interface端口号

clockrate时钟速率(64000)/*在串口中配置*/

bandwidth带宽(缺省56)/*在串口中配置*/

media-type介质类型/*在以太网口上*/

early-tokenrelease/*在令牌环网口上*/

ring-speed16/*在令牌环网口上*/

noshutdown

writememory

2)检验端口

showinterfaces

showcontrollers

6.配置环境

1)引导方式

bootsystemflashIOS-filename

bootsystemtftpIOS-filenametftp-address

bootsystemrom

2)配置Register值

config-register0x2102

7.查看邻居路由

showcdpinterface

showcdpneighbors[detail]

showcdpentryrouterA

8.IPAddress配置

Ipaddress网络地址掩码

Iphost主机名address

Ipname-se

rver服务器地址1服务器地址2。

Ipdomain-lookupnsap

Showhosts

Ping主机名/IP地址

Trace主机名/IP地址

三、IP路由

1.静态路由

iprouting

iproute目标网络号掩码端口号[permanent]

2.缺省路由

ipdefault-network网络号

3.动态路由

1)RIP配置

Routerrip

Network网络号

Showiproute

Showipprotocol

Debugip

2)OSPF配置

Routerospf进程号

Redistribute其它路由协议

Network端口网络反掩码area区域号

Area区域号range网络号掩码

Area区域号default-cost花销值

Ipospfprioritynumber

Ipospfcost花销值

Showipospfdatabase

3)BGP配置

Routerbgp自治域号

Redistribute其它路由协议

Network网络号/*自治域内*/

Aggregate-address网络号掩码summary-only汇总网络

Neighbor相邻网络号remote-as自治域号/*自治域间的网络*/

四、流量控制

1)被动端口

passiveinterface端口号

2)缺省路由

ipdefault网络号/端口网络

3)静态路由

iproute目标网络号掩码端口号

4)ACL过滤表

(全局上)access-list访问号1{permit|deny}反掩码号[established]

access-list访问号2{permit|deny}IP/TCP协议源网络目的

网络

操作符参数

(端口上)access-group访问号in|out

distribute-list访问号in|out端口号

4)Null0interface

Iprouteaddressmasknull0

五、广义网配置

1)PPP

Ppppapsent-usename封装

Pppchaphostname

Pppchappassword

2)X.25

encapsulationx25[dce]

x25address

x25map协议地址/*SVC*/

x25pvcpvc号ip地址x25地址/*PVC*/

ipswitching

x25routex.121地址接口x.121映射地址

2)FrameRelay

Frame-relaylocal-dlciIP网络号

Frame-relaymap协议地址

Frame-relaylmi-typeansi

交换机命令全集

1.在基于IOS的交换机上设置主机名/系统名:

switch(config)#hostnamehostname

在基于CLI的交换机上设置主机名/系统名:

switch(enable)setsystemnamename-string

2.在基于IOS的交换机上设置登录口令:

switch(config)#enablepasswordlevel1password

在基于CLI的交换机上设置登录口令:

switch(enable)setpassword

switch(enable)setenalbepass

3.在基于IOS的交换机上设置远程访问:

switch(config)#interfacevlan1

switch(config-if)#ipaddressip-addressnetmask

switch(config-if)#ipdefault-gatewayip-address

在基于CLI的交换机上设置远程访问:

switch(enable)setinterfacesc0ip-addressnetmaskbroadcast-address

switch(enable)setinterfacesc0vlan

switch(enable)setiproutedefaultgateway

4.在基于IOS的交换机上启用和浏览CDP信息:

switch(config-if)#cdpenable

switch(config-if)#nocdpenable

为了查看Cisco邻接设备的CDP通告信息:

switch#showcdpinterface[typemodle/port]

switch#showcdpneighbors[typemodule/port][detail]

在基于CLI的交换机上启用和浏览CDP信息:

switch(enable)setcdp{enable|disable}module/port

为了查看Cisco邻接设备的CDP通告信息:

switch(enable)showcdpneighbors[module/port][vlan|duplex|capabilities|detail]

5.基于IOS的交换机的端口描述:

switch(config-if)#descriptiondescription-string

基于CLI的交换机的端口描述:

switch(enable)setportnamemodule/numberdescription-string

6.在基于IOS的交换机上设置端口速度:

switch(config-if)#speed{10|100|auto}

在基于CLI的交换机上设置端口速度:

switch(enable)setportspeedmoudle/number{10|100|auto}

switch(enable)setportspeedmoudle/number{4|16|auto}

7.在基于IOS的交换机上设置以太网的链路模式:

switch(config-if)#duplex{auto|full|half}

在基于CLI的交换机上设置以太网的链路模式:

switch(enable)setportduplexmodule/number{full|half}

8.在基于IOS的交换机上配置静态VLAN:

switch#vlandatabase

switch(vlan)#vlanvlan-numnamevla

switch(vlan)#exit

switch#configureteriminal

switch(config)#interfaceinterfacemodule/number

switch(config-if)#switchportmodeaccess

switch(config-if)#switchportaccessvlanvlan-num

switch(config-if)#end

在基于CLI的交换机上配置静态VLAN:

switch(enable)setvlanvlan-num[namename]

switch(enable)setvlanvlan-nummod-num/port-list

9.在基于IOS的交换机上配置VLAN中继线:

switch(config)#interfaceinterfacemod/port

switch(config-if)#switchportmodetrunk

switch(config-if)#switchporttrunkencapsulation{isl|dotlq}

switch(config-if)#switchporttrunkallowedvlanremovevlan-list

switch(config-if)#switchporttrunkallowedvlanaddvlan-list

在基于CLI的交换机上配置VLAN中继线:

switch(enable)settrunkmodule/port[on|off|desirable|auto|nonegotiate]

Vlan-range[isl|dotlq|dotl0|lane|negotiate]

10.在基于IOS的交换机上配置VTP管理域:

switch#vlandatabase

switch(vlan)#vtpdomaindomain-name

在基于CLI的交换机上配置VTP管理域:

switch(enable)setvtp[domaindomain-name]

11.在基于IOS的交换机上配置VTP模式:

switch#vlandatabase

switch(vlan)#vtpdomaindomain-name

switch(vlan)#vtp{sever|cilent|transparent}

switch(vlan)#vtppasswordpassword

在基于CLI的交换机上配置VTP模式:

switch(enable)setvtp[domaindomain-name][mode{sever|cilent|transparent}][passwordpassword]

12.在基于IOS的交换机上配置VTP版本:

switch#vlandatabase

switch(vlan)#vtpv2-mode

在基于CLI的交换机上配置VTP版本:

switch(enable)setvtpv2enable

13.在基于IOS的交换机上启动VTP剪裁:

switch#vlandatabase

switch(vlan)#vtppruning

在基于CLI的交换机上启动VTP剪裁:

switch(enable)setvtppruningenable

14.在基于IOS的交换机上配置以太信道:

switch(config-if)#portgroupgroup-number[distribution{source|destination}]

在基于CLI的交换机上配置以太信道:

switch(enable)setportchannelmoudle/port-rangemode{on|off|desirable|auto}

15.在基于IOS的交换机上调整根路径成本:

switch(config-if)#spanning-tree[vlanvlan-list]costcost

在基于CLI的交换机上调整根路径成本:

switch(enable)setspantreeportcostmoudle/portcost

switch(enable)

setspantreeportvlancostmoudle/port[costcost][vlan-list]

16.在基于IOS的交换机上调整端口ID:

switch(config-if)#spanning-tree[vlanvlan-list]port-priorityport-priority

在基于CLI的交换机上调整端口ID:

switch(enable)setspantreeportpri{mldule/port}priority

switch(enable)setspantreeportvlanpri{module/port}priority[vlans]

17.在基于IOS的交换机上修改STP时钟:

switch(config)#spanning-tree[vlanvlan-list]hello-timeseconds

switch(config)#spanning-tree[vlanvlan-list]forward-timeseconds

switch(config)#spanning-tree[vlanvlan-list]max-ageseconds

在基于CLI的交换机上修改STP时钟:

switch(enable)setspantreehellointerval[vlan]

switch(enable)setspantreefwddelaydelay[vlan]

switch(enable)setspantreemaxageagingtiame[vlan]

18.在基于IOS的交换机端口上启用或禁用PortFast特征:

switch(config-if)#spanning-treeportfast

在基于CLI的交换机端口上启用或禁用PortFast特征:

switch(enable)setspantreeportfast{module/port}{enable|disable}

19.在基于IOS的交换机端口上启用或禁用UplinkFast特征:

switch(config)#spanning-treeuplinkfast[max-update-ratepkts-per-second]

在基于CLI的交换机端口上启用或禁用UplinkFast特征:

switch(enable)setspantreeuplinkfast{enable|disable}[rateupdate-rate][all-protocolsoff|on]

20.为了将交换机配置成一个集群的命令交换机,首先要给管理接口分配一个IP地址,然后使用下列命令:

switch(config)#clusterenablecluster-name

21.为了从一条中继链路上删除VLAN,可使用下列命令:

switch(enable)cleartrunkmodule/portvlan-range

22.用showvtpdomain显示管理域的VTP参数.

23.用showvtpstatistics显示管理域的VTP参数.

24.在Catalyst交换机上定义TrBRF的命令如下:

switch(enable)setvlanvlan-name[namename]typetrbrfbridgebridge-num[stp{ieee|ibm}]

25.在Catalyst交换机上定义TrCRF的命令如下:

switch(enable)setvlanvlan-num[namename]typetrcrf

{ringhex-ring-num|decringdecimal-ring-num}parentvlan-num

26.在创建好TrBRFVLAN之后,就可以给它分配交换机端口.对于以太网交换,可以采用如下命令给VLAN分配端口:

switch(enable)setvlanvlan-nummod-num/port-num

27.命令showspantree显示一个交换机端口的STP状态.

28.配置一个ELAN的LES和BUS,可以使用下列命令:

ATM(config)#interfaceatmnumber.subintmultioint

ATM(config-subif)#laneserber-busethernetelan-name

29.配置LECS:

ATM(config)#lanedatabasedatabase-name

ATM(lane-config-databade)#nameelan1-nameserver-atm-addressles1-nsap-address

ATM(lane-config-databade)#nameelan2-nameserver-atm-addressles2-nsap-address

ATM(lane-config-databade)#name…

30.创建完数据库后,必须在主接口上启动LECS.命令如下:

ATM(config)#interfaceatmnumber

ATM(config-if)#laneconfigdatabasedatabase-name

ATM(config-if)#laneconfigauto-config-atm-address

31.将每个LEC配置到一个不同的ATM子接口上.命令如下:

ATM(config)#interfaceatmnumber.subintmultipoint

ATM(config)#laneclientethernetvlan-numelan-num

32.用showlaneserver显示LES的状态.

33.用showlanebus显示bus的状态.

34.用showlanedatabase显示LECS数据库可内容.

35.用showlaneclient显示LEC的状态.

36.用showmodule显示已安装的模块列表.

37.用物理接口建立与VLAN的连接:

router#configureterminal

router(config)#interfacemediamodule/port

router(config-if)#descriptiondescription-string

router(config-if)#ipaddressip-addrsubnet-mask

router(config-if)#noshutdown

38.用中继链路来建立与VLAN的连接:

router(config)#interfacemodule/port.subinterface

router(config-ig)#encapsulation[isl|dotlq]vlan-number

router(config-if)#ipaddressip-addresssubnet-mask

39.用LANE来建立与VLAN的连接:

router(config)#interfaceatmmodule/port

router(config-if)#noipaddress

router(config-if)#atmpvc105qsaal

router(config-if)#atmpvc2016ilni

router(config-if)#interfaceatmmodule/port.subinterfacemultipoint

router(config-if)#ipaddressip-addresssubnet-mask

router(config-if)#laneclientethernetelan-num

router(config-if)#interfaceatmmodule/port.subinterfacemultipoint

router(config-if)#ipaddressip-addresssubnet-name

router(config-if)#laneclientethernetelan-name

router(config-if)#…

40.为了在路由处理器上进行动态路由配置,可以用下列IOS命令来进行:

router(config)#iprouting

router(config)#routerip-routing-protocol

router(config-router)#networkip-network-number

router(config-router)#networkip-network-number

41.配置默认路由:

switch(enable)setiproutedefaultgateway

42.为一个路由处理器分配VLANID,可在接口模式下使用下列命令:

router(config)#interfaceinterfacenumber

router(config-if)#mlsrpvlan-idvlan-id-nu

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 高中教育 > 高中教育

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1