local-preference
Syntax
local-preferencelocal-preference;Hierarchy Level
[edit protocols bgp],[edit protocols bgpgroupgroup-name],[edit protocols bgp groupgroup-nameneighboraddress],[edit routing-instancesrouting-instance-nameprotocols bgp],[edit routing-instancesrouting-instance-nameprotocols bgpgroupgroup-name],[edit routing-instancesrouting-instance-nameprotocols bgp groupgroup-name
neighboraddress]Description
Modify the value of the
LOCAL_PREFpath attribute, which is a metric used by internal BGP sessions to indicate the degree of preference for an external route. The route with the highest local preference value is preferred.The
LOCAL_PREFpath attribute always is advertised to internal BGP peers and to neighboring confederations. It is never advertised to external BGP peers.Default
If you do omit this statement, the
LOCAL_PREFpath attribute, if present, is not modified.Options
local-preference—Preference to assign to routes learned from BGP or from the group or peer.
Range: 0 through 4,294,967,295 (232 -1)
Default: If theLOCAL_PREFpath attribute is present, do not modify its value. If a BGP route is received without aLOCAL_PREFattribute, the route is handled locally (it is stored in the routing table and advertised by BGP) as if it were received with aLOCAL_PREFvalue of 100. A non-BGP route that is advertised by BGP is advertised with aLOCAL_PREFvalue of 100 by default.Usage Guidelines
See Configure the BGP Local Preference.
Required Privilege Level
routing—To view this statement in the configuration.
routing-control—To add this statement to the configuration.See Also