net-dns/ddclient-3.6.3 starts before named service and fail to resolve IP address: Apr 14 22:44:30 titan ddclient[7824]: WARNING: cannot connect to ipdetect.dnspark.com:80 socket: IO::Socket::INET: Bad hostname 'ipdetect.dnspark.com' that could be solved by adding 'dns' in depend-list in /etc/init.d/ddclient: depend() { need net dns }
It should be "use dns", because not everyone will be running a dns server. This is fixed in ddclient-3.7.0: /usr/portage/net-dns/ddclient/files/ddclient.initd ddclient-3.7.0 stability: bug #170708
'use' or 'after' ?
The documentation ( http://www.gentoo.org/doc/en/handbook/handbook-x86.xml?part=2&chap=4 ) is confusing, but "use" seems better: $ grep use /etc/init.d/* | grep dns | wc -l 7 $ grep after /etc/init.d/* | grep dns | wc -l 1
Nebojsa, does 3.7.0 work Ok for you?
no, 3.7.0 doesn't work :( /etc/init.d/ddclient start * Starting DDClient ... WARNING: file /etc/ddclient/ddclient.conf: Cannot open file '/etc/ddclient/ddclient.conf'. (Permission denied) stat() on closed filehandle FD at /usr/sbin/ddclient line 858. Use of uninitialized value in bitwise and (&) at /usr/sbin/ddclient line 859. readline() on closed filehandle FD at /usr/sbin/ddclient line 865. WARNING: file /etc/ddclient/ddclient.conf: Cannot open file '/etc/ddclient/ddclient.conf'. (Permission denied) stat() on closed filehandle FD at /usr/sbin/ddclient line 858. Use of uninitialized value in bitwise and (&) at /usr/sbin/ddclient line 859. readline() on closed filehandle FD at /usr/sbin/ddclient line 865. WARNING: unable to determine IP address
> '/etc/ddclient/ddclient.conf'. (Permission denied) Give it sane permissions. chgrp ddclient /etc/ddclient/ddclient.conf chmod 640 /etc/ddclient/ddclient.conf As done by the ebuild, if the file did not already exist.
changing permissions solved the problem. I had old /etc/ddclient/ddclient.conf file with wrong permissions. guess that 3.7.0(-r1) ebuild should change those permissions even if file already exists, just in case of an upgrade and not the clean install. 3.7.0 gives me the same error message, but at least ddclient stays started so it can update dynamic dns record a little bit latter: Apr 15 14:19:34 titan ddclient[7758]: WARNING: cannot connect to ipdetect.dnspark.com:80 socket: IO::Socket::INET: Bad hostname 'ipdetect.dnspark.com' titan ~ # /etc/init.d/iptables status * status: started titan ~ # changing to depend() { before cron need net use logger after dns } didn't helped, but I think it's not so big deal tu update 300 seconds later.
please test with the latest version, 3.7.3