cisco中IPv6实验.docx

上传人:b****5 文档编号:3729087 上传时间:2022-11-25 格式:DOCX 页数:28 大小:266.42KB
下载 相关 举报
cisco中IPv6实验.docx_第1页
第1页 / 共28页
cisco中IPv6实验.docx_第2页
第2页 / 共28页
cisco中IPv6实验.docx_第3页
第3页 / 共28页
cisco中IPv6实验.docx_第4页
第4页 / 共28页
cisco中IPv6实验.docx_第5页
第5页 / 共28页
点击查看更多>>
下载资源
资源描述

cisco中IPv6实验.docx

《cisco中IPv6实验.docx》由会员分享,可在线阅读,更多相关《cisco中IPv6实验.docx(28页珍藏版)》请在冰豆网上搜索。

cisco中IPv6实验.docx

cisco中IPv6实验

IPv6实验部分:

一.IPv6静态路由配置

实验拓扑:

IPv6route命令添加静态ipv6路由:

Router(config)#ipv6unicast-routing//全局启用IPV6单播路由功能

Router(config)#ipv6routeipv6-prefix/prefix-length{next-hop|interface}[distance]

在CISCOIOS软件支持中语法为:

Router(config)#ipv6routeipv6-prefix/prefix-lengthinterfacelink-local-address[distance]

配置R1和R2:

R1使用网络接口S1/0,通过下跳FE80:

:

CE00:

2FF:

FEA4:

0,可到达目的IPV6网络2001:

2:

2:

:

/48

r1(config)#ipv6route2001:

2:

2:

:

/48serial1/0FE80:

:

CE00:

2FF:

FEA4:

0

r2(config)#ipv6route2001:

1:

1:

:

/48serial1/0FE80:

:

CE00:

3FF:

FE68:

0

或:

r2(config)#ipv6route2001:

1:

1:

:

/482001:

A:

A:

A:

:

1

默认路由配置例子:

r2(config)#ipv6route:

:

/0serial1/0FE80:

:

CE00:

3FF:

FE68:

0

 

静态路由配置时要注意:

在IPV6规范中,不推荐使用聚合全球单播或本地站点地址作为下一跳地址,一般使用本地链路地址作为下一跳,但在配置本地地址作为一下跳时,在配置中必须指出路由器上相应的网络接口

二.配置6to4隧道连接IPv4/6网络

6to4机制的特点是:

1、自动隧道机制

2、在站点边缘启用,6to4的路由器通过IPv4网络到达对方。

3、自动前缀分配,所有前缀均使用2002:

:

/16,IPv4的地址转换为16进制附在2002:

:

/16后面.最终表现形式是2002:

ipv4-address:

:

/48。

4、没有IPv6路由传播,每个前缀都是基于IPv4地址,因此IPv4的路由域已经足够使用。

本实验目的:

通过6to4隧道连接2个IPv6网络:

实验拓扑如下:

R4路由器连接的IPv6网络所属网段为2002:

0202:

0202:

:

/48(可划分出65535个子网);

R5路由器连接的IPv6网络所属网段为2002:

0303:

0303:

:

/48(可划分出65535个子网);

这两个IPv6网络之间要通信,可通过穿透IPv4Internet建立6to4隧道。

R1、R2、R3运行OSPFv2来完成整个IPv4网络的可达性;而IPv6网络分别运行OSPFv3来完成各自内部的可达性。

以下为每个路由器完整配置:

配置R1:

hostnamer1

interfaceSerial1/0

ipaddress12.1.1.1255.255.255.0

clockrate64000

interfaceSerial1/1

ipaddress13.1.1.1255.255.255.0

clockrate64000

routerospf1

log-adjacency-changes

network0.0.0.0255.255.255.255area0

end

配置R2:

ipv6unicast-routing

interfaceTunnel0

ipv6enable

tunnelsourceLoopback0

tunnelmodeipv6ip6to4

!

interfaceLoopback0

ipaddress2.2.2.2255.255.255.0

!

interfaceSerial1/0

ipaddress12.1.1.2255.255.255.0

!

interfaceSerial1/1

ipospf1area0

ipv6enable

ipv6ospf1area0

routerospf1

log-adjacency-changes

network0.0.0.0255.255.255.255area0

ipv6route2002:

303:

303:

:

/48Tunnel0

ipv6routerospf1

log-adjacency-changes

redistributestatic//将静态路由重发布进OSPF,以使网络内部(R4)获得对端路由

配置R3:

ipv6unicast-routing

interfaceTunnel0

ipv6enable

tunnelsourceLoopback0

tunnelmodeipv6ip6to4

!

interfaceLoopback0

ipaddress3.3.3.3255.255.255.0

!

interfaceSerial1/0

ipaddress13.1.1.3255.255.255.0

!

interfaceSerial1/1

ipv6enable

ipv6ospf1area0

!

routerospf1

log-adjacency-changes

network0.0.0.0255.255.255.255area0

ipv6route2002:

202:

202:

:

/48Tunnel0

ipv6routerospf1

log-adjacency-changes

redistributestatic//将静态路由重发布进OSPF,以使网络内部(R5)获得对端路由

配置R4:

ipv6unicast-routing

interfaceLoopback0

ipaddress4.4.4.4255.255.255.0

!

interfaceEthernet0/0

ipv6address2002:

202:

202:

4:

:

4/64

ipv6enable

ipv6ospf1area0

nokeepalive

!

interfaceSerial1/0

ipv6enable

ipv6ospf1area0

ipv6routerospf1

router-id4.4.4.4

配置R5:

ipv6unicast-routing

interfaceLoopback0

ipaddress5.5.5.5255.255.255.0

!

interfaceEthernet0/0

ipv6address2002:

303:

303:

5:

:

5/64

ipv6ospf1area0

nokeepalive

!

interfaceSerial1/0

ipv6enable

ipv6ospf1area0

!

ipv6routerospf1

router-id5.5.5.5

 

查看R4,R5的路由表:

r4#showipv6route

IPv6RoutingTable-5entries

Codes:

C-Connected,L-Local,S-Static,R-RIP,B-BGP

U-Per-userStaticroute

I1-ISISL1,I2-ISISL2,IA-ISISinterarea,IS-ISISsummary

O-OSPFintra,OI-OSPFinter,OE1-OSPFext1,OE2-OSPFext2

ON1-OSPFNSSAext1,ON2-OSPFNSSAext2

C2002:

202:

202:

4:

:

/64[0/0]

via:

:

Ethernet0/0

L2002:

202:

202:

4:

:

4/128[0/0]

via:

:

Ethernet0/0

OE22002:

303:

303:

:

/48[110/20]

viaFE80:

:

CE00:

FFF:

FE88:

0,Serial1/0

LFE80:

:

/10[0/0]

via:

:

Null0

LFF00:

:

/8[0/0]

via:

:

Null0

r5#showipv6route

IPv6RoutingTable-5entries

Codes:

C-Connected,L-Local,S-Static,R-RIP,B-BGP

U-Per-userStaticroute

I1-ISISL1,I2-ISISL2,IA-ISISinterarea,IS-ISISsummary

O-OSPFintra,OI-OSPFinter,OE1-OSPFext1,OE2-OSPFext2

ON1-OSPFNSSAext1,ON2-OSPFNSSAext2

OE22002:

202:

202:

:

/48[110/20]

viaFE80:

:

CE00:

FFF:

FE34:

0,Serial1/0

C2002:

303:

303:

5:

:

/64[0/0]

via:

:

Ethernet0/0

L2002:

303:

303:

5:

:

5/128[0/0]

via:

:

Ethernet0/0

LFE80:

:

/10[0/0]

via:

:

Null0

LFF00:

:

/8[0/0]

via:

:

Null0

检查R4、R5的路由表,可见均已经有对应网络的路由信息:

用PING命令测试网络连通性:

r4#ping2002:

303:

303:

5:

:

5

Typeescapesequencetoabort.

Sending5,100-byteICMPEchosto2002:

303:

303:

5:

:

5,timeoutis2seconds:

!

!

!

!

!

Successrateis100percent(5/5),round-tripmin/avg/max=240/410/504ms

r4#

r5#ping2002:

202:

202:

4:

:

4

Typeescapesequencetoabort.

Sending5,100-byteICMPEchosto2002:

202:

202:

4:

:

4,timeoutis2seconds:

!

!

!

!

!

Successrateis100percent(5/5),round-tripmin/avg/max=280/432/632ms

r5#

 

三.RIPng(下一代路由信息协议)实验配置

实验拓扑:

配置R1:

ipv6unicast-routing//启用ipv6单播路由协议

interfaceEthernet0/0

ipv6address2001:

1:

1:

1:

:

1/64

ipv6ripciscoenable//在接口启用RIPng

nokeepalive

interfaceSerial1/0

ipv6address2001:

A:

A:

A:

:

1/64

ipv6ripciscoenable//在接口启用RIPng

interfaceSerial1/1

ipv6address2001:

B:

B:

B:

:

1/64

ipv6ripciscoenable//在接口启用RIPng

ipv6routerripcisco//定义标识为cisco的的RIPng进程

 

配置R2:

ipv6unicast-routing

interfaceEthernet0/0

ipv6address2001:

2:

2:

2:

:

2/64

ipv6ripciscoenable

nokeepalive

interfaceSerial1/0

ipv6address2001:

A:

A:

A:

:

2/64

ipv6ripciscoenable

ipv6routerripcisco

配置R3

ipv6unicast-routing//启用ipv6单播路由协议

interfaceEthernet0/0

ipv6address2001:

3:

3:

1:

:

3/64

ipv6address2001:

3:

3:

2:

:

3/64

ipv6address2001:

3:

3:

3:

:

3/64

ipv6address2001:

3:

3:

4:

:

3/64

ipv6address2001:

3:

3:

5:

:

3/64

ipv6address2001:

3:

3:

6:

:

3/64

ipv6ripciscoenable

nokeepalive

!

interfaceSerial1/0

ipv6address2001:

B:

B:

B:

:

3/64

ipv6ripciscoenable

ipv6routerripcisco:

 

在R2验证配置:

r2#showipv6rip

RIPprocess"cisco",port521,multicast-groupFF02:

:

9,pid168

Administrativedistanceis120.Maximumpathsis16

Updatesevery30seconds,expireafter180

Holddownlasts0seconds,garbagecollectafter120

Splithorizonison;poisonreverseisoff

Defaultroutesarenotgenerated

Periodicupdates92,triggerupdates16

Interfaces:

Ethernet0/0

Serial1/0

Redistribution:

None

r2#showipv6route

IPv6RoutingTable-14entries

Codes:

C-Connected,L-Local,S-Static,R-RIP,B-BGP

U-Per-userStaticroute

I1-ISISL1,I2-ISISL2,IA-ISISinterarea,IS-ISISsummary

O-OSPFintra,OI-OSPFinter,OE1-OSPFext1,OE2-OSPFext2

ON1-OSPFNSSAext1,ON2-OSPFNSSAext2

R2001:

1:

1:

1:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

C2001:

2:

2:

2:

:

/64[0/0]

via:

:

Ethernet0/0

L2001:

2:

2:

2:

:

2/128[0/0]

via:

:

Ethernet0/0

R2001:

3:

3:

1:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

2:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

3:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

4:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

5:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

6:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

C2001:

A:

A:

A:

:

/64[0/0]

via:

:

Serial1/0

L2001:

A:

A:

A:

:

2/128[0/0]

via:

:

Serial1/0

R2001:

B:

B:

B:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

LFE80:

:

/10[0/0]

via:

:

Null0

LFF00:

:

/8[0/0]

via:

:

Null0

r2#showipv6routerip

IPv6RoutingTable-14entries

Codes:

C-Connected,L-Local,S-Static,R-RIP,B-BGP

U-Per-userStaticroute

I1-ISISL1,I2-ISISL2,IA-ISISinterarea,IS-ISISsummary

O-OSPFintra,OI-OSPFinter,OE1-OSPFext1,OE2-OSPFext2

ON1-OSPFNSSAext1,ON2-OSPFNSSAext2

R2001:

1:

1:

1:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

1:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

2:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

3:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

4:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

5:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

6:

:

/64[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

B:

B:

B:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

r2#showipv6ripdatabase

RIPprocess"cisco",localRIB

2001:

1:

1:

1:

:

/64,metric2,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

1:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

2:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

3:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

4:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

5:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

3:

3:

6:

:

/64,metric3,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

A:

A:

A:

:

/64,metric2

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

2001:

B:

B:

B:

:

/64,metric2,installed

Serial1/0/FE80:

:

CE00:

3FF:

FE68:

0,expiresin157secs

r2#showipv6ripnext-hops

RIPprocess"cisco",NextHops

FE80:

:

CE00:

3FF:

FE68:

0/Serial1/0[9paths]

r2#

在R3上实现聚合路由:

r3(config)#ints1/0

r3(config-if)#ipv6ripciscosummary-address2001:

3:

3:

:

/48

在R2上查看路由表:

(聚合后的路由)

r2#showipv6routerip

IPv6RoutingTable-9entries

Codes:

C-Connected,L-Local,S-Static,R-RIP,B-BGP

U-Per-userStaticroute

I1-ISISL1,I2-ISISL2,IA-ISISinterarea,IS-ISISsummary

O-OSPFintra,OI-OSPFinter,OE1-OSPFext1,OE2-OSPFext2

ON1-OSPFNSSAext1,ON2-OSPFNSSAext2

R2001:

1:

1:

1:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

3:

3:

:

/48[120/3]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

R2001:

B:

B:

B:

:

/64[120/2]

viaFE80:

:

CE00:

3FF:

FE68:

0,Serial1/0

在RIPng中分发默认路由:

r3(config)#ints1/0

r3(config-if)#ipv6ripciscodefault-informationoriginatemetric5

在R

展开阅读全文
相关资源
猜你喜欢
相关搜索

当前位置:首页 > 初中教育 > 学科竞赛

copyright@ 2008-2022 冰豆网网站版权所有

经营许可证编号:鄂ICP备2022015515号-1