Creating Layer 3 Outside Access in Cisco ACI
Last month I wrote about creating layer 2 outside access in Cisco ACI. Perhaps even more necessary is creating layer 3 outside access or even doing both layer 2 and layer 3. It’s likely you’re going to need to connect your ACI fabric to your current network just to get traffic between the two environments. Keep in mind you can also apply policies even to the outside network (outside of ACI) using the APIC, as I talked about in the previous article.
In this article we’ll assume that we’re using OSPF as the dynamic routing protocol, though other routing protocols are allowed with ACI, too. We’ll be creating a connection to a Nexus 5000 switch, with an NSSA area type for the connection to the ACI fabric.
One of the jobs of the spines in the ACI fabric are to act as BGP Route Reflectors. There’s a lot of information out there on Route Reflection, but briefly it is a way to share routing information among all the switches in the fabric. Not every spine needs to be configured as a Route Reflector, but it is a best practice to have two configured for redundancy purposes.
To configure BGP Route Reflectors:
- Login to the APIC
- Click on the Fabric tab
- Expand Fabric Policies
- Expand Pod Policies
- Expand Policies
- Select BGP Route Reflectors Default
- For the Autonomous System Number enter 1 in the pane on the right.
- Click the + button to add Route Reflector Nodes
- Click on the dropdown box to select a spine node ID
- Click Submit twice
To create a pod policy:
- Select Policy Groups under Pod Policy
- Right click on Policy Groups and create a new one
- Give it a name
- Next to BGP Route Reflector Policy select BGP Route Reflectors Default, which is what we selected up in step 6 above.
- Click Submit
- Click on Default under Pod Policies in the tree on the left
- In the dropdown box on the right, select the name that you specified in step 3 for the Fabric Policy Group
- Click Submit
We can now go ahead and configure our layer 3 connection. Keep in mind this will be done on a per tenant basis. So at the top, click on the tenant in which you’d like to create this layer 3 external connection. For our example, we’ll go in to the Production Tenant and we’ll create a connection to a Nexus 5548 switch that lives in our already existing or legacy network.
- In the APIC, click on Tenants
- Click on Production
- Expand Networking in the tree on the left
- Right click on External Routed Networks and select Create Routed Outside
- Enter a name for it such as Production-L3-Out-Prof
- Select OSPF, which is what we’re using in this example
- It by default enters 1 for the OSPF area
- Click the + sign to pick which nodes you’d like to connect
- Click the dropdown next to Private Network and choose the VRF you’ve created
- Click the + sign under Nodes and Interfaces Protocol Profiles
Here you’ll create a Node Profile. When you click on the + sign a new window will pop up.
- Enter a name such as Production-L3-Out-Prof
- Click the + sign under OSPF Interface Profiles to create a new Interface Profile
- Here you’ll use the dropdown menu to show the leaf nodes. Expand the leaf nodes to select the port on the leaf node which will connect to the router in your currently existing network.
- Supply an OSPF Router ID
- Click OK
- Now click on the + sign under OSPF Interface Profiles
- Give it a name such as Production-L3-Out-IntProf
- Click on the + sign to assign routed interfaces
- A new window will appear and you will select a path from the dropdown menu once again. Make sure you expand the leaf and choose an actual port here
- Specify an IP address
- Specify the MTU as well, whether these are regular or jumbo frames
- Click OK twice to complete the tasks
At this point you’ll be back at the initial wizard. You can click Next to specify External EPG Networks. Essentially create this outside connection as an actual End Point Group, which means you can assign policies to it as you would to any EPG within the ACI Fabric. This is a pretty cool thing, because now we can even assign policies to outside objects while we’re migrating from our current network to the ACI fabric.
- Click on the + sign to add and external EPG Network
- Give it a name such as Production-L3-Out-EPG
- Choose the subnet 0.0.0.0/0.0.0.0 to allow any connection. You can narrow this down as needed by subnet
- Click Finish
Now we can go back and check that the Layer 3 external connection has been created by looking under External Routed Networks in the tree on the left.
The layer 3 external access EPG has now been created. With the case of OSPF timers can be very important. Generally speaking, OSPF timers need to be set to the same interval on all devices for communication to happen.
To set OSPF timers in the APIC:
- Expand Private Networks located under Networking in the tree on the left
- Select Production-VRF
- In the right hand pane, under OSPF timers you can enter the correct interval there. You may also select default if your other OSPF timers are set to default in your environment
Next assign your new network to a bridge domain. If you’re unfamiliar with bridge domains in ACI, please see this article.
- Expand Bridge Domains under Networking in the tree on the left
- Select the bridge domain to which you’d like to assign it
- In the pane on the right click the + sign next to Associated L3 Outs
- In the dropdown menu, choose Production-L3-Out
- Click Update
- Click Submit to complete this task
We’ve now completed the layer 3 external connection. Keep in mind no traffic will flow in or out of the ACI fabric until a policy, or Contract, has been created because we’re still using a white list model within ACI. A contract is necessary between two EPGs, even if that EPG is an external Layer 3 EPG. For more information on creating contracts, please see this article.
If you have any questions, as always, please leave them in the comments section or reach out to me on Twitter @Malhoit.