ddns-updater icon indicating copy to clipboard operation
ddns-updater copied to clipboard

Bug: run.go:295: ERROR malformed IP address received

Open robyscar opened this issue 2 years ago • 3 comments

TLDR: Describe your issue in a one liner here

  1. Is this urgent: YES
  2. DNS provider(s) you use: NAMECHEAP
  3. Program version: latest Running version latest built on 2022-03-15T14:38:50Z (commit 584597d)
  4. What are you using to run the container: PORTAINER, with manual ENV variables
  5. Extra information (optional)

Logs:

2022/03/23 16:18:18 json.go:46: INFO reading JSON config from file /data/config/config.json
2022/03/23 16:18:18 main.go:189: INFO Found single setting to update record
2022/03/23 16:18:18 main.go:203: INFO Reading history from database: domain domain.xyz host @
2022/03/23 16:18:18 server.go:45: INFO healthcheck server: listening on 127.0.0.1:9999
2022/03/23 16:18:18 main.go:276: INFO backup: each 24h0m0s; writing zip files to directory /data/bkp
2022/03/23 16:18:18 server.go:48: INFO http server: listening on :8000
2022/03/23 16:18:18 main.go:288: ERROR backup: open /data/bkp/ddns-updater-backup-577439870.zip: no such file or directory
2022/03/23 16:18:19 run.go:196: WARN cannot DNS resolve domain.xyz after 5 tries: lookup domain.xyz on 8.8.8.8:53: no such host
2022/03/23 16:18:19 run.go:211: INFO IP address of domain.xyz is <nil> and your IP address is 5X.1XX.8X.5X
2022/03/23 16:18:19 run.go:292: INFO Updating record [domain: domain.xyz | host: @ | provider: namecheap | ip: ipv4 or ipv6] to use 5X.1XX.8X.5X
2022/03/23 16:18:19 run.go:295: ERROR malformed IP address received: 
2022/03/23 16:18:40 "GET http://192.168.2.222:8063/ HTTP/1.1" from 192.168.2.166:30890 - 200 1612B in 345.466µs
2022/03/23 16:18:41 "GET http://192.168.2.222:8063/favicon.ico HTTP/1.1" from 192.168.2.166:30890 - 404 19B in 57.499µs
2022/03/23 16:18:53 "GET http://192.168.2.222:8063/ HTTP/1.1" from 192.168.2.166:30890 - 200 1612B in 169.791µs
)

Configuration file (remove your credentials!):

{
     "settings": [
         {
             "provider": "namecheap",
             "domain": "domain.xyz",
             "host": "@",
             "password": "*******************************"
         }
     ]
}

Host OS:

DietPi v8.2.2 : 16:28 - Wed 03/23/22
 - Device model : RPi 3 Model B+ (armv7l)

robyscar avatar Mar 23 '22 09:03 robyscar

Same here, Namecheap Portainer on Fedora 35

albydnc avatar Mar 28 '22 10:03 albydnc

Can you run with LOG_LEVEL=debug? That should log each request and response being sent. I would like to find out what kind of response they send you. I use Namecheap but I haven't seen this problem so far. I also checked the last time the relevant code was changed was 10 months ago, so I guess it's something that changed on Namecheap's end?

qdm12 avatar Mar 29 '22 18:03 qdm12

@robyscar and @albydnc you may have skipped the step of creating an A + Dynamic DNS Record. See here: https://www.namecheap.com/support/knowledgebase/article.aspx/43/11/how-do-i-set-up-a-host-for-dynamic-dns/

jlikens avatar Apr 16 '22 20:04 jlikens

Sorry that took forever... 88474c8a3af946e7e2140c8cb38de88d89922549 allows to have empty "" IP address returned from Namecheap, and won't error out if this happens.

Although I use Namecheap and never had the problem, so that's a bit odd.

Anyway closing this, but feel free to report if it's still broken.

qdm12 avatar Aug 28 '22 22:08 qdm12