You want to summarize your routing table before forwarding it to another router.
BGP includes an automatic summarization feature that is on by default:
configure terminalEnter configuration commands, one per line. End with CNTL/Z. Router1(config)#
router bgp65500 Router1(config-router)#
By default, BGP will try to summarize routes. This is not always desirable, though, which is why we have explicitly disabled this feature in many of the examples in this chapter. In fact, many engineers prefer to manually summarize their routing tables because they want to control what gets summarized and what doesn’t.
The first problem with auto-summarization is that it is strictly classful. Your AS may not control all of the subnets in a classful network, and even if you do, this may not be the most useful prefix on which to summarize your networks. The second problem is that autosummarization only works on routes that are redistributed into BGP, and not on routes from BGP or routes injected via the network command. Please refer to Recipe 9.14 for more information on redistributing routes into BGP.
Suppose you wanted to summarize several routes to a single nonclassful route, or to summarize routes from several downstream BGP networks. You might be tempted to handle this by redistributing a static route ...