Announcement

Collapse
No announcement yet.

Any way to set a tunnel destination as an FQDN not an IP?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Any way to set a tunnel destination as an FQDN not an IP?

    Hi peeps,

    I'm trying to set up a tunnel between two routers (pair of 1841s). I know I can do this easily enough specifying the destination by IP address, or by FQDN and having it instantly resolved to an IP.

    Code:
    gforce-router-1#conf t
    Enter configuration commands, one per line.  End with CNTL/Z.
    gforce-router-1(config)#int tunnel 0
    gforce-router-1(config-if)#tunnel destination www.google.com
    Translating "www.google.com"...domain server (192.168.1.31) [OK]
    
    gforce-router-1(config-if)#end
    
    gforce-router-1#show run int tunnel 0
    Building configuration...
    
    Current configuration : 74 bytes
    !
    interface Tunnel0
     no ip address
     tunnel destination 31.55.163.155
    end
    
    gforce-router-1#
    What I'm trying to do however is to have the FQDN saved into the configuration and for this to be resolved whenever needed, which I guess would be whenever the router gets reloaded or the tunnel connection drops.

    Does anybody know if this is possible?

    Looking around online I've seen some suggestions of workarounds, such as this one to automatically have the configuration update itself with the new IP address. I've not tried that yet but it looks promising, however ideally I'd prefer to do it "my way" if possible

    Thanks in advance.
    Gareth Howells

    BSc (Hons), MBCS, MCP, MCDST, ICCE

    Any advice is given in good faith and without warranty.

    Please give reputation points if somebody has helped you.

    "For by now I could have stretched out my hand and struck you and your people with a plague that would have wiped you off the Earth." (Exodus 9:15) - I could kill you with my thumb.

    "Everything that lives and moves will be food for you." (Genesis 9:3) - For every animal you don't eat, I'm going to eat three.

  • #2
    Re: Any way to set a tunnel destination as an FQDN not an IP?

    The answer is unfortunately no. Tunnel endpoints must be specified as IP addresses, not host names.

    It makes sense when you think about it; DNS names may change, and exactly how often should the router check a given A/AAAA record?

    Comment


    • #3
      Re: Any way to set a tunnel destination as an FQDN not an IP?

      Thought not but worth asking

      My thought was that the router might be able to detect when the tunnel connection dropped and then perform the DNS lookup.
      Gareth Howells

      BSc (Hons), MBCS, MCP, MCDST, ICCE

      Any advice is given in good faith and without warranty.

      Please give reputation points if somebody has helped you.

      "For by now I could have stretched out my hand and struck you and your people with a plague that would have wiped you off the Earth." (Exodus 9:15) - I could kill you with my thumb.

      "Everything that lives and moves will be food for you." (Genesis 9:3) - For every animal you don't eat, I'm going to eat three.

      Comment

      Working...
      X