Within all of the practice labs I have worked through for the CCIE Lab exam and in most real world applications I have seen, MPLS networks are run on top of (or within) an OSPF network. Configuring the OSPF and MPLS mesh involves a few steps in my mind:
- Build basic mesh topology with desired IP scheme
- Enable OSPF between all routers
- Enable MPLS globally on all routers
- Enable MPLS on all interfaces within the topology
The first two steps are pretty straight forward, but the last two can be different in how they are handled. I came across this web page: http://www.cisco.com/c/en/us/td/docs/ios/12_0s/feature/guide/fsldpaut.html#wp1053058 This page showed me there are two ways to accomplish the task of enabling MPLS: separately on each interface or protocol wide for all OSPF interfaces.
The first way looks like this:
R1#conf t Enter configuration commands, one per line. End with CNTL/Z. R2(config)#mpls ip R2(config)#int e0/0 R2(config-if)#mpls ip R2(config-if)#int e0/1 R2(config-if)#mpls ip R2(config-if)#int e0/2 R2(config-if)#mpls ip
That is what you would do to enable MPLS globally on the router and on those three specific interfaces.
The other method allows you to enable MPLS on all interfaces that are being used within that specific OSPF process.
R1#conf t Enter configuration commands, one per line. End with CNTL/Z. R1(config)#router ospf 1 R1(config-router)#mpls ldp autoconfig
Each method is valid and will ultimately accomplish the same thing. If you want to watch a video on this actually being implemented, I put a quick video together as well. Watch it below or directly on our YouTube Channel.