howtonetwork.net

Cisco Certification Training

  • Products
  • CCNA
    • CCNA Videos
    • CCNA Lectures
    • CCNA Practice Exams
    • Challenge Labs
      • Challenge Video Solutions
    • Cisco Commands
  • CCNP ROUTE
    • ROUTE Exams
  • CCNP SWITCH
    • SWITCH Exams
  • CCNP TSHOOT
  • Home
  • Join
  • Downloads
  • About Us
  • Whitepapers
  • Feature Articles
  • Helpdesk
  • FAQ
  • Free Training
You are here: Home / distance ospf

distance ospf

Command

Distance OSPF

Use

This command changes the administrative distance for OSPF routes.

Syntax

Router(config-router)#distance ospf <intra-area distance><inter-area distance><external distance>

Example

distance ospf

In this example, we will change OSPF administrative distance to 150 for internal routes and 220 for external. Currently, we see OSPF is at its default administrative distance of 110.

R1(config-router)#do show ip route ospf
33.0.0.0/32 is subnetted, 1 subnets
O 33.33.33.33 [110/65] via 192.168.13.2, 00:01:05, Serial1/1
3.0.0.0/32 is subnetted, 1 subnets
O 3.3.3.3 [110/65] via 192.168.13.2, 00:01:05, Serial1/1
10.0.0.0/24 is subnetted, 3 subnets
O 10.2.2.0 [110/65] via 192.168.13.2, 00:01:05, Serial1/1
133.133.0.0/32 is subnetted, 1 subnets
O 133.133.133.133 [110/65] via 192.168.13.2, 00:01:05, Serial1/1

Here, we change the distance with the distance ospf command.

R1(config)#router ospf 1
R1(config-router)#distance ospf intra-area 150 inter
R1(config-router)#distance ospf intra-area 150 inter-area 150 ex
R1(config-router)#distance ospf intra-area 150 inter-area 150 external 220
R1(config-router)#exit

Now, we can see the change is reflected in the routing table.

R1(config)#do show ip route ospf
33.0.0.0/32 is subnetted, 1 subnets
O 33.33.33.33 [150/65] via 192.168.13.2, 00:00:06, Serial1/1
3.0.0.0/32 is subnetted, 1 subnets
O 3.3.3.3 [150/65] via 192.168.13.2, 00:00:06, Serial1/1
10.0.0.0/24 is subnetted, 3 subnets
O 10.2.2.0 [150/65] via 192.168.13.2, 00:00:06, Serial1/1
133.133.0.0/32 is subnetted, 1 subnets
O 133.133.133.133 [150/65] via 192.168.13.2, 00:00:06, Serial1/1

Get access to over 5 hours of IT webinar videos as well as regular study tips and ideas when you
join our mailing list

About This Site

We replaced this site some time ago with an upgraded version. Please feel free to enjoy the content and if you like what you see check out our brilliant new site:

howtonetwork.com

Keep In Touch

About Us

This is a free access website which has now been replaced by howtonetwork.com.

Navigation

  • Home
  • Join
  • Downloads
  • About Us
  • Whitepapers
  • Feature Articles
  • Helpdesk
  • FAQ
  • Free Training

Copyright

All content is protected by international copyright laws. Copyright Reality Press Ltd.

Copyright © 2023 · Dynamik Website Builder on Genesis Framework · WordPress · Log in