PDA

Bekijk de volledige versie : Update NoIp, DynDNS, dyn.ee, ipactive via script



rj.2001
07-05-2007, 21:08
Hello,

with the below script, you can update NoIp, DynDNS, dyn.ee and ipactive without any client! The advantage of that is, that you can update your DNS entry at any time you want. Client programs in most case are limited: You can only update after X minutes. But you can not update the DNS directly after you WAN connection is established.

Here is the script:


#!/bin/sh
###################################
# Content of /opt/bin/IPupdate.sh #
###################################

# Logfile parameter
# LOG=1/0 (On/Off)
# LOG=pathname to the logfile
LOG=1
LOGFILE=/opt/logs/IPupdate.log

# provider url's
# DynDNS
#URL="http://$1:$2@members.dyndns.org/nic/update?hostname=$3"
# NoIP
URL="http://dynupdate.no-ip.com/dns?username=$1&password=$2&hostname=$3"
# dyn.ee
#URL="http://dynserv.ca/dyn/dynengine.cgi?name=$1&pass=$2&func=set&domain=$3"
# ipactive
#URL="http://logon.ipactive.de/cgi-bin/logon_off.pl?V=2.1&B=$1&P=$2&IP=$3&F=1"


echo ""
if [ $# != 3 ] ; then
echo "IPUpdate script"
echo "usage: $0 <LOGIN-NAME> <PASSWORD> <HOSTNAME/DOMAIN/IPADR>"
exit
fi

if [ $LOG == 1 ] ; then echo "$(date) Starting DNS entry update for $3 ..." >> $LOGFILE; fi
echo "Starting DNS entry update for $3 ..."

# Update Host entry
RESULT=`wget -O - $URL | cat`
if [ "$RESULT" == "" ] ; then RESULT=Error; fi
if [ $LOG == 1 ] ; then echo "$(date) DNS entry update result for $3: $RESULT" >> $LOGFILE; fi
echo "DNS entry update result for $3: $RESULT"


call this script via:

/opt/bin/IPupdate.sh <YourLogin> <YourPassword> <YourHostname>

If you want to update the DNS directly after your PPPoE connection is raised up, you can place the above call at the end of your /usr/local/sbin/post-firewall. (Thanks to al37919 for this tip) :)

To update DnyDNS or an other DNS service (supply with the script), you must remove / insert the # in front of the related
URL=

Additional you can install cron and start the script with the above call every X minutes.

Have fun!

jrosado
18-06-2007, 22:20
Why is the dyndns option on the webpage of my asus wl-500gP not working? Is this a bug from oleg firmware? I've olge firmware 1.9.2.7-7g.

In order to keep my IP updated, i had to create a script and run it every 15 minutes using crontab. :(

osymandias
21-08-2007, 11:31
Hi,

I'm running a WL500gP under access point mode as a wireless bridge to a router that does not support DynDNS. I'd like to use the DynDNS features of the 500g, but these are disabled in the web interface. Have found the ddns_updated utility (and start_ddns) but neither of these provide information on their use. Can anybody point me to a reference for these (couldn't find anything in the forum) or suggest where and how I should put a configuration?

Cheers.

SuperB
30-10-2007, 18:34
I have tried using a script for updating my DynDNS on a regular basis. After about a day DynDNS blocked me because of excessive updating.
Of course my script was different from yours, but the result *may* be the same. Since then, I have decided to install inadyn, which is recommended by DynDNS. Search for my how-to on this forum that I posted today.

al37919
31-10-2007, 06:31
After installing 1.9.2.7-8-pre15, it seems that built in ddns client started to work correctly (self-updating after reconnection). So you may try just to enable it in web-IF and remove all scripts.

Tellus1
06-04-2008, 17:41
Is it possible to update 2-3 DynDNS hostnames from WL500gP (when the dynamic IP changes) at the same time?

al37919
06-04-2008, 17:49
sure, Oleg's firmware includes ez-ipupdate ( http://ez-ipupdate.com/ ). Tune in a way which you like.

mark_q4xprt
27-08-2008, 13:58
here is my problem on dyndns
wl-500gp doesnt update my ip automatically or even if i update manually


on IP Config - Miscellaneous
Enable the DDNS Client? Yes
Server: WWW.DYNDNS.ORG
User Name or E-mail Address: acer21
Password or DDNS Key: xxxxxxx
Host Name: acer.gotdns.com
Enable wildcard? Yes

now the other problem is, when i log in to the dyndns website and update my ip manualy, it just bounces to my modem "Mt880" not on my router"wl500gp" can someone help me on this?

heres my setup

i have a dynamic ip
my modem is MT880 that gets ip automatically
my wl500gp setup is obtain ip automatically
WAN IP Setting
Get IP automatically? Yes
IP Address: 192.168.1.2
Subnet Mask: 255.255.255.0
Default Gateway: 192.168.1.1


LAN IP Setting
Host Name: WL-500G
IP Address: 192.168.0.1
Subnet Mask: 255.255.255.0

now what is wrong with my config that keeps me bouncing on the modem instead of the router?

Tellus1
08-11-2008, 07:13
Is ez-ipupdate in any way connected to the DynDNS settings on the router's web interface? Or is it a separate application?

slawuta
04-01-2011, 15:48
Hi, all!
How can I configure DynDNS service by command line? Web unreachable...