198
Generally BGP only compares MEDs of routes received from the same AS. You can also use
the
compare-different-as-med
command to force BGP to compare MED values of routes
received from different ASs.
•
LOCAL_PREF
The LOCAL_PREF attribute is exchanged between IBGP peers only, and is not advertised to
any other AS. It indicates the priority of a BGP router.
BGP uses LOCAL_PREF to determine the optimal route for traffic leaving the local AS. When a
BGP router obtains multiple routes to the same destination but with different next hops, it
considers the route with the highest LOCAL_PREF value as the optimal route. As shown in
, traffic from AS 20 to AS 10 travels through Router C that is selected according to
LOCAL_PREF.
Figure 54 LOCAL_PREF attribute
•
COMMUNITY
The COMMUNITY attribute identifies the community of BGP routes. A BGP community is a
group of routes with the same characteristics. It has no geographical boundaries. Routes of
different ASs can belong to the same community.
A route can carry one or more COMMUNITY attribute values (each of which is represented by a
4-byte integer). A router uses the COMMUNITY attribute to determine whether to advertise the
route and the advertising scope without using complex filters such as ACLs. This mechanism
simplifies routing policy configuration, management, and maintenance.
Well-known COMMUNITY attributes involve the following:
INTERNET
—By default, all routes belong to the Internet community. Routes with this
attribute can be advertised to all BGP peers.
NO_EXPORT
—Routes with this attribute cannot be advertised out of the local AS or out of
the local confederation, but can be advertised to other sub-ASs in the confederation. For
confederation information, see "
Settlements for problems in large-scale BGP networks
."
No_ADVERTISE
—Routes with this attribute cannot be advertised to other BGP peers.
No_EXPORT_SUBCONFED
—Routes with this attribute cannot be advertised out of the
local AS or other sub-ASs in the local confederation.
You can configure BGP community lists to filter BGP routes based on the BGP COMMUNITY
attribute.
D = 8.0.0.0
Next_hop = 3.1.1.1
Local_pref = 200
D = 8.0.0.0
Next_hop = 2.1.1.1
Local_pref = 100
Local_pref = 200
3.1.1.1
Router B
Router A
Router C
Router D
2.1.1.1
AS 20
AS 10
EBGP
EBGP
IBGP
IBGP
IBGP
Local_pref = 100
8.0.0.0
Содержание HPE FlexNetwork 7500 series
Страница 505: ...493 Connector N A ...