1200字范文,内容丰富有趣,写作的好帮手!
1200字范文 > cisco路由器基本实验之五 配置Loopback接口进行远程登录 (Boson NetSim)

cisco路由器基本实验之五 配置Loopback接口进行远程登录 (Boson NetSim)

时间:2021-09-07 03:43:20

相关推荐

cisco路由器基本实验之五 配置Loopback接口进行远程登录 (Boson NetSim)

先说点题外话,本来这两天是没时间来更新博客了的,但是事情出了点变化,使得我又有时间上网了,上网当然要到博客里面去逛逛了,没想到收到一封来自51cto的短信,说我的博客已经被评为推荐博客了,呵呵,真的很高兴能得到这样的荣誉,51cto让我感受到了学习的乐趣和写博客的动力(之前在csdn很没动力),更重要的是,能和这么多的网络技术爱好者共同学习,实在是一件很美妙的事情。感谢51cto。

最近我的这几篇关于cisco基础实验的文章都有幸得到了推荐,从网友的回复看,大多数网友还是支持我的,虽然我的文章对一部分博友来说很初级,但他们都没有说,相反还得到了他们的多次指点,真的很谢谢他们。当然我相信,我不会永远做初级的实验的,我是按照进度来循序渐进的进行的,总会做到高级一点的实验的,呵呵,当然,今天的实验应该还算初级的,呵呵。下面看实验。 实验开始前先说说Loopback接口,它是应用最为广泛的一种虚接口(即是接口不会依赖物理接口,接口的状态永远是UP的),网管完成网络规划之后,为了方便管理,会为每一台路由器创建一个loopback 接口,并在该接口上单独指定一个IP 地址作为管理地址,管理员会使用该地址对路由器远程登录(telnet)。因此学习它的配置还是有一定的意义的。 拓扑图如上所示,今天的实验通过show 的方式来展现,一来比较简短,二来比较易于察看,一目了然。1.1 在r1上show run:r1#show run

Building configuration...!

Version 12.1

service timestamps debug uptime

service timestamps log uptime

no service password-encryption

!

hostname r1

!

!

!

ip subnet-zero

!

!

!

!

!

!

!

!

!

!

interface Loopback

ip address 10.1.1.1 255.255.255.0

no ip directed broadcast

!

interface Serial0

ip address 192.168.2.1 255.255.255.0

no ip directed-broadcast

clock rate 64000

!

interface Ethernet0

ip address 192.168.1.2 255.255.255.0

no ip directed-broadcast

!

!

router rip

network 192.168.1.0

network 192.168.2.0

network 10.0.0.0 //我的loopback接口的IP地址为10.1.1.1

!

ip classless

no ip http server

!

!

!

line con 0

transport input none

line aux 0

line vty 0 4/启用了vty线路方可进行telnet

login

password cisco

!

no scheduler allocate

end1.2在r1上show ip route

r1# show ip route

Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default

U - per-user static routeGateway of last resort is not set192.168.1.0/24 is subnetted, 1 subnets

C 192.168.1.0 is directly connected, Ethernet0

10.0.0.0/24 is subnetted, 1 subnets

C 10.1.1.0 is directly connected, Loopback

192.168.2.0/24 is subnetted, 1 subnets

C 192.168.2.0 is directly connected, Serial0

192.168.3.0/24 is subnetted, 1 subnets

R 192.168.3.0 [120/1] via 192.168.2.2, 00:01:25, Serial0 //这个英文比较简单,应该看得懂1.3 在r1上show ip pror1#show ip pro

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 7 seconds

Invalid after 180 seconds, hold down 180, flushed after 240 //从这句可以得知:该配置采用rip协议,路由器每隔30s发出更新信息,(next due in 7 seconds?),超过180s未收到路由更新则认为该路由无效,如果经过240s还没收到更新信息,这该路由信息将会从路由表中删除。

Outgoing update filter list for all interfaces is

Incoming update filter list for all interfaces is

Redistributing: rip

Default version control: send version 1, receive any version

Interface Send Recv Key-chain

Serial0 1 1 2

Ethernet0 1 1 2

Routing for Networks:

192.168.1.0

192.168.2.0

10.0.0.0

Routing Information Sources:

192.168.2.2 120 00:00:09

Distance: (default is 120) //rip的管理距离默认为120,该值越小越好21.在r2上show run:r2#show run

Building configuration...!

Version 12.1

service timestamps debug uptime

service timestamps log uptime

no service password-encryption

!

hostname r2

!

!

!

ip subnet-zero

!

!

!

!

!

!

!

!

!

!

interface Serial0

ip address 192.168.2.2 255.255.255.0

no ip directed-broadcast

!

interface Ethernet0

ip address 192.168.3.1 255.255.255.0

no ip directed-broadcast

!

!

router rip

network 192.168.3.0

network 192.168.2.0

!

ip classless

no ip http server

!

!

!

line con 0

transport input none

line aux 0

line vty 0 4

!

no scheduler allocate

end

2.2在r2上show ip router2#show ip route

Codes: C - connected, S - static, I - IGRP, R - RIP, M - mobile, B - BGP

D - EIGRP, EX - EIGRP external, O - OSPF, IA - OSPF inter area

E1 - OSPF external type 1, E2 - OSPF external type 2, E - EGP

i - IS-IS, L1 - IS-IS level-1, L2 - IS-IS level-2, * - candidate default

U - per-user static routeGateway of last resort is not set192.168.2.0/24 is subnetted, 1 subnets

C 192.168.2.0 is directly connected, Serial0

192.168.3.0/24 is subnetted, 1 subnets

C 192.168.3.0 is directly connected, Ethernet0

192.168.1.0/24 is subnetted, 1 subnets

R 192.168.1.0 [120/1] via 192.168.2.1, 00:08:16, Serial0

10.0.0.0/24 is subnetted, 1 subnets

R 10.1.1.0 [120/1] via 192.168.2.1, 00:02:14, Serial02.3 在r2上show ip pror2#show ip pro

Routing Protocol is "rip"

Sending updates every 30 seconds, next due in 4 seconds

Invalid after 180 seconds, hold down 180, flushed after 240

Outgoing update filter list for all interfaces is

Incoming update filter list for all interfaces is

Redistributing: rip

Default version control: send version 1, receive any version

Interface Send Recv Key-chain

Serial0 1 1 2

Ethernet0 1 1 2

Routing for Networks:

192.168.3.0

192.168.2.0

Routing Information Sources:

192.168.2.1 120 00:00:03

Distance: (default is 120) //意思同r1中的意思3.pc1的配置ipconfig /ip 192.168.1.1 255.255.255.0ipconfig /dg192.168.1.24.pc2的配置ipconfig /ip 192.168.3.2 255.255.255.0ipconfig /dg192.168.3.15.远程登录验证

如图所示,在输入telnet 10.1.1.1 并回车之后,会要求输入密码,此处为cisco,输入之后便可以在pc1上对r1进行配置。以前做实验,做完之后就只想到让它们互相ping通就好了,但是自从经过博友的提醒之后,才发现原来做实验并不仅仅局限于此,实验做完之后还可以学到很多的东西,再次谢谢众博友。

本文转自 victoryan 51CTO博客,原文链接:/victoryan/39231

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。