Configuring the default med value – H3C Technologies H3C S12500 Series Switches User Manual

Page 238

Advertising
background image

222

BGP selects a MED value in the following order:

1.

MED set by the apply cost command.

2.

MED set by the med keyword in the import-route command.

3.

MED set by the default med command.

4.

Original MED of a BGP route, or MED changed from the metric of a redistributed IGP route.

Configuring the default MED value

Step Command

Remarks

1.

Enter system view.

system-view

N/A

2.

Enter BGP view or BGP-VPN
instance view.

Enter BGP view:

bgp as-number

Enter BGP-VPN instance view:

a.

bgp as-number

b.

ipv4-family vpn-instance

vpn-instance-name

Use either method.

3.

Configure the default MED
value.

default med med-value

Optional.
0 by default.

Enabling the comparison of MED of routes from different ASs

Step Command

Remarks

1.

Enter system view.

system-view

N/A

2.

Enter BGP view or BGP-VPN
instance view.

Enter BGP view:

bgp as-number

Enter BGP-VPN instance view:

a.

bgp as-number

b.

ipv4-family vpn-instance

vpn-instance-name

Use either method.

3.

Enable the comparison of
MED of routes from different

Ass.

compare-different-as-med

Not enabled by default.

Enabling the comparison of MEDs for routes on a per-AS basis

Route learning sequence might affect optimal route selection.

Advertising