呃呃呃

2. 利用超级终端对路由器进行基本配置

启动PC0超级终端(单击PC0>单击Desktop选项卡—>单击terminal,设置路由器的管理地址(假设为192.168.1.1)、VTY虚拟终端线路登陆密码(假设为123)和进入特权模式的密码(假设为12345,实现对路由器的远程登录连接。

具体操作命令如下:

1)设置路由器的管理地址

Router>enable 进入特权模式

Router #config terminal   进入全局模式

配置IP地址

Router (config)#interface fa0/0  //选择模块00号端口

Router (config-if)#ip address 192.168.1.1 255.255.255.0

Router (config-if)#no shut  //启动路由器,注意,此操作不可缺少,否则计算机无法和路由器连接

2)设置VTY虚拟终端线路登陆密码

Router (config)#line vty 0 4   //设置虚拟终端接口线路的密码,允许远程登录

Router (config-line)#password 123

Router (config-line)#login

3)设置进入特权模式的密码

Router (config-line)#enable password 12345

Router (config-line)#end

3. 远程登录路由器

启动PC1,配置PC1IP地址为192.168.1.3,在Desktop中选择Commend Prompt,进入命令行模式

在提示符PC>下输入Telnet 192.168.1.1则会出现以下信息:

Trying 192.168.1.1 ...

User Access Verification

Password:      

输入密码123即可登录到路由器上,出现提示符Router >

在提示符Router >下输入enable回车,输入密码12345回车,则进入特权模式Router #

1)在特权模式下显示vlan信息

在提示符Router #下输入show vlan  

结果如下:

Router

VLAN   Name                          Status    Ports

---- -------------------------------- --------- -------------------------------

1       default                         active    

1002    fddi-default                     act/unsup

1003    token-ring-default               act/unsup

1004    fddinet-default                  act/unsup

1005    trnet-default                    act/unsup

 

VLAN Type  SAID       MTU   Parent RingNo BridgeNo Stp  BrdgMode Trans1 Trans2

---- ----- ---------- ----- ------ ------ -------- ---- -------- ------ ------

1    enet   100001     1500  -      -      -        -    -        0      0

1002 fddi   101002     1500  -      -      -        -    -        0      0   

1003 tr     101003     1500  -      -      -        -    -        0      0   

1004 fdnet  101004     1500  -      -      -        ieee -         0      0   

1005 trnet   101005     1500  -      -      -        ibm  -        0      0   

 

Remote SPAN VLANs

------------------------------------------------------------------------------

Primary Secondary Type              Ports

------- --------- ----------------- ------------------------------------------

说明:如果在第2步中没有设置进入特权模式的密码,则远程登录到路由器后,无法进入特权模式,会看到以下提示信息:% No password set

2)在特权模式下显示当前配置文件信息

在提示符Router#下输入show run命令,显示结果如下:

Building configuration...

Current configuration : 497 bytes

version 12.4

no service timestamps log datetime msec

no service timestamps debug datetime msec

no service password-encryption

enable password 12345

interface FastEthernet0/0

 ip address 192.168.1.1 255.255.255.0

 duplex auto

 speed auto

interface FastEthernet0/1

 no ip address

 duplex auto

 speed auto

 shutdown

interface Vlan1

 no ip address

 shutdown

ip classless

line con 0

line vty 0 4

 password 123

 login

end

4. 远程登录连接到路由器后,配置路由器的主机名为R1,然后禁用DNS服务。

输入如下命令:

Router#conf t

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

Router(config)#hostname R1

R1(config)#no ip domain-lookup

R1(config)#

5. 查看配置文件的内容变化情况,然后执行copy命令保存配置。

R1#show run

R1#copy run start

Destination filename [startup-config]? (此处按回车即可)

Building configuration...

[OK]

此时如果运行show start命令,可以看到其内容。

6. 将路由器的fa0/1口速率设置为100Mbps通信方式设置为全双工。并用show run命令显示配置结果。

R1#conf t

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

R1 (config)#interface  fa0/1

R1 (config-if)#speed 100     //设置速率

R1 (config-if)#duplex full   //设置全双工模式 两端模式要一致,否则不能连通

R1#show run    //显示设置结果

Building configuration...

Current configuration : 485 bytes

version 12.4

no service timestamps log datetime msec

no service timestamps debug datetime msec

no service password-encryption

hostname R1

enable password 12345

interface FastEthernet0/0

 ip address 192.168.1.1 255.255.255.0

 duplex auto

 speed 100

interface FastEthernet0/1

 no ip address

 duplex full

 speed 100

 shutdown

no ip address

ip classless

line con 0

line vty 0 4

 password 123

 login

end

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值