NO-IP DDNS on Cisco Router

Started by Ironman, March 21, 2015, 03:03:21 PM

Previous topic - Next topic

Ironman

Trying to get this setup but having some issues. Here is my config:


ip ddns update method ironman
HTTP
  add http://email_address:password@dynupdate.no-ip.com/nic/updatehostname=<h>&myip=<a>
interval maximum 0 0 5 0

interface gi0/0 (public internet interface)
ip ddns update hostname iron.ddns.net (changed slightly)
ip ddns update ironman



PVD_RTR1#sho ip ddns update
Dynamic DNS Update on GigabitEthernet0/0:
  Update Method Name            Update Destination
  ironman                       not available


Any thoughts?

Fred

First thing I'd check is DNS resolution.  Can you ping dynupdate.no-ip.com from the router?

Ironman

Quote from: Fred on March 21, 2015, 10:50:57 PM
First thing I'd check is DNS resolution.  Can you ping dynupdate.no-ip.com from the router?

Hi Fred, yes I can ping it:

PVD_RTR1#ping dynupdate.no-ip.com
Type escape sequence to abort.
Sending 5, 100-byte ICMP Echos to 8.23.224.120, timeout is 2 seconds:
!!!!!


Actually it seems like it's closer to working now. I didn't make any changes. In the debug I noticed this

<p>The requested URL /nic/updatehostname=PVD_RTR1.domain&amp;myip=x.x.x.x was not found on this server.</p>

Does this command refer to the hostname of the router or should it be the URL name I assigned on NO-IP.com?

add http://email_address:password@dynupdate.no-ip.com/nic/updatehostname=<h>&myip=<a>


Reggle

I don't know no-ip, but do you need the "&myip=" part? The DDNS service I use will automatically use the source of the HTTP GET as IP address if that parameter is missing. I also think it's weird your debug shows the ampersand in different formatting.

Ironman

Yea, it is an odd message. I will actually reboot the router in the next day or so and see if DDNS is working properly.

Fred

Quote from: Ironman on March 22, 2015, 08:01:09 AM
<p>The requested URL /nic/updatehostname=PVD_RTR1.domain&amp;myip=x.x.x.x was not found on this server.</p>
This suggests that the URL is invalid.  IIRC there are some nice debug commands that will show the update in progress, but you'd have to google those.

Stuart

@Ironman,

I believe the answer to your problem is that the update URL requires a question mark between the "update" and "hostname" portion (e.g. dynupdate.no-ip.com/nic/update?hostname)

Now as we all know, you can't enter a ? in the IOS.  But you can. :)

Enter the URL until you get to the end of "update", type CTRL + V and then press ? which will give you the question mark.  You can then continue to enter the remainder of the URL.

I have the following configured on my router and it works fine:-


ip ddns update method DynamicDNS
HTTP
  add http://USERNAME:PASSWORD@nic.changeip.com/nic/update?system=dyndns&hostname=HOSTNAME
interval maximum 7 0 0 0
interval minimum 0 6 0 0
!


Regards,

S.

Ironman

#7
Thanks for the reply! I did get the ? in my config a few days ago but I am still noticing an error in the debug. Do I have to specify the actual HOSTNAME in that line?


000098: Mar 25 22:11:33.695 EST: HTTPDNSUPD: DATA START 404 Not Found Not Found The requested URL /nic/ was not found on this server. Apache Server at dynupdate.no-ip.com Port 80
000099: Mar 25 22:11:33.699 EST: HTTPDNSUPD: DATA END, Status is Response data recieved, successfully
000100: Mar 25 22:11:33.699 EST: HTTPDNSUPD: Call returned SUCCESS, update of avenger2.ddns.net x.x.x.x succeeded
000101: Mar 25 22:11:33.699 EST: DYNDNSUPD: Another update completed (outstanding=0, total=0)
000102: Mar 25 22:11:33.699 EST: HTTPDNSUPD: Clearing all session 11 info


Here is my current configuration:
ip ddns update method avenger2
HTTP add http://username:password@dynupdate.no-ip.com/nic/?updatehostname=&myip
interval maximum 0 0 1 0
interface gi0/1
ip ddns update hostname avenger2.ddns.net
ip ddns update avenger2

SimonV

Is there any way to specify the source IP because now I get 1.1.1.1 from nslookup, maybe one of your loopbacks?

Ironman

I changed it to 1.1.1.1 on the web side on NOIP.com to force my router to update it. It should be using the Gi0/1 interface as its source which is where the public dhcp address is.

SimonV

The No-IP guide uses this format:

add http://username:passsword@dynupdate.no-ip.com/nic/update?hostname=<h>&myip=<a>

Your config behind the /nic/ uses a different format

By the way, I've been using No-IP for the last two years and it really gets on my nerve to confirm the hostnames every two weeks.
Been looking into an alternative and will be trying these ones soon: FreeDNS.afraid.org

Ironman

#11
Thanks for the info, I made the changes and now I am getting this in the debug:

008625: Mar 26 11:02:21.272 EST: HTTPDNSUPD: DATA END, Status is Response data recieved, successfully
008626: Mar 26 11:02:21.272 EST: HTTPDNSUPD: Call returned SUCCESS, update of avenger2.ddns.net <=> x.x.x.x succeeded
008627: Mar 26 11:02:21.272 EST: DYNDNSUPD: Another update completed (outstanding=0, total=0)
008628: Mar 26 11:02:21.272 EST: HTTPDNSUPD: Clearing all session 13 info
CRN_RTR1#
008629: Mar 26 11:03:22.156 EST: DYNDNSUPD: Adding DNS mapping for avenger2.ddns.net <=> x.x.x.x
008630: Mar 26 11:03:22.156 EST: HTTPDNS: Update add called for avenger2.ddns.net <=> x.x.x.x
008631: Mar 26 11:03:22.156 EST: HTTPDNSUPD: Session ID = 0xE
008632: Mar 26 11:03:22.156 EST: HTTPDNSUPD: URL = 'http://ironman401:password@dynupdate.no-ip.com/nic/?updatehostname=&myip'
008633: Mar 26 11:03:22.156 EST: HTTPDNSUPD: Sending request
008634: Mar 26 11:03:22.784 EST: HTTPDNSUPD: Response for update avenger2.ddns.net <=> x.x.x.x

008635: Mar 26 11:03:22.784 EST: HTTPDNSUPD: DATA START
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><
CRN_RTR1#head>
<title>403 Forbidden</title>
</head><body>
<h1>Forbidden</h1>
<p>You don't have permission to access /nic/
on this server.</p>
<hr>
<address>Apache/2 Server at dynupdate.no-ip.com Port 80</address>
</body></html>

SimonV

Is it possible you forgot the hostname after the = ?

Stuart

#13
Ironman,

You have the ? in the wrong place in the URL.

In your code you have it after nic (e.g. no-ip.com/nic/?) when in fact it should come between "update" and "hostname" (e.g. no-ip.com/nic/update?hostname)

Move the ? to the correct location and then it should work.

No-ip.com also have the following guide for setting up DDNS on Cisco routers.
http://www.noip.com/support/knowledgebase/using-your-cisco-router-with-no-ip-dynamic-dns-services/

Edit: so the correct URL to use should be:

http://ironman401:password@dynupdate.no-ip.com/nic/update?hostname=<h>&myip=<a>

Regards,

S.

Ironman

#14
Thanks for your help! I made the changes you mentioned and it was still hung up. I believe it was tied up with some of the previous commands so I reloaded each router and it is working now. Much appreciated! I modified the links I was using above for security reasons.