Skip to main content

DMVPN - Key concepts

 DMVPN (Dynamic Multipoint Virtual Private Network)

DMVPN enables dynamic and scalable VPN connections, primarily using mGRE (Multipoint Generic Routing Encapsulation), NHRP (Next Hop Resolution Protocol), and optionally, IPsec for encryption. It supports hub-and-spoke topologies, with the ability to evolve into a fully meshed network.

DMVPN Phases

  1. Phase 1:
    • Basic hub-and-spoke topology where spokes communicate through the hub.
    • mGRE is configured on the hub, and point-to-point GRE on the spokes.
    • Limitation: No direct spoke-to-spoke communication; all traffic passes through the hub.
    • Routing: Spokes register their IP with the hub, and no spoke-to-spoke tunnels are formed.
  2. Phase 2:
    • Introduces spoke-to-spoke communication using mGRE at both the hub and spokes.
    • Next-hop reachability is maintained, and spokes dynamically form tunnels to communicate directly.
    • No route summarization allowed, and the hub doesn’t originate default routes.
    • EIGRP: Requires no split-horizon and no next-hop-self on the hub to preserve next-hop information across spokes.
  3. Phase 3:
    • Improved scalability with route summarization and default routing at the hub.
    • NHRP redirects allow spokes to resolve and create direct spoke-to-spoke tunnels without routing through the hub.
    • Routing: Spokes look up the NHRP table and create dynamic tunnels when needed.
    • Summary: Most efficient phase, allowing default routing and spoke-to-spoke communication without burdening the hub.

DMVPN Key Components

  • NHRP: Works like ARP but maps private (VPN) IPs to public (NBMA) IPs, enabling dynamic tunnel creation.
  • mGRE: Allows multiple endpoints on the same interface, unlike point-to-point GRE which is tied to a single destination.
  • EIGRP: Commonly used due to manual summarization and scalability, though OSPF and BGP can also be used.
  • IPsec: Optional, adds encryption for secure tunnels.
    • Phases involve IKE (Internet Key Exchange) for negotiating keys and establishing IPsec Security Associations (SAs).

Key Features and Configuration Tips

  • Tunnels: Stateless, meaning they come up without requiring configuration on the other end.
  • mGRE MTU: Requires adjusting MTU size (commonly 1476) due to additional GRE headers.
  • NHRP Holdtime: Configured on spokes (recommended holdtime is 600 seconds).
  • IPsec Tunnel Protection: Use the tunnel protection ipsec profile command to apply IPsec to DMVPN tunnels.
  • EIGRP Split-Horizon: Disable split-horizon and next-hop-self to ensure proper route advertisement in hub-and-spoke designs.

DMVPN Troubleshooting

  • Commands:
    • show dmvpn: View active DMVPN connections.
    • show ip nhrp: Inspect NHRP mappings.
  • Spoke-to-Spoke Issues: Ensure NHRP mappings are correct and check if spoke-to-spoke tunnels are being triggered by hub redirects.
  • EIGRP Flapping: If adjacency keeps going up and down, ensure multicast support is configured correctly.

DMVPN Use Cases

  • Phase 1: Simple hub-and-spoke topology where spokes communicate only through the hub.
  • Phase 2: Introduces spoke-to-spoke tunnels, improving efficiency in scenarios where direct communication is necessary.
  • Phase 3: Ideal for large-scale deployments, allowing summarization, default routes, and scalable spoke-to-spoke communication.

DMVPN Technical Tips:

  1. NHRP (Next Hop Resolution Protocol):
    • Works like ARP but maps VPN IP to public IP, enabling dynamic spoke-to-spoke tunnels.
    • NHRP holdtime should be set to 600 seconds as recommended by Cisco.
    • Use ip nhrp redirect on the hub and ip nhrp shortcut on spokes for Phase 3 configuration.
  2. mGRE (Multipoint Generic Routing Encapsulation):
    • Allows for multi-point site connectivity without needing separate GRE tunnels for each spoke.
    • MTU size should be adjusted to 1476 to accommodate the 24-byte overhead for GRE headers.
  3. EIGRP Configurations:
    • Disable split-horizon (no ip split-horizon eigrp <AS-Number>) on hub interfaces to prevent routing issues between spokes.
    • Use no ip next-hop-self to preserve next-hop information between spokes in Phase 2.
  4. Tunnels:
    • Tunnels are stateless: They come up even if the other side is not yet configured, simplifying initial setup.
    • mGRE tunnels are used on both the hub and spokes starting from Phase 2 to support dynamic spoke-to-spoke tunnels.
  5. IPsec Configuration:
    • Use tunnel protection ipsec profile to secure DMVPN tunnels with IPsec.
    • IPsec encryption adds a layer of security, and the key exchange protocol (IKEv1 or IKEv2) should be properly configured.
  6. Routing Protocols:
    • EIGRP is commonly used due to its support for summarization and ease of configuration.
    • OSPF requires careful configuration because it does not handle split-horizon the same way and introduces complexity with next-hop issues.
  7. DMVPN Phase-Specific Tips:
    • Phase 1: Use GRE on spokes and mGRE on hubs. No direct spoke-to-spoke tunnels.
    • Phase 2: mGRE on both hub and spokes allows direct spoke-to-spoke communication.
    • Phase 3: Enable ip nhrp redirect (hub) and ip nhrp shortcut (spokes) to optimize routing and allow spoke-to-spoke communication directly.

DMVPN Troubleshooting Tips:

  1. Flapping EIGRP adjacencies:
    • Ensure multicast capability is enabled (e.g., ip nhrp map multicast), especially on NBMA networks.
  2. Spoke-to-Spoke Tunnel Issues:
    • Verify NHRP mappings and ensure spoke-to-spoke tunnels are triggered by NHRP redirects from the hub.
    • Check the NHRP cache using show ip nhrp to ensure correct resolution of spokes.
  3. IPsec Tunnel Issues:
    • Use show crypto isakmp sa and show crypto ipsec sa to verify IPsec tunnel establishment and troubleshoot encryption problems.

Comments

Popular posts from this blog

How to import Putty Saved Connections to mRemoteNG

Just started using mRemoteNG and its being very cool to connect to different remote connection with different protocols e.g Window Remote Desktop, VNC to Linux, SSH, HTTP connection etc. from a single application. As new user I configured some remote desktop connection which was quite easy to figure out. But when I wanted to add SSH connections, it came in my mind to import all of the saved connections in the putty. But I couldn't figure it out how can it be done, though it was quite easy and here are the steps. Open your mRemoteNG Create a folder if you want segregation of multiple networks Create a new connection Enter the IP address of remote server under connection in Config pane Under the config pane, select protocol " SSH version 2 ".  Once you select protocol to SSH version 2 you are given option to import putty sessions, as shown in the snap below. In the above snap, I have imported CSR-AWS session from my saved sessions in Putty.

Authoritative DNS Servers Delegation and Internal DNS Explained

DNS (Domain Name System) plays a critical role in how users and systems find resources on the internet or within internal networks. Whether it's managing an internal domain in an enterprise or delegating parts of a domain for traffic distribution, DNS setups vary widely depending on needs. In this blog post, we’ll break down the different types of DNS setups, including authoritative DNS servers, DNS delegation, and how internal DNS functions within organizations. 1. Authoritative DNS Server An Authoritative DNS server is the final source of truth for a specific domain. When someone queries a domain (e.g., example.com ), the authoritative DNS server for that domain holds the DNS records (A records, CNAME, MX, etc.) and responds with the corresponding IP address. Key Points: Who can host it? Authoritative DNS servers are often hosted by domain registrars (e.g., GoDaddy, Namecheap) or cloud DNS providers (e.g., AWS Route 53, Cloudflare). However, organizations can also host their ...

BGP MED: Managing Inbound Traffic with Multi-Exit Discriminator

The Multi-Exit Discriminator (MED) is used in BGP to control inbound traffic into your AS. It tells a neighboring AS which entry point into your network it should prefer when there are multiple links between your AS and the neighboring AS. The lower the MED value , the more preferred the path. MED is only honored between the same neighboring AS . Example Scenario : You are connected to ISP1 via two routers, CE1 and CE2 , and want to control which router ISP1 uses to send traffic into your AS. Network Topology : CE1 (connected to ISP1): 10.0.1.1/30 CE2 (connected to ISP1): 10.0.2.1/30 iBGP Router (Internal) connected to both CE1 (10.0.1.2/30) and CE2 (10.0.2.2/30). Configuration on CE1 (Lower MED, More Preferred) : Create a route map to set the MED to 50 for CE1: route-map SET_MED permit 10 set metric 50 Apply this route map to the neighbor in the BGP configuration for CE1: router bgp 65001 neighbor 10.0.1.1 remote-as 65000 neighbor 10.0.1.1 route-map SET_MED out Configuratio...