LinuxQuestions.org
Latest LQ Deal: Latest LQ Deals
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 01-04-2014, 05:10 AM   #1
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Rep: Reputation: Disabled
Question ddclient.conf - Multiple domain registrars?


Hello!

Pardon my English.

I own domains at two different domain registrars, hence I have two separate providers I'd like to update the IP address of my webserver to.

I've been trying to write a ddclient.conf file for this purpose but I am not able to get it to work properly. How can I edit it to make it work?

(Domain names and providers are censored.)

Code:
# ddclient.conf

daemon=600                              # check every 10 min
syslog=yes                              # log update msgs to syslog
mail=root                               # mail all msgs to root
mail-failure=root                       # mail failed update msgs to root
pid=/var/run/ddclient.pid               # record PID in file
ssl=yes                                 # use ssl-support

# Where to get the server IP address?

use=web, web=dns.xxx.se/checkip.php, web-skip='Current IP Address:'

# The login details for XXX

protocol=dyndns2
server=dns.xxx.se/XDynDNSServer/XDynDNS.php
login=andy
password=***

# Domains @ XXX

domain.com,www.domain.com,example.com,www.example.com

# The login details for YYY

protocol=dyndns2
server=dyndns.yyy.se
login=boris
password=***

# Domains @ YYY

anotherdomain.com,www.anotherdomain.com
Thanks in advance!
 
Old 01-05-2014, 02:06 PM   #2
btmiller
Senior Member
 
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290

Rep: Reputation: 378Reputation: 378Reputation: 378Reputation: 378
I've never used ddclient before, but you may need to write two different config files. Assumedly, ddclient has some way you can specify a non-default config file when it is run. You would need to start instances of ddclient for both config files. You might also need to change default paths to the PID files so both can run simultaneously.
 
Old 01-05-2014, 03:24 PM   #3
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
I don't see anything obviously wrong with your config file. I update two different registrars with ddclient.

Here's mine, slightly redacted:

Code:
daemon=600                              # check every 600 seconds
syslog=yes                              # log update msgs to syslog
mail=root                               # mail all msgs to root
mail-failure=root                       # mail failed update msgs to root
pid=/var/run/ddclient.pid               # record PID in file
cache=/var/cache/ddclient/ddclient.cache  # cache file
ssl=yes                                 # requires perl ssl module
#
use=web, web=checkip.dyndns.org/, web-skip='IP Address'
login=myusername
password=**********
server=members.dyndns.org
protocol=dyndns2
myhost1.homelinux.net,   \
myhost2.homelinux.net
#
protocol=namecheap, \
server=dynamicdns.park-your-domain.com, \
login=mydomainnameismyusername, \
password=**************** \
@,                 \
www,               \
*
 
Old 01-05-2014, 05:20 PM   #4
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Z038 View Post
I don't see anything obviously wrong with your config file. I update two different registrars with ddclient.
Well, something in the config i posted must be broken. The domains at the first section (to the 1st registrar) is all updated correctly, but the domains to the second registrar doesnt update properly, except for that it creates 4 subdomain posts in the first domain name instead of 2 (@ and www). It creates an "@", "ce", "www", "www.ce", where "ce" is the first two letters of the second domain (theres actually 2 domains in the second registrar, and not only 1 as in my example).. in other words it looks like this:

Code:
site.com,www.site.com,othersite,www.othersite.com
and results in

SITE.COM DNS INFO
  • @
    Type: A
    TTL: 120
  • ot
    Type: A
    TTL: 120
  • www
    Type: A
    TTL: 120
  • www.ot
    Type: A
    TTL: 120

OTHERSITE.COM DNS INFO
  • Exactly NOTHING is updated for this domain.

where ot is the first two letters in the second domain "othersite.com".

The IPs are correct for all those 4 records (which should only be 2 records..).

So how come it creates these 2 broken records with parts from the second domain...? and doesnt update ANYTHING for the otherdomain DNS settings?

Thanks for your answers people, hopefully we can get this solved with your help...

Last edited by VaioSE; 01-05-2014 at 05:35 PM.
 
Old 01-05-2014, 06:15 PM   #5
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
I also tried replacing the whole file with only this, only updating to the registrar that it's not working with.

Code:
pid=/var/run/ddclient.pid
protocol=dyndns2
custom=yes
ssl=yes
use=web, web=dyndns.***.se,
web-skip='Current IP Address:'
server=dyndns.***.se
login='MyLoginname'
password='MyPassword'
foo.co, www.foo.co, bar.es, www.bar.es
Manually removing the old records through the registrars websites DNS-handler to make sure to get a fresh start. And then running a sudo ddclient -force

But it still gives the exact same result.. Writing 4 records in one of the domains and the second it doesn't write anything at all to.

What can be wrong..? I'm losing my hair over this!

Last edited by VaioSE; 01-05-2014 at 06:16 PM.
 
Old 01-06-2014, 01:18 AM   #6
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
Are you trying to get ddclient to update identical hostnames for different domain names? So far as I know, ddclient can't handle duplicate hostnames. For example, it won't update hostname www at both foo.com and bar.com. Or if it can, I haven't figured out how to do it.
 
Old 01-06-2014, 07:29 AM   #7
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Z038 View Post
Are you trying to get ddclient to update identical hostnames for different domain names? So far as I know, ddclient can't handle duplicate hostnames. For example, it won't update hostname www at both foo.com and bar.com. Or if it can, I haven't figured out how to do it.
Unless I'm misunderstanding your question then Yes.

Code:
abc.com,www.abc.com,def.com,www.def.com,ghi.com,www.ghi.com,jkl.net,www.jkl.net
This works perfect when updating to Provider A. When trying the exact same thing to Provider B, the DNS-records gets corrupted. Makes no sense to me.
 
Old 01-06-2014, 08:57 AM   #8
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
If you comment out Provider A and leave only Provider B in the ddclient config, do the DNS records get updated properly at Provider B? Or are they still corrupted?
 
Old 01-06-2014, 09:13 AM   #9
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Z038 View Post
If you comment out Provider A and leave only Provider B in the ddclient config, do the DNS records get updated properly at Provider B? Or are they still corrupted?
Already tried at Post #5 in this thread. Still the exact same result. I initially believed the problem was related to having two providers in the same configuration file but that seems to not be the case. The exact same corruption occurs when trying to update only Provider B using Provider B's own configuration file template.

However, it seems to work if I only update one of the domains (for example: foo.com, www.foo.com) or (bar.com, www.bar.com).

Updating multiple domain names at the same provider works with Provider A, so I don't see why it wouldn't work with Provider B. I run virtualhosts on the server and would like to associate different domains with different sites on the same physical server, just like I am successfully doing with Provider A.

I also tried creating two separate blocks, making what I assume to be two requests to the same provider using only one domain name per request. Like this:

Code:
# The login details for YYY

protocol=dyndns2
server=dyndns.yyy.se
login=boris
password=abc123

# First domain at YYY

foo.com,www.foo.com

# The login details for YYY (again)

protocol=dyndns2
server=dyndns.yyy.se
login=boris
password=abc123

# Second domain at YYY

bar.com,www.bar.com
However this produced the exact same corruption, again.
 
Old 01-06-2014, 09:25 AM   #10
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
Perhaps it is a problem with the DNS provider. You might try contacting them. Also, I see ddclient 3.8.2 was just released. What version are you running?

Last edited by Z038; 01-06-2014 at 09:26 AM.
 
Old 01-06-2014, 09:41 AM   #11
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Z038 View Post
Perhaps it is a problem with the DNS provider. You might try contacting them. Also, I see ddclient 3.8.2 was just released. What version are you running?
I was first using ddclient 3.8.0 (from 2009) which is the latest version provided through apt-get in ubuntu. However I downloaded ddclient from it's official website to get the latest version 3.8.2 and installed that instead to resolve a problem with the same Provider B sending malformed responses (not including IP, so ddclient complained about Invalid value for keyword IP) hoping that this would also solve the corruption problem with the DNS-records. It didn't. But atleast now, the cachefile is written properly. (ddclient 3.8.2 sets the IP value by itself in case it's not sent by the provider.)

And I've also tried deleting the cachefile for ddclient before every new attempt of updating (after doing some change) just to be clear about that.

Been doing practically nothing at all other than trying to solve this problem with updates to Provider B the last couple of days. Heh.

Last edited by VaioSE; 01-06-2014 at 09:43 AM.
 
Old 01-06-2014, 11:46 AM   #12
Z038
Member
 
Registered: Jan 2006
Location: Dallas
Distribution: Slackware
Posts: 910

Rep: Reputation: 174Reputation: 174
I have run out of ideas. Have you tried running non-daemon mode with debug and verbose?

Code:
# ddclient -daemon=0 -debug -verbose -noquiet
Also, this gives more help info:

Code:
# ddclient -help
 
Old 01-06-2014, 03:33 PM   #13
VaioSE
LQ Newbie
 
Registered: Jan 2014
Posts: 7

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Z038 View Post
I have run out of ideas. Have you tried running non-daemon mode with debug and verbose?

Code:
# ddclient -daemon=0 -debug -verbose -noquiet
Also, this gives more help info:

Code:
# ddclient -help
I tried it now, and couldn't find anything extraordinary in the output. I e-mailed the service provider.

Unless someone has any more suggestions of what might be causing the trouble I'll wait and see what the service provider will respond to my e-mail. The provider in question has a good reputation and they are one of the larger domain providers and hosting company today in my country, it's considered one of the better ones. Hopefully they will be willing to and able to help, since the problem might be on their side.

I'd still like more suggestions on what I can try if someone see's anything not mentioned in this thread that could be causing problems like this.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Various xorg.conf examples for using (multiple) cards + (multiple) monitors GrapefruiTgirl Linux - Hardware 7 10-13-2022 02:04 PM
DNS - resolv.conf with custom tld (top level domain) domain directive rubanek Linux - Networking 1 06-04-2013 12:11 PM
ddclient and ddclient.conf help to understand wolfsar Linux - Networking 8 12-28-2012 10:55 AM
About ddclient.conf satimis Linux - Server 4 03-18-2009 03:56 AM
Not only cheap, but reliable suggestions for DNS registrars (for dynamic IP's) MasterC General 1 05-30-2003 01:29 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 11:51 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration