x
all questions login
General DNS & Domains Dyn Email Update Clients

How to access to CCTV with a router that doesn't support DDNS

Hi, we're in a remote area of Spain w/o fixed ADSL lines. We can only use 3G or long distance wifi internet connections. Our new provider who offers very good network coverage doesn't support DDSN client within their router. We can't use another router since it's integrated in their antenna we have on our roof. It's a Mikro Tik router board. How can I still access to our cameras?

more ▼

asked Jul 23 '11 at 05:51 PM in DNS & Domains

operator1815 gravatar image

operator1815
1 1 1 1

operator1815 gravatar image operator1815 Jul 23 '11 at 06:22 PM

I know about the client update software but what do I do if there isn't any computer running in the LAN but only the CCTV IP cameras?

(comments are locked)
10|600 characters needed characters left

1 answer: sort voted first

The MikroTik certainly supports DynDNS updates - I know because that's what I use.

You'll find a number of good scripts in their forums and Wiki, depending on what version of RouterOS you're running. On RouterOS v4 I'm using the following:

# User configuration follows
:global ddnsuser "yourUSERNAME"
:global ddnspass "yourPASSWORD"
:global ddnshost "yourHOSTNAME.dyndns.example"


# Do not edit below this line
:global ddnsinterface "WAN"
:global ddnssystem ("mt-" . [/system package get [/system package find name=system] version] )
:global ddnsip [ /ip address get [/ip address find interface=$ddnsinterface] address ]
:global ddnsip [:pick $ddnsip 0 [:find $ddnsip "/"] ]
:global ddnslastip

:if ([:len [/interface find name=$ddnsinterface]] = 0 ) do={ :log info "system No interface named $ddnsinterface, please check configuration." }
:if ([ :typeof $ddnslastip ] = "nothing" ) do={ :global ddnslastip  [/file get dyndns.txt contents] }
:if ([ :typeof $ddnsip ] = "nothing" ) do={

:log info ("system No ip address present on" . $ddnsinterface)

} else={

# We have a WAN IP, do update

  :if ($ddnsip != $ddnslastip) do={

    :log info ("system Sending UPDATE for " . $ddnshost . " from " . $ddnslastip . " to " . $ddnsip)
    /tool fetch user=$ddnsuser password=$ddnspass mode=http address="members.dyndns.org" src-path="/nic/update?hostname=$ddnshost&myip=$ddnsip" keep-result=no
    :global ddnslastip $ddnsip

# Log current IP
/file set dyndns.txt contents="$ddnsip"

  } else={ 

    :log debug "system No changes necessary."

  }

:log debug "system Update process complete"

}

Note that it doesn't handle the inactivity timeout, since I have a paid account and it doesn't matter to me. Adding that however should be pretty easy.


Edit

Most routers expect to be the WAN connected device, so will generally fail to update correctly. If you were to use a router running DD-WRT then you'd probably be ok, since it's default client uses web based detection.

more ▼

answered Jul 23 '11 at 07:41 PM

Cry Havok gravatar image

Cry Havok ♦
79.2k 14 28 279

RotBlitz gravatar image RotBlitz ♦ Jul 23 '11 at 09:27 PM

This is a TOP answer! Fantastic!

operator1815 gravatar image operator1815 Jul 24 '11 at 08:08 PM

Thank you! This is a top answer in deed but I'm not a programmer. Besides I don't have any access to the router board since the provider doesn't allow their customers to play with the configuration of course. What I intended to ask was whether I could put my own router (with ddns client) behind the router board? What would be necessary to change with the router board's config that I can instruct the provider to do?

(comments are locked)
10|600 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

© 1998-2013  Dynamic Network Services Inc.  -  Legal Notices  -  Privacy Policy  -  Contacts