8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area (Answers)

Packet Tracer Packet Tracer Labs Original source

8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area (Answers)

Topology

8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area

8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area

Addressing Table

Device Interface IP Address Subnet Mask
R1 G0/0 172.16.1.1 255.255.255.0
S0/0/0 172.16.3.1 255.255.255.252
S0/0/1 192.168.10.5 255.255.255.252
R2 G0/0 172.16.2.1 255.255.255.0
S0/0/0 172.16.3.2 255.255.255.252
S0/0/1 192.168.10.9 255.255.255.252
R3 G0/0 192.168.1.1 255.255.255.0
S0/0/0 192.168.10.6 255.255.255.252
S0/0/1 192.168.10.10 255.255.255.252
PC1 NIC 172.16.1.2 255.255.255.0
PC2 NIC 172.16.2.2 255.255.255.0
PC3 NIC 192.168.1.2 255.255.255.0

Objectives

Background

In this activity, the IP addressing is already configured. You are responsible for configuring the three router topology with basic single area OSPFv2 and then verifying connectivity between end devices.

Note: The topology is the same one used in the chapter examples. In addition, the student practiced the configuration of this topology in the Syntax Checker activities. Therefore, the student should be able to complete this activity with minimal assistance.

Instructions

Part 1: Configure OSPFv2 Routing

Step 1: Configure OSPF on the R1, R2 and R3.

Use the following requirements to configure OSPF routing on all three routers:

Part 2: Verify the Configurations

Step 2: Verify OSPF routing is operational.

On each router, the routing table should now have a route to every network in the topology.

Copy

R1# show ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

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

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       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, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route



Gateway of last resort is not set



     172.16.0.0/16 is variably subnetted, 5 subnets, 3 masks

C       172.16.1.0/24 is directly connected, GigabitEthernet0/0

L       172.16.1.1/32 is directly connected, GigabitEthernet0/0

O       172.16.2.0/24 [110/65] via 172.16.3.2, 00:06:25, Serial0/0/0

C       172.16.3.0/30 is directly connected, Serial0/0/0

L       172.16.3.1/32 is directly connected, Serial0/0/0

O    192.168.1.0/24 [110/65] via 192.168.10.6, 00:06:25, Serial0/0/1

     192.168.10.0/24 is variably subnetted, 3 subnets, 2 masks

C       192.168.10.4/30 is directly connected, Serial0/0/1

L       192.168.10.5/32 is directly connected, Serial0/0/1

O       192.168.10.8/30 [110/128] via 172.16.3.2, 00:06:25, Serial0/0/0

                        [110/128] via 192.168.10.6, 00:06:25, Serial0/0/1

Copy

R2# show ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

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

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       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, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route



Gateway of last resort is not set



     172.16.0.0/16 is variably subnetted, 5 subnets, 3 masks

O       172.16.1.0/24 [110/65] via 172.16.3.1, 00:06:31, Serial0/0/0

C       172.16.2.0/24 is directly connected, GigabitEthernet0/0

L       172.16.2.1/32 is directly connected, GigabitEthernet0/0

C       172.16.3.0/30 is directly connected, Serial0/0/0

L       172.16.3.2/32 is directly connected, Serial0/0/0

O    192.168.1.0/24 [110/65] via 192.168.10.10, 00:06:41, Serial0/0/1

     192.168.10.0/24 is variably subnetted, 3 subnets, 2 masks

O       192.168.10.4/30 [110/128] via 172.16.3.1, 00:06:31, Serial0/0/0

                        [110/128] via 192.168.10.10, 00:06:31, Serial0/0/1

C       192.168.10.8/30 is directly connected, Serial0/0/1

L       192.168.10.9/32 is directly connected, Serial0/0/1

Copy

R3# show ip route

Codes: L - local, C - connected, S - static, R - RIP, M - mobile, B - BGP

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

       N1 - OSPF NSSA external type 1, N2 - OSPF NSSA external type 2

       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, ia - IS-IS inter area

       * - candidate default, U - per-user static route, o - ODR

       P - periodic downloaded static route



Gateway of last resort is not set



     172.16.0.0/16 is variably subnetted, 3 subnets, 2 masks

O       172.16.1.0/24 [110/65] via 192.168.10.5, 00:06:48, Serial0/0/0

O       172.16.2.0/24 [110/65] via 192.168.10.9, 00:06:48, Serial0/0/1

O       172.16.3.0/30 [110/128] via 192.168.10.5, 00:06:48, Serial0/0/0

                      [110/128] via 192.168.10.9, 00:06:48, Serial0/0/1

     192.168.1.0/24 is variably subnetted, 2 subnets, 2 masks

C       192.168.1.0/24 is directly connected, GigabitEthernet0/0

L       192.168.1.1/32 is directly connected, GigabitEthernet0/0

     192.168.10.0/24 is variably subnetted, 4 subnets, 2 masks

C       192.168.10.4/30 is directly connected, Serial0/0/0

L       192.168.10.6/32 is directly connected, Serial0/0/0

C       192.168.10.8/30 is directly connected, Serial0/0/1

L       192.168.10.10/32 is directly connected, Serial0/0/1
Step 3: Verify the Configurations

Each PC should be able to ping the other two PCs. If not, check your configurations.

Copy

C:\> ping 172.16.2.2



Pinging 172.16.2.2 with 32 bytes of data:



Request timed out.

Reply from 172.16.2.2: bytes=32 time=2ms TTL=126

Reply from 172.16.2.2: bytes=32 time=3ms TTL=126

Reply from 172.16.2.2: bytes=32 time=2ms TTL=126



Ping statistics for 172.16.2.2:

    Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),

Approximate round trip times in milli-seconds:

    Minimum = 2ms, Maximum = 3ms, Average = 2ms

Copy

C:\> ping 192.168.1.2



Pinging 192.168.1.2 with 32 bytes of data:



Request timed out.

Reply from 192.168.1.2: bytes=32 time=2ms TTL=126

Reply from 192.168.1.2: bytes=32 time=2ms TTL=126

Reply from 192.168.1.2: bytes=32 time=2ms TTL=126



Ping statistics for 192.168.1.2:

    Packets: Sent = 4, Received = 3, Lost = 1 (25% loss),

Approximate round trip times in milli-seconds:

    Minimum = 2ms, Maximum = 2ms, Average = 2ms

Device Configs - Final

ROUTER R1

Copy

! ==============================================================

!--- 8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area

!--- ANSWER SCRIPT FOR ROUTER R1

!--- Usage: copy this whole file and paste it into the R1 terminal (start at the R1> prompt). Every line beginning with "!" is a comment; IOS ignores it, so pasting a comment by accident is harmless.

!--- Scope: IP addressing is already configured on all three routers

!--- per the activity's own Background note - this script only adds

!--- OSPFv2 routing.

! ==============================================================



enable

configure terminal



! --------------------------------------------------------------

!--- Part 1: Configure OSPFv2 (process ID 10) on R1.

! --------------------------------------------------------------



router ospf 10



!--- Explicit router ID, as required, instead of letting OSPF pick one

!--- from the highest loopback/interface address.

 router-id 1.1.1.1



!--- LAN 1 (G0/0, 172.16.1.0/24).

 network 172.16.1.0 0.0.0.255 area 0



!--- Serial link to R2 (S0/0/0, 172.16.3.0/30).

 network 172.16.3.0 0.0.0.3 area 0



!--- Serial link to R3 (S0/0/1, 192.168.10.4/30).

 network 192.168.10.4 0.0.0.3 area 0



!--- LAN interface must be passive - no routers live on that segment,

!--- so R1 shouldn't send Hellos out of it. Named explicitly (not

!--- "passive-interface default") per the activity's requirement.

 passive-interface GigabitEthernet0/0

 exit



end



! --------------------------------------------------------------

!--- Save the configuration to NVRAM. (Press Enter when prompted for the destination filename.)

! --------------------------------------------------------------

copy running-config startup-config





! ==============================================================

!--- Verification:

!---   show ip ospf neighbor       -> FULL adjacency with R2 (172.16.3.2) and R3 (192.168.10.6)

!---   show ip route ospf          -> routes to 172.16.2.0/24 and 192.168.1.0/24 via OSPF (O)

!---   show ip protocols           -> Router ID 1.1.1.1, passive interface GigabitEthernet0/0

!---   ping 172.16.2.2 / ping 192.168.1.2  -> PC2 and PC3, once OSPF has converged

! ==============================================================

ROUTER R2

Copy

! ==============================================================

!--- 8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area

!--- ANSWER SCRIPT FOR ROUTER R2

!--- Usage: copy this whole file and paste it into the R2 terminal (start at the R2> prompt). Every line beginning with "!" is a comment; IOS ignores it, so pasting a comment by accident is harmless.

!--- Scope: IP addressing is already configured on all three routers

!--- per the activity's own Background note - this script only adds

!--- OSPFv2 routing.

! ==============================================================



enable

configure terminal



! --------------------------------------------------------------

!--- Part 1: Configure OSPFv2 (process ID 10) on R2.

! --------------------------------------------------------------



router ospf 10



!--- Explicit router ID, as required.

 router-id 2.2.2.2



!--- LAN 2 (G0/0, 172.16.2.0/24).

 network 172.16.2.0 0.0.0.255 area 0



!--- Serial link to R1 (S0/0/0, 172.16.3.0/30).

 network 172.16.3.0 0.0.0.3 area 0



!--- Serial link to R3 (S0/0/1, 192.168.10.8/30).

 network 192.168.10.8 0.0.0.3 area 0



!--- LAN interface must be passive - named explicitly (not

!--- "passive-interface default") per the activity's requirement.

 passive-interface GigabitEthernet0/0

 exit



end



! --------------------------------------------------------------

!--- Save the configuration to NVRAM. (Press Enter when prompted for the destination filename.)

! --------------------------------------------------------------

copy running-config startup-config





! ==============================================================

!--- Verification:

!---   show ip ospf neighbor       -> FULL adjacency with R1 (172.16.3.1) and R3 (192.168.10.10)

!---   show ip route ospf          -> routes to 172.16.1.0/24 and 192.168.1.0/24 via OSPF (O)

!---   show ip protocols           -> Router ID 2.2.2.2, passive interface GigabitEthernet0/0

!---   ping 172.16.1.2 / ping 192.168.1.2  -> PC1 and PC3, once OSPF has converged

! ==============================================================

ROUTER R3

Copy

! ==============================================================

!--- 8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area

!--- ANSWER SCRIPT FOR ROUTER R3

!--- Usage: copy this whole file and paste it into the R3 terminal (start at the R3> prompt). Every line beginning with "!" is a comment; IOS ignores it, so pasting a comment by accident is harmless.

!--- Scope: IP addressing is already configured on all three routers

!--- per the activity's own Background note - this script only adds

!--- OSPFv2 routing.

! ==============================================================



enable

configure terminal



! --------------------------------------------------------------

!--- Part 1: Configure OSPFv2 (process ID 10) on R3.

! --------------------------------------------------------------



router ospf 10



!--- Explicit router ID, as required.

 router-id 3.3.3.3



!--- LAN 3 (G0/0, 192.168.1.0/24).

 network 192.168.1.0 0.0.0.255 area 0



!--- Serial link to R1 (S0/0/0 on R3, 192.168.10.4/30).

 network 192.168.10.4 0.0.0.3 area 0



!--- Serial link to R2 (S0/0/1 on R3, 192.168.10.8/30).

 network 192.168.10.8 0.0.0.3 area 0



!--- LAN interface must be passive - named explicitly (not

!--- "passive-interface default") per the activity's requirement.

 passive-interface GigabitEthernet0/0

 exit



end



! --------------------------------------------------------------

!--- Save the configuration to NVRAM. (Press Enter when prompted for the destination filename.)

! --------------------------------------------------------------

copy running-config startup-config





! ==============================================================

!--- Verification:

!---   show ip ospf neighbor       -> FULL adjacency with R1 (192.168.10.5) and R2 (192.168.10.9)

!---   show ip route ospf          -> routes to 172.16.1.0/24 and 172.16.2.0/24 via OSPF (O)

!---   show ip protocols           -> Router ID 3.3.3.3, passive interface GigabitEthernet0/0

!---   ping 172.16.1.2 / ping 172.16.2.2  -> PC1 and PC2, once OSPF has converged

!--- Note: on the R1-R3 link, R1 uses S0/0/1 while R3 uses S0/0/0 for the

!--- same 192.168.10.4/30 subnet - that's just how the two routers'

!--- serial ports happen to be wired/numbered in this topology, not a

!--- config error; the "network" statement only cares about the address

!--- range, not the local interface name.

! ==============================================================

Download 8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area .PKA file:

Icon

8.2.1 Packet Tracer - Configure OSPFv2 in a Single Area .PKA

1 file(s) 283.76 KB

Download

Previous Lab
6.2.1 Packet Tracer – Configure IPv4 and IPv6 Static and Default Routes

Next Lab
9.2.1 Packet Tracer – Implement Multiarea OSPFv2

← All Packet Tracer articles Home