我很难将debian配置为noip.com更新程序。我的配置如下所示:
# Configuration file for ddclient generated by debconf
#
# /etc/ddclient.conf
use=web
web=checkip.dyndns.com
web-skip='Current IP Address: '
protocol=dyndns2
server=dynupdate.no-ip.com/nic/update
login=myusername
password='mypass'
myhost.noip.me
一切似乎都很好,但如果我ping myhost.noip.me,ip地址就不会更新。通过检查
ddclient -daemon=0 -debug -verbose -noquiet 2 /etc/ddclient.conf
我得到以下答复:
.conf
=== opt ====
opt{cache} : <undefined>
opt{cmd} : <undefined>
opt{cmd-skip} : <undefined>
opt{daemon} : 0
opt{debug} : 1
opt{exec} : <undefined>
opt{facility} : <undefined>
opt{file} : <undefined>
opt{force} : <undefined>
opt{foreground} : <undefined>
opt{fw} : <undefined>
opt{fw-login} : <undefined>
opt{fw-password} : <undefined>
opt{fw-skip} : <undefined>
opt{geturl} : <undefined>
opt{help} : <undefined>
opt{host} : <undefined>
opt{if} : <undefined>
opt{if-skip} : <undefined>
opt{ip} : <undefined>
opt{login} : <undefined>
opt{mail} : <undefined>
opt{mail-failure} : <undefined>
opt{max-interval} : 2592000
opt{min-error-interval} : 300
opt{min-interval} : 30
opt{options} : <undefined>
opt{password} : <undefined>
opt{pid} : <undefined>
opt{postscript} : <undefined>
opt{priority} : <undefined>
opt{protocol} : <undefined>
opt{proxy} : <undefined>
opt{query} : <undefined>
opt{quiet} : 0
opt{retry} : <undefined>
opt{server} : <undefined>
opt{ssl} : <undefined>
opt{syslog} : <undefined>
opt{test} : <undefined>
opt{timeout} : <undefined>
opt{use} : <undefined>
opt{verbose} : 1
opt{web} : <undefined>
opt{web-skip} : <undefined>
=== globals ====
globals{daemon} : 60
globals{debug} : 1
globals{login} : myusername
globals{password} : mypass
globals{protocol} : dyndns2
globals{quiet} : 0
globals{server} : dynupdate.no-ip.com/nic/update
globals{use} : web
globals{verbose} : 1
globals{web} : checkip.dyndns.com
globals{web-skip} : Current IP Address:
=== config ====
config{myhost.noip.me}{atime} : 0
config{myhost.noip.me}{backupmx} : 0
config{myhost.noip.me}{cacheable} : ARRAY(0x1770c50)
config{myhost.noip.me}{cmd} : <undefined>
config{myhost.noip.me}{cmd-skip} :
config{myhost.noip.me}{custom} : 0
config{myhost.noip.me}{fw} :
config{myhost.noip.me}{fw-login} : <undefined>
config{myhost.noip.me}{fw-password} :
config{myhost.noip.me}{fw-skip} :
config{myhost.noip.me}{host} : myhost.noip.me
config{myhost.noip.me}{if} : ppp0
config{myhost.noip.me}{if-skip} :
config{myhost.noip.me}{ip} : <undefined>
config{myhost.noip.me}{login} : myusername
config{myhost.noip.me}{max-interval} : 2592000
config{myhost.noip.me}{min-error-interval} : 300
config{myhost.noip.me}{min-interval} : 30
config{myhost.noip.me}{mtime} : 0
config{myhost.noip.me}{mx} :
config{myhost.noip.me}{password} : mypass
config{myhost.noip.me}{protocol} : dyndns2
config{myhost.noip.me}{script} : /nic/update
config{myhost.noip.me}{server} : dynupdate.no-ip.com/nic/update
config{myhost.noip.me}{static} : 0
config{myhost.noip.me}{status} :
config{myhost.noip.me}{use} : web
config{myhost.noip.me}{warned-min-error-interval} : 0
config{myhost.noip.me}{warned-min-interval} : 0
config{myhost.noip.me}{web} : checkip.dyndns.com
config{myhost.noip.me}{web-skip} : Current IP Address:
config{myhost.noip.me}{wildcard} : 0
config{myhost.noip.me}{wtime} : 30
=== cache ====
cache{myhost.noip.me}{atime} : 0
cache{myhost.noip.me}{backupmx} : 0
cache{myhost.noip.me}{custom} : 0
cache{myhost.noip.me}{host} : myhost.noip.me
cache{myhost.noip.me}{ip} : 12.34.56.78
cache{myhost.noip.me}{mtime} : 1437992275
cache{myhost.noip.me}{mx} :
cache{myhost.noip.me}{script} : /nic/update
cache{myhost.noip.me}{static} : 0
cache{myhost.noip.me}{status} :
cache{myhost.noip.me}{warned-min-error-interval} : 0
cache{myhost.noip.me}{warned-min-interval} : 0
cache{myhost.noip.me}{wildcard} : 0
cache{myhost.noip.me}{wtime} : 30
DEBUG: proxy =
DEBUG: url = checkip.dyndns.com
DEBUG: server = checkip.dyndns.com
CONNECT: checkip.dyndns.com
CONNECTED: using HTTP
SENDING: GET / HTTP/1.0
SENDING: Host: checkip.dyndns.com
SENDING: User-Agent: ddclient/3.8.2
SENDING: Connection: close
SENDING:
RECEIVE: HTTP/1.1 200 OK
RECEIVE: Content-Type: text/html
RECEIVE: Server: DynDNS-CheckIP/1.0
RECEIVE: Connection: close
RECEIVE: Cache-Control: no-cache
RECEIVE: Pragma: no-cache
RECEIVE: Content-Length: 103
RECEIVE:
RECEIVE: <html><head><title>Current IP Check</title></head><body>Current IP Address: 12.34.56.78</body></html>
DEBUG: get_ip: using web, checkip.dyndns.com reports 12.34.56.78
SUCCESS: myhost.noip.me: skipped: IP address was already set to 12.34.56.78.
我想我目前(人工) IP "12.34.56.78“已经被正确设置。现在,如果我ping (我的人工主机) myhost.noip.me,我得到一个不同的IP。
有什么建议吗?我需要修改什么才能让to客户端使用noip.com?
发布于 2016-06-13 02:53:50
protocol=noip
我正在使用noip,但是使用noip协议,就像它在--帮助标志里面,看看这个帮助,以获得更多的信息。
发布于 2016-06-04 15:51:57
您显示的跟踪显示,ddclient
为您的机器的IP进行了checkip.dyndns.com
轮询,发现IP没有更改,因此决定跳过联系dynupdate.no-ip.com
来更改IP。如果它联系了dynupdate.no-ip.com
,您将在跟踪中看到这样的一行
CONNECT: dynupdate.no-ip.com
然后是一系列的SENDING
和RECEIVE
行。
我发现,如果您想强制ddclient
执行整个操作,您应该停止任何当前使用sudo service ddclient stop
运行的守护进程,并使用sudo rm /var/cache/ddclient/ddclient.cache
删除它的缓存文件。然后,任何后续运行都必须执行所有检查。
此外,您的配置文件是错误的。在/nic/update
设置中不应该有server
,因为这是protocol
设置的一部分。(使用dyndns2
作为协议意味着附加了/nic/update
。)供参考,我的当前配置是:
use=cmd
cmd='dig +short myip.opendns.com @resolver1.opendns.com'
protocol=dyndns2
ssl=yes
server=dynupdate.no-ip.com
login=<YOUR LOGIN>
password=<YOUR PASSWORD>
<YOUR HOST>
我使用dig
命令获取公共IP,而不是通过HTTP与服务器联系。
发布于 2019-07-26 18:56:23
配置中唯一的问题是服务器更新地址。它应该是:
# Configuration file for ddclient generated by debconf
#
# /etc/ddclient.conf
use=web
web=checkip.dyndns.com
web-skip='Current IP Address: '
protocol=dyndns2
server=dynupdate.no-ip.com
login=myusername
password='mypass'
myhost.noip.me
您可以通过执行以下命令来测试配置:
sudo ddclient -verbose -foreground
您应该看到路由器部分(使用'web‘提供者提取IP地址),然后是无IP的身份验证和正在更新的IP地址:
ONNECT: checkip.dyndns.com
CONNECTED: using HTTP
SENDING: GET / HTTP/1.0
SENDING: Host: checkip.dyndns.com
SENDING: User-Agent: ddclient/3.8.3
SENDING: Connection: close
SENDING:
RECEIVE: HTTP/1.1 200 OK
RECEIVE: Content-Type: text/html
RECEIVE: Server: DynDNS-CheckIP/1.0.1
RECEIVE: Connection: close
RECEIVE: Cache-Control: no-cache
RECEIVE: Pragma: no-cache
RECEIVE: Content-Length: 106
RECEIVE:
RECEIVE: <html><head><title>Current IP Check</title></head><body>Current IP Address: X.X.X.X</body></html>
INFO: setting IP address to X.X.X.X for myhost.noip.me
UPDATE: updating myhost.noip.me
CONNECT: dynupdate.no-ip.com
CONNECTED: using HTTP
SENDING: GET /nic/update?system=dyndns&hostname=myhost.noip.me&myip=X.X.X.X HTTP/1.0
SENDING: Host: dynupdate.no-ip.com
SENDING: Authorization: Basic bHBlbmFwQGdtYWlsLmNvbToyNjg3OGxhcA==
SENDING: User-Agent: ddclient/3.8.3
SENDING: Connection: close
SENDING:
RECEIVE: HTTP/1.0 200 OK
RECEIVE: server: envoy
RECEIVE: content-type: text/plain; charset=UTF-8
RECEIVE: cache-control: no-cache
RECEIVE: date: Fri, 26 Jul 2019 18:48:25 GMT
RECEIVE: connection: close
RECEIVE:
RECEIVE: good X.X.X.X
SUCCESS: updating myhost.noip.me: good: IP address set to X.X.X.X
https://unix.stackexchange.com/questions/218841
复制相似问题