静态综合实验

静态综合实验

图

IP地址规划

192.168.1.0/24
192.168.1.0/27 骨干
192.168.1.0/30
192.168.1.4/30
192.168.1.8/30
192.168.1.12/30
192.168.1.16/30
192.168.1.20/30
192.168.1.24/30
192.168.1.28/30
192.168.1.32/27 R1环回
192.168.1.32/28
192.168.1.48/28
192.168.1.64/27 R2环回
192.168.1.64/28
192.168.1.80/28
192.168.1.96/27 R3
192.168.1.128/27 R4环回
192.168.1.128/28
192.168.144/28
192.168.1.169/27 R5环回

配置

配置IP地址(以r1为例)

[r1]int g0/0/0
[r1-GigabitEthernet0/0/0]ip add 192.168.1.1 30
[r1-GigabitEthernet0/0/0]int g0/0/1
[r1-GigabitEthernet0/0/1]ip add 192.168.1.26 30
[r1-GigabitEthernet0/0/1]int l0
[r1-LoopBack0]ip add 192.168.1.33 28
[r1-LoopBack0]int l1
[r1-LoopBack1]ip add 192.168.1.49 28

配置静态路由(以r1为例)

r1]ip route-static 0.0.0.0 0.0.0.0 192.168.1.2
[r1]ip route-static 0.0.0.0 0.0.0.0 192.168.1.25
[r1]ip route-static 192.168.1.96 30 192.168.1.25
[r1]ip route-static 192.168.1.64 27 192.168.1.2
[r1]ip route-static 192.168.1.4 30 192.168.1.2
[r1]ip route-static 192.168.1.16 30 192.168.1.25

DHCP服务

[r3]dhcp enable
Info: The operation may take a few seconds. Please wait for a
[r3]ip pool xh
[r3-ip-pool-xh]network 192.168.1.96 mask 27
[r3-ip-pool-xh]gateway-list 192.168.1.97
[r3-ip-pool-xh]int g0/0/2
[r3-GigabitEthernet0/0/2]dhcp select global
PC1
PC2

空接口避免路由黑洞的产生(r1为例)

[r1]ip route-static 192.168.1.32 27 NULL 0

nat 让AR1到AR3都可以访问lsp

[r5]acl 2000
[r5-acl-basic-2000]rule permit source 192.168.1.0 0.0.0.0
[r5-acl-basic-2000]int g0/0/0
[r5-GigabitEthernet0/0/0]nat outbound 2000
访问1.1.1.1

r6telnetr5的公有IP地址的时候实际登录到r1上

在r1开启telnet服务

[r1]aaa
[r1-aaa]local-user xh privilege level 3 password cipher 12345
[r1-aaa]local-user admin service-type telnet
[r1-aaa]q
[r1]user-interface vty 0 3
[r1-ui-vty0-3]authentication-mode aaa

在r5进行对r1的端口映射

[r5]int g0/0/0
[r5-GigabitEthernet0/0/0]nat server protocol tcp global current-interface 23 inside 192.168.1.1 23

Are you sure to continue?[Y/N]:y

在r6测试

telnet 12.0.0.1
Press CTRL_] to quit telnet mode
Trying 12.0.0.1 …
Connected to 12.0.0.1 …

Login authentication

Username:xh
Password:
在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值