分享

思科路由器配置

 星之梦sxp 2021-05-19

switch>enable

switch>configure terminal

swith(config)hostname  cisco-sw1

cisco-sw1(config)#enable secret ciscoswitch  //给交换机配置使能密码。进入特权模式事需要输入密码才能进

cisco-sw1(config)#vlan 2

cisco-sw1(config-vlan)#name test

cisco-sw1(config-vlan)#exit

cisco-sw1(config)#interface  fastEthernet 0/1   //进入交换机蒙一个端口

cisco-sw1(config-if)#switchport  mode access

cisco-sw1(config-if)#switchport  access vlan 2

查看命令

#show vlan brief(查看配置情况)

#show version 查看系统中的所有版本信息

#show running-configure查看交换机当前起作用得配置信息。

#show interface fastethernet 0/1 查看交换机1 接口具体配置和统计信息

#show mac-address-table 查看mac地址转发表。

交换机恢复出厂设置

switch>enable

switch>erase startup-configure

switch>#reload

telnet远程登录设置

switch>en

switch>#configure  terminal

switch(conf)#enable password cisco      以cisco为特权模式密码

switch(conf)#interface vlan1  以vlan1端口作为远程登录接口,其它端口亦可。

switch(conf)#ip address 192.168.1.1  255.255.255.0

swich(conf-if)#no shut

swich(conf-if)#exit

switch(conf)#line vty 0 4 设置0-4个用户可以telnet远程登录。

swich(conf-line)# password 123456

switch(conf-line)#login

SSH远程登录设置:

Switch#conf t

Enter configuration commands, one per line.  End with CNTL/Z.

Switch(config)#hostname cisco-sw1   交换机重新命名

cisco-sw1(config)#ip domain-name 配置域名

cisco-sw1(config)#line vty 0 4

cisco-sw1(config-line)#transport input ssh 登录方式为SSH

cisco-sw1(config-line)#exit

cisco-sw1(config)#crypto key generate rsa 配置秘钥

The name for the keys will be: cisco-sw1.

Choose the size of the key modulus in the range of 360 to 2048 for your

General Purpose Keys. Choosing a key modulus greater than 512 may take

a few minutes.

How many bits in the modulus [512]: 1024 思科推荐使用1024

% Generating 1024 bit RSA keys, keys will be non-exportable...[OK]

思科交换机常用命令及配置

    本站是提供个人知识管理的网络存储空间,所有内容均由用户发布,不代表本站观点。请注意甄别内容中的联系方式、诱导购买等信息,谨防诈骗。如发现有害或侵权内容,请点击一键举报。
    转藏 分享 献花(0

    0条评论

    发表

    请遵守用户 评论公约

    类似文章 更多