CISCO router基本配置

简介:

基本配置

包括:

1.配置主机名称

2.配置特权密码/登陆密码/用户数据库

3.配置用户数据库

4.配置TELNET 及CON口

5.配置禁止DNS解析

6.配置接口。能够远程登陆

7.配置文件的保存。

 Press RETURN to get started!

 

Router>ena
Router#conf?    当不了解命令的拼写时可以使用帮助
configure 
Router#configure ?   当不了解命令的组成时可以使用帮助
  terminal  Configure from the terminal
  <cr>
Router#configure terminal  进入控制台配置模式


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


Router(config)#hostname R1    更改ROUTER名为R1


R1(config)#username cisco sec cisco   创建用户名和密码数据库  sec  为secret的缩写,加密。也可以为password


R1(config)#ena sec cisco         行特权配置模式密码,不配置的话TELNET无法使用


R1(config)#banner motd #this cisco router!#    用户提示语,显示在进入ROUTER前。
 
R1(config)#line vty 0 4     配置虚拟连接(TELNET)


R1(config-line)#login local   启用登陆验证,不启用的话TELNET不能使用


R1(config-line)#exec-timeout 88 1   设置超时值为88分钟1秒


R1(config-line)#exi    退出


R1(config)#line console 0   进入控制台端口


R1(config-line)#login local 


R1(config-line)#exec-timeout 88 1


R1(config-line)#exit
R1(config)#no ip domain-lookup  禁用DNS解析


R1(config)#exi
R1#
%SYS-5-CONFIG_I: Configured from console by console


R1#clock set 15:36:10 mar 6 2011  设置时钟
R1#show cloc
*15:36:18.94 UTC ??? ?? 6 2011
R1#show ip int brief
Interface              IP-Address      OK? Method Status                Protocol
 
FastEthernet0/0        unassigned      YES unset  administratively down down
 
FastEthernet0/1        unassigned      YES unset  administratively down down
 
Vlan1                  unassigned      YES unset  administratively down down
R1#conf t
Enter configuration commands, one per line.  End with CNTL/Z.
R1(config)#interface fastethernet0/0   进入端口F0/0
R1(config-if)#ip add 192.168.1.1 255.255.255.0   配置IP和掩码
R1(config-if)#no shu   ROUTER端口默认是关闭。需要用no shutdown命令开启.showdown命令关闭。

%LINK-5-CHANGED: Interface FastEthernet0/0, changed state to up


Router(config-if)#description neiwang   
端口描述:neiwang

R1(config-if)#exi
 
R1(config)#logging ?  
  A.B.C.D   IP address of the logging host
  buffered  Set buffered logging parameters
  console   Set console logging parameters
  host      Set syslog server IP address and parameters
  on        Enable logging to all enabled destinations
  trap      Set syslog server logging level
  userinfo  Enable logging of user info on privileged mode enabling
R1(config)#lin con 0
R1(config-line)#logging synchronous  它可以阻止那控制台信息来打断你当前的输入,从而使输入信息显得更为简单易读。DEBUG时用处就显现出来了。效果和配置只在控制台配置模式下
R1(config-line)#exi
 
R1(config)#exi

%SYS-5-CONFIG_I: Configured from console by console
R1#
R1#copy running-config startup-config    保存配置命令。 将RAM中正在运行的配置running-config保存 在NVRAM的startup-config 中


Destination filename [startup-config]?
Building configuration...
[OK]
 
R1#reload    重启ROUTER


本文转自  还不算晕  51CTO博客,原文链接:http://blog.51cto.com/haibusuanyun/508165

相关文章
|
网络协议 网络架构
BGP基本配置
文章目录 系列文章目录 前言 BGP实验拓扑描述 实验描述 实验需求 BGP的选路规则 完成基本配置 R1的配置如下: R2的配置如下 : R3 的配置如下: R4的配置如下: R5的配置如下: 总结
125 0
BGP基本配置
|
网络协议 网络架构 数据安全/隐私保护
|
网络虚拟化 域名解析 网络架构
|
数据安全/隐私保护 网络架构
|
网络协议 数据安全/隐私保护 网络架构
|
网络协议 Shell 网络架构
|
网络协议 网络虚拟化 网络架构