Manual Summaries and the AS_PATH Path Attribute
The aggregate route must include the AS_PATH PA, just like it is required for every other NLRI in the BGP table. However, to fully understand what this command does, you need to take a closer look at the AS_PATH PA.
The AS_PATH PA consists of up to four different components, called segments, as follows:
■ AS_SEQ (short for AS Sequence)
■ AS_SET
■ AS_CONFED_SEQ (short for AS Confederation Sequence)
■ AS_CONFED_SET
The most commonly used segment is called AS_SEQ. AS_SEQ is the idea of AS_PATH as shown back in Figure 12-1, with the PA representing all ASNs, in order, through which the route has been advertised.
However, the aggregate-address command can create a summary route for which the AS_SEQ must be null. When the component subnets of the summary route have differing AS_SEQ values, the router simply can’t create an accurate representation of AS_SEQ, so it uses a null AS_SEQ. However, this action introduces the possibility of creating routing loops, because the contents of AS_PATH, specifically AS_SEQ, are used to prevent a route from being re-advertised to an AS that has already heard about the route.
The AS_PATH AS_SET segment solves the problem when the summary route has a null AS_SEQ. The AS_SET segment holds an unordered list of all the ASNs in all the component subnets’ AS_SEQ segments. Example 12-7 shows an example in which the router does use a null AS_SEQ for a summary route, and then the same summary with the as-set option creating the AS_SET segment.
NOTE
AS_PATH includes the AS_CONFED_SEQ and AS_CONFED_SET segments as well, which are covered later, in the section “Confederations.” The following list summarizes the actions taken by the aggregate-address command when it creates a summary route:
■ It does not create the summary if the BGP table does not currently have any routes for NLRI inside the summary.
■ If all the component subnets are withdrawn from the aggregating router’s BGP table, it also then withdraws the aggregate. (In other words, the router tells its neighbors that the aggregate route is no longer valid.)
■ It sets the NEXT_HOP address of the summary, as listed in the local BGP table, as 0.0.0.0.
■ It sets the NEXT_HOP address of the summary route, as advertised to neighbors, to the router’s update source IP address for each neighbor, respectively.
■ If the component subnets inside the summary all have the same AS_SEQ, it sets the new summary route’s AS_SEQ to be exactly like the AS_SEQ of the component subnets.
■ If the AS_SEQ of the component subnets differs in any way, it sets the AS_SEQ of the new summary route to null.
■ When the as-set option has been configured, the router creates an AS_SET segment for the aggregate route, but only if the summary route’s AS_SEQ is null.
■ As usual, if the summary is advertised to an eBGP peer, the router prepends its own ASN to the AS_SEQ before sending the Update.
■ It suppresses the advertisement of all component subnets if the summary-only keyword is used; advertises all of them if the summary-only keyword is omitted; or advertises a subset if the suppress-map option is configured. (Refer to Chapter 13 for an example of using the suppress-map option.)
Example 12-7 shows R3 from Figure 12-4 summarizing 23.0.0.0/8. R3 advertises the summary with ASN 123 as the only AS in the AS_SEQ, because some component subnets have AS_PATHS of 45, and others have 678 45. As a result, R3 uses a null AS_SEQ for the aggregate. The example goes on to show the impact of the as-set option.
Example 12-7 Route Aggregation and the as-set Option



NOTE
Summary routes can also be added via another method. First, the router would create a static route, typically with destination of interface null0. Then, the prefix/length can be matched with the network command to inject the summary. This method does not filter any of the component subnets.
Table 12-6 summarizes the key points regarding summarization using the aggregate-address, auto-summary, and network commands.
Table 12-6 Summary: Injecting Summary Routes in BGP




