![]() :log info "DNSoMatic: Previous IP $previousIP and current IP $currentIP are equal: No update needed"Īll I have done is to fix this - credit due to the original author, 't3wera', for getting it off the ground.Īh yes - thanks janisk - I've added the line: :log info "DNSoMatic: Sending update to $currentIP" # Get the current ip address from the internet (in case of double-NAT) :log info "DNSoMatic: Last ip address: $previousIP" # :log info "DNSoMatic: User: $maticuser Password: $maticpass" :log info "DNSoMatic: Updating dynamic ip on DNS for $matichost" This script _does_ work for me using 4.9 - the remaining issue is that OpenDNS takes several minutes to update, during which time the script, if repeated at, say, 120s intervals, will try several times to update.Īnyone know how to put in a delay in a script - ideally the script will run every, say, 60s but then wait before completing after an update attempt for, say, 5 minutes to allow the updates to propagate. The above script did most but not all of the work needed - the :global previousIP was not retained by 4.9 so I put in some additional code, using the same variables as the similar section to parse the result gathered from the web. :log info "DNSoMatic: Previous IP $previousIP and current $currentIP equal, no update need" :log info "DNSoMatic: Host $matichost updated on DNSoMatic with IP $currentIP" :log info "DNSoMatic: Sending update $currentIP" :local str "/nic/update?hostname=$matichost&myip=$currentIP&wildcard=NOCHG&mx=NOCHG&backmx=NOCHG" # Touching the string passed to fetch command on "src-path" option :log info "DNSoMatic: IP actual $currentIP" tool fetch mode=http address="" src-path="/" dst-path="/" # get the current IP address from the internet (in case of double-nat) :log info "DNSoMatic: Last IP $previousIP" :log info "DNSoMatic: User $maticuser y Pass $maticpass" :log info "DNSoMatic: Updating dynamic IP on DNS for host $matichost" ![]() Code: Select all # DNSoMatic automatic DNS updates
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |