Do you like this site? Remember to share it to all your friends on Facebook and Twitter!

Friday, May 21, 2010

How many subnets are in your network? A quick estimate

A quick method to estimate the total number of subnets in your network.

Seizing the Moment (DSC_0161)
Seizing the Moment (DSC_0161),
originally uploaded by Li-Ji.
We spend quite a lot of time watching the utilization of our network links. How about the total number of network segments, no matter large as LAN segments or small as point-to-point links, in our network?

The total number of network segments is important when we are planning address migration to IPv6. Are there any better ways to estimate, instead of boring counting on the diagram?

The IOS command "show ip route summary" can help us make quick estimate of this number.

Output of command "show ip route summary"

Command "show ip route summary" is used to list number of entries in the routing table, by how the router learned the entries. Here is a example of "show ip route summary" documented on Cisco.com:
"Achieve Optimal Routing and Reduce BGP Memory Consumption"
(in "Background Information" section)















R1# show ip route summary
IP routing table name is Default-IP-Routing-Table(0)
Route Source    Networks    Subnets     Overhead    Memory (bytes)
connected       0           4           256         576
static          0           1           64          144
eigrp 6         0           5           768         720
bgp  XX         80132       18622       6320256     14326656
  External: 87616 Internal: 11138 Local: 0
internal        854                                 994056
Total           80986       18632       6321344     15322152
In this example, IOS tells us that 0 (zero) "networks" and 4 subnets' routing entries learned by "connected" information source. The names "networks" and "subnets" mean:
  • Networks: Classful A/B/C major network routes. That is, the prefix lengths are exactly "/8", "/16", "/24" for Class A, B, and C, respectively.
  • Subnets: Totoal number of subnets within any of Classful A/B/C major networks
Rows of "static", "eigrp (AS) 6", "bgp (AS) XX" are similar.

Some numbers need to explained further:

Row "internal" means the total number of Classful networks not being counted in previously mentioned sources. That is, Classful networks with some subnets in the routing table, but their own major /8, /16, /24 routes are not.

Row "Total" means totals for Networks and Subnets fields, respectively.

Now we can move on to count the number of network segments from the number of routes.

How to count the number of IP network segments?

Here I assume no "route summarizations" are done on routes. In this case, the sum of "non BGP routes" is almost equal to the number of network segments you have in your network.

Counting from the example above, "non BGP" sources are "connected", "static", "eigrp 6", totally 10 network segments (= 0+4 + 0+1 + 0+5 = 10).

BGP should be excluded because normally all those routes learned from BGP are not under your administration. Should you have BGP to distribute internal routes, you might have to add some number back.

If you do not have BGP in your network, then the sum of "Total Networks" and "Total Subnets" is a good estimate of the number of network segments.

To minimize other side effects such as missing routes or route summarization, it is best to do this command on routers near the core area of your network!

Conclusion

We can use IOS's "show ip route summary" command to come up quick estimate of the total number of IP network segments in your network.

I do have a purpose in mind sharing this post. I would like you to spend some time on calculating the number of the network you administer.

I believe in most non-service-provider networks, the total number of IP network segments would be (much) less than 10,000.

What is your number? Share with me in the below comment section!
Do you like this post? You really should consider Subscribing by Email!


Related Posts with Thumbnails

No comments:

Post a Comment

Tip: you can also anonymously comment here.

Popular Posts