BGP MED: Inbound Traffic Engineering (NX-OS Lab)

The BGP MED (Multi-Exit Discriminator) attribute is the primary tool for influencing inbound traffic paths when your data center fabric has multiple connections to an external autonomous system. Without a deterministic policy in place, leaving path selection to BGP’s default tie-breakers often leads to asymmetric routing.

In this guide, we break down the core function and mechanics of the MED attribute. Then we jump straight to the command line for a lab demonstration on Cisco Nexus switches to configure our route maps and verify metric changes in the NX-OS BGP table.

Summary

FeatureDescription
Is it a PA?Yes, optional non-transitive.
PurposeAllows an AS to tell a neighboring AS the best way to forward packets into the first AS.
ScopeAdvertised by one AS into another, propagated inside the AS, but not sent to any other ASes.
Defaultnot set (Null).
Changing the defaultUsing the bestpath med missing-as-worst BGP subcommand sets it to the maximum value.
Range0 through 4,294,967,295 (232 – 1)
Which is best?Smaller is better.
ConfigurationThrough the neighbor route-map out command, using the set metric command inside the route map. Or use set metric-type internal to link the MED value to the IGP metric of the route’s next hop.

Looking for Comprehensive Cisco Data Center Training?

Take your data center skills to the next level with my deep-dive courses, designed for real-world application.

Modern DC Architecture & Automation (Self-paced Courses):


Core Protocols & CCIE Prep (Self-paced Courses):


Live Intensive Training (Cohorts):

Need Personalized Guidance (1:1 Mentorship)?

Additional Resources:
BGP Path Attributes: Your BGP Path Selection Master Guide

author avatar
Salman Alhiary Expert Network Consultant
In the networking field since 2010, 2× CCIE (ENT & DC), and founder of LearnWithSalman—specializes in Cisco Data Center networking and automation. A former Cisco TAC engineer and now an Expert Professional Services consultant, he delivers lab-first tutorials, deep templates, and repeatable playbooks through his courses and technical blog, all built from real enterprise projects.
0 0 votes
Article Rating
Subscribe
Notify of
guest

0 Comments
Newest
Oldest Most Voted
Scroll to Top