Cisco Support Community
cancel
Showing results for 
Search instead for 
Did you mean: 
Community Member

ip ospf cost


I will implement using OSPF cost higher for the best path, How does impact the OSPF network if increased value ip ospf cost, effect on latency & bandwidth?? below existing configuration. All interface Gigabits default cost "1", what is recommended configure the OSPF cost metric for the interface?

CORE4.5K-HO-TBP-01#sh ip ospf  interface  brief 
Interface    PID   Area            IP Address/Mask    Cost  State Nbrs F/C
Vl11         1     0               10.100.8.252/24    1     DR    2/2
Vl19         1     0               10.100.9.2/30      1     DR    1/1
Vl147        1     0               10.100.12.1/24     1     DR    0/0
Vl18         1     0               10.100.22.5/24     1     DR    1/1
Vl17         1     0               10.100.20.1/24     1     DR    1/1
Vl16         1     0               10.100.18.1/24     1     DR    1/1
Vl15         1     0               10.100.17.1/24     1     DR    1/1
Vl14         1     0               10.100.16.4/24     1     DR    1/1
Vl13         1     0               10.100.15.1/24     1     DR    1/1
Vl12         1     0               10.100.13.1/24     1     DR    1/1
Vl9          1     0               10.100.11.1/24     1     DR    1/1
Vl114        1     0               192.168.10.1/24    1     DR    0/0
Gi2/44       1     0               172.16.0.6/30      1     DR    0/0
Vl222        1     0               10.100.222.1/24    1     DR    1/1
Vl220        1     0               10.100.220.1/24    1     DR    1/1
Vl218        1     0               10.100.218.1/24    1     DR    0/0
Vl217        1     0               10.100.217.1/24    1     DR    1/1
Vl212        1     0               10.100.212.1/24    1     DR    1/1
Vl206        1     0               10.100.206.1/24    1     DR    1/1
Vl205        1     0               10.100.205.1/24    1     DR    1/1
Vl203        1     0               10.100.203.1/24    1     DR    1/1
Vl202        1     0               10.100.202.1/24    1     DOWN  0/0
Vl201        1     0               10.100.201.1/24    1     DR    1/1
Gi2/43       1     0               10.100.100.2/29    1     BDR   1/1
Vl146        1     0               10.100.41.1/29     1     DR    0/0
Vl21         1     0               10.100.21.1/25     1     DR    0/0
Vl10         1     0               10.100.10.253/24   1     BDR   2/2
Vl5          1     0               10.100.5.1/25      1     DR    0/0
Vl4          1     0               10.100.4.253/24    1     DR    0/0
Vl3          1     0               10.100.3.253/24    1     DR    0/0
Vl2          1     0               10.100.2.253/24    1     DR    0/0
Vl8          1     0               10.100.1.1/25      1     DR    0/0
Vl302        1     0               10.45.3.253/24     1     DR    0/0
Vl301        1     0               10.45.1.253/24     1     DR    0/0

Thanks,

Rohmat

5 REPLIES
Community Member

Hey Rohmat.tri.OSPF

Hey Rohmat.tri.

OSPF calculates the cost this way: Reference bandwidth / Interface bandwidth. It'll select the lowest cost link. So if you have a 1Gbit link and a reference of 10.000 you'd calculate it this way: 10.000/1000 = 10. A 100Mbit link would have a cost of 10.000/100 = 100. If multiple paths to the same destination exists in the OSPF database it'll automatically load-balance between them, if the links are up. 

Both are values which you can change. I like to set my reference cost to 100.000 (100Gbit) for future profing of the links, so you don't have to change the reference again. You can set the reference bandwidth with this command in OSPF configuration mode: "auto-cost reference-bandwidth xx".

You can manually change the OSPF cost directly on the interface: "ip ospf cost xx". This will override the calculated value. 

To manually change the bandwidth used for calculation on the interface you'll use this interface command: "bandwidth xxxxx

Hope this helps

Jacob Hee Malling

Community Member

Ok jacobmalling, thanks for

Ok jacobmalling, thanks for response

Cost = Reference Bandwidth/Interface Bandwidth what does it mean same calculation this way => Interface Bandwidth = Reference Bandwidth/Cost ????

if i can mannually change the ospf directly on interface :"ip ospf cost", will affect data transfer rate?

Regards,

Rohmat

Hall of Fame Super Gold

Rohmat Changing the OSPF cost

Rohmat

 

Changing the OSPF cost does not do anything directly that would affect data transfer rate. The capacity of the interface remains the same no matter what you set as cosst. If you set the OSPF cost and that change causes OSPF to choose a different path through the network then obviously the data transfer rate might be affected.

 

HTH

 

Rick

Community Member

Mr Richard,Thanks a lot, your

Mr Richard,

Thanks a lot, your explanations were really useful.

Regards,

Rohmat

Super Bronze

DisclaimerThe Author of this

Disclaimer

The Author of this posting offers the information contained within this posting without consideration and with the reader's understanding that there's no implied or expressed suitability or fitness for any purpose. Information provided is for informational purposes only and should not be construed as rendering professional advice of any kind. Usage of this posting's information is solely at reader's own risk.

Liability Disclaimer

In no event shall Author be liable for any damages whatsoever (including, without limitation, damages for loss of use, data or profit) arising out of the use or inability to use the posting's information even if Author has been advised of the possibility of such damage.

Posting

Thought I might clarify Jacob's "OSPF calculates the cost this way: Reference . . ."  To be more precise, that's how Cisco devices usually compute interface OSPF cost.  Other vendor equipment might not auto calculate OSPF interface cost at all, or they might use a different default reference bandwidth.

Also regarding Jacob's suggestion to set reference bandwidth to 100G, that's fine, but be aware that you might lose path costing differences for low bandwidth links. OSPF sums up hop by hop link costs to reach destination.  Such a sum can "overflow" if OPSF is summing using a 16 bit counter and sum is greater than 65K.

So, when deciding on changing the auto-cost reference-bandwidth, you may need to consider both maximum and minimum bandwidths on your network, now and perhaps future.

760
Views
0
Helpful
5
Replies
CreatePlease to create content