Tag Archives: google

HOWTO: Configure ddclient to update your Dynamic DNS entries with Google Domains

In a continuation of Google Domains includes Dynamic DNS for your self-hosted websites, I set up a ‘utilities’ virtual machine (CentOS 7) to run the DDNS daemon for my domains.  This makes sure that if my IP changes, there’s a semi-quick update.

The first thing I did was install ddclient.

yum -y install ddclient

Then, I used the Dynamic DNS entry created during the other blog posts – and grabbed the user/password info for that ddns entry.

I edited the /etc/ddclient.conf file, adding in the necessary info from domains.google.com.

utilitarian@localhost ~]# sudo cat /etc/ddclient.conf 
# Configuration file for ddclient generated by debconf
# /etc/ddclient.conf

login=<from the domains page>
password='<in single quotes on purpose>'

The www in www.blogdomain.dom above must match the DDNS record within Google Domains DNS settings.

Once that’s done, execute the ddns update:

utilitarian@localhost ~]# sudo ddclient -verbose -foreground
CONNECT:  checkip.dyndns.org
SENDING:   Host: checkip.dyndns.org
SENDING:   User-Agent: ddclient/3.8.2
SENDING:   Connection: close
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: 104
RECEIVE:  <html><head><title>Current IP Check</title></head><body>Current IP Address: <redacted></body></html>
INFO:     forcing updating www.blogdomain.dom because no cached entry exists.
INFO:     setting IP address to <redacted> for www.blogdomain.dom
UPDATE:   updating www.blogdomain.dom
CONNECT:  domains.google.com
SENDING:  GET /nic/update?system=dyndns&hostname=www.blogdomain.dom&myip=<redacted> HTTP/1.0
SENDING:   Host: domains.google.com
SENDING:   Authorization: Basic <redacted>
SENDING:   User-Agent: ddclient/3.8.2
SENDING:   Connection: close

Now, add it to cron to run every 2 hours on the half-hour & log the results:

30 */2 * * * /usr/sbin/ddclient -verbose >> /var/log/ddclient_updates.out


Google Domains includes Dynamic DNS for your self-hosted websites

Oh, the good-old-days, when DYNDNS was free – and so was zoneedit.  Move forward to today, where everything costs (and it should!).

Since I’m so heavily invested in Google from a tech perspective, I opted in to try their registrar service: Google Domains.

Transferring in was easy (see ya 1and1!) and setting up custom resource records (DNS entries) was simple.

Then, I read about Dynamic DNS being included with the service (along with free domain privacy) and I was intrigued.

Google offers their ‘help’ page here – but it left me questioning something.

I’m not going to re-write their doc, however, if you have any subdomains (www, blog, etc), THOSE are your synthetic Dynamic DNS records.

HOWTO: MOSH – when you need to SSH and there’s intermittent connectivity problems

Read about is here: https://mosh.mit.edu/

I loaded it up on RHEL 7.2, and here’s the process that I went through …

Add pre-requisite packages:
yum -y install git protobuf-c autoconf automake wget bzip2 gcc-c++ zlib-devel libutempter ncurses-devel openssl-devel net-tools

Run all of these commands:

wget http://protobuf.googlecode.com/files/protobuf-2.4.1.tar.bz2
tar -xf protobuf-2.4.1.tar.bz2
cd protobuf-2.4.1
./configure --prefix=$PREFIX
make install

export PKG_CONFIG_PATH=$PKG_CONFIG_PATH:/root/lib/pkgconfig

$ git clone https://github.com/mobile-shell/mosh
$ cd mosh
$ ./autogen.sh
$ ./configure
$ make
# make install

echo "export LD_LIBRARY_PATH=/root/lib" >> ~/.bashrc ; source ~/.bashrc

firewall-cmd –add-port=60000-61000/udp