Configuring Routing Table Path Selection for BGP

By default, only the multiple exit discriminators (MEDs) of routes that have the same peer autonomous systems (ASs) are compared. You can configure routing table path selection options to get different behaviors.

The third step of the algorithm, by default, evaluates the length of the AS path and determines the active path. You can configure an option that enables the Junos OS to skip this third step of the algorithm by including the as-path-ignore option.

Note: The as-path-ignore option is not supported for routing instances.

For a description of the algorithm used to determine the active path, see How the Active Route Is Determined.

To configure routing table path selection behavior, include the path-selection statement:

path-selection {(always-compare-med | cisco-non-deterministic | external-router-id);as-path-ignore;med-plus-igp {igp-multiplier number;med-multiplier number;}}

For a list of hierarchy levels at which you can include this statement, see the statement summary section for this statement.

Routing table path selection can be configured in one of the following ways:

Note: These two effects cause the system to only sometimes compare the MEDs between paths that it should otherwise compare. Because of this, we recommend that you not configure nondeterministic behavior.