Point the Way Home: DDNS with Linode

Guest Blogger: Keith Murray

Earlier this year I switched my web hosting from my long-time account at DreamHost to a fancy new VPS at Linode. I really did enjoy my time with DreamHost, but what I wanted out of my hosting provider had changed somewhat. I was looking for full control of a machine in the cloud. Although DreamHost does offer a VPS option, the pricing options just didn’t compare with what Linode was offering.

I also took the opportunity to move my domain registrations over to Hover, but more on that another time.

With my Linode account managing the DNS for my domains I was able to point a a single subdomain back at the IP of my home network, effectively giving me a nice publicly accessible domain from within my network. This worked well until my ISP changed the IP address I had. Admittedly this doesn’t happen often, but it always seems to occur when I actually need to make use of this remote connection, and with no knowledge of my new public DHCP address it’s pretty useless.

Enter DDNS.

With some modifications to a script I found on GitHub I was able to quckly set up job to check my public IP address and update the DNS records at Linode using the Linode API. I hacked apart the original script and put together my own DDNS update script, suitable for automating.

By scheduling the script to run using a simple crontab entry I can rest assured that every night, while I’m asleep, my server will be connecting to Linode to point the way home.


Keith Murray is a software architect and developer who blogs about technology and science at kdmurray.net. He can also be found on twitter as kdmurray.

Related Posts

kw602 : Life on a Stick.

Do you have any USB Thumbdrives lying around collecting dust or data that you haven’t used in quite a while ? Those days are gone after you listen to this weeks episode of the Knightwise.com podcast. We show you how to “live of a stick” and have both your data, your applications and even your complete operating system .. running on a stick.

Shownotes

Related Posts

What if we took Linux seriously ?

It had only been a couple of days since the release of the latest version of Ubuntu’s next incarnation 13.04 when I decided it would be time to give it a spin on my Lenovo Thinkpad. I had only purchased the little 11.6 inch I3 laptop a couple of days earlier ( A nice second hand machine if I may say so ) and was planning on using it for most of my day-to-day computing tasks. Having read up on all the ‘latest’ features to come to 13.04 I was looking forward to the next version of Nautilus and having a peek at the new “Friends” application that had come to replace Gwibber. But most of all I was looking forward to the speed increase in Unity.

Four hours later I woke from a daze of searching forums, entering command line strings, downloading packages, fixing dependencies and filing bugs to a system that was actually working. As it turned out the “bleeding edge” of Ubuntu Distro’s had been hemorrhaging into my work schedule where it had eaten up the precious time of “Getting things done” in favour of “Getting things to work”. The system was operational, but somehow I did not have the confidence in my installed machine that I normally have. Why ? Because I take my computers seriously. Computers are an integral part of my work routine and I actually rely on my Linux powered computers to get things done for work, but also for things like blogging, podcast producing and so forth. And I hold those Linux powered systems to high standards : They have be stable, reliable, consistent and most of all, help me to get things done. 

I flash back 7 or 8 years when I bought my first iBook (G4 powered Mac Laptop) and experienced the joy of having a computer that helped me be creative and get things done. This is raw contrast to the dodgy XP and Vista systems that seem to need constant cleaning, maintenance, repair and re installations. I had a computer that got the job done.. And I liked it.

 So having spent 4 hours on a “bleeding edge” Linux distribution to get it working just the way I wanted to had been a learning experience (as most Linux related things are) but not quite what I had in mind for the afternoon. With Blogposts unwritten, Podcasts unrecorded, work email .. unchecked it somehow reminded me of those dodgy XP machines we spent hours to fix.  I wiped the drive and re-installed trusty Ubuntu 12.04 (Long term support) exchanging bleeding edge features for slightly older and boring well supported stability. I did it because I needed to get OTHER stuff done.

 The question has been nagging in my mind ever since : What if we took Linux seriously. And by that I do not mean the “ham-shack amateur passion” in which we all run our own favorite super tweaked distribution. Not in the way we bicker and squabble over the best graphical user interface.. But ‘Serious’ in the way a company would use it.  Over the last couple of years I’ve seen the Linux scene expand in adoption and popularity. From the bearded geeks in their basements whose only source of light was a flickering command line prompt to a much larger host of geeks and even end users who have discovered the wondrous world of Tux. But the question remains if the Linux community with its resources of developers, bug fixers, advocates and users would be enough in a “real world environment”.

To illustrate my point let me pose you a question. What Linux distribution would you pick to install on 2600 workstations, spread over 4 countries. Its average user level “novice” its support and management servers centralized  With Microsoft’s “active directory” things like remote configurations, policies and software packaging are quite able to produce a somewhat uniform and centrally managed workstation landscape. What Linux system would you pick to replace it ? On the one hand stability and support is an issue, so the ‘bleeding edge’ of Debian Testing might not be something towards you would want to entrust your day-to-day business processes. On the other hand there is the issue of support where you need to make sure that your install base is not starved out of patches and support after 9 months. And lastly there is of course the need for a centralized system to make sure system configurations, policies and so forth can be managed from one location.

When I look around the Linux landscape today I see few distributions that are up to the corporate task of being the primary OS for a desktop workforce (I am not talking about servers) As colorful as distributions like Pear_OS or Hanna Montanna Linux might be, they do not have the resources to make in the corporate world. Other distributions like Suse or Redhat ( who have corporate backing ) lack any form of centralized management and configuration tools like Microsofts Active Directory. You might have a fair chance of rolling them out on the desktop, but only to a workforce that is able to install and repair their own workstations. And then there are those other distro’s who are looking for an unity between their different platforms. They are shunned for “selling out” to the idea of “free and open source” in favor of making a buck.

And so I ponder what would happen if some bloggers got what they asked for. “Windows will be dead in 2 years”. Then what ? What os is going to be on the workstation of your aunty Jeanne over at the DMV ?  Who is gonna support Uncle Joe as his Arch Linux workstation reports broken dependencies. What company will be the first to roll out “Hanna Montana Linux” as their strategic choice for the desktop.   We have been touting for years that “The Linux Desktop” is gonna make it to the mainstream, but I wonder what we do if we get there. Because then it will be in the hands of the “average” users. Students who need to get their papers done. Accountants who need to file tax returns, Tattoo artists who need to have a high res picture of that Hanna Montana clipart before they paint it on your shoulder. People who do not have the slightest notion what Linux is about and why it is so great. People unaware they can compile packages from source or tweak their system to a whole new level. People who associate penguins with David Attenborough instead of Richard Stallman. People who are not in the know. In other words : People who need to take this stuff seriously and use their computer not to “do things” but to get things done.

Related Posts

kw504 : Sliders Academy Part One : Installing your Ubuntu system.

We start out a new series of Video tutorials on Knightwise.com called “Sliders Academy” where we give you step by step guides to ‘learn how to slide’. We start out with chapter one of Sliders Academy where we show you how to setup a central Ubuntu system that will serve as the nervecenter for your upcoming slider activities. In this episode we show you how to download and install Ubuntu, Partition your drive, update your system and install some alternative desktop interfaces. 30 minutes of educational edu-tainment coming right up.

Shownotes.

Download the video HERE.

Related Posts

Bohdi, ONE linux distro for your Netbook, Nexus, Mk802, Chromebook and Raspberry PI.

With all the great feedback we have been getting on the last podcast episode ” Return of the Netbook” we have gotten quite a few Knightwise.com fans asking “What would be a good distro to pick”. Yeah sure there are plenty of *buntu or Debian based versions of Linux out there with a very light desktop interface. But most of them are based on Lxde or Xfce. The downside with these graphical skins is that … everybody else has them too. And you want to stand out .. right ? So not only do you want to score hordes of fans in the geek world (and the oposite or same sex) with your flaunting walk as you ‘stride’ through the shopping mall holding your Netbook .. You also want something that no-one else has… Yet.

If in need of an original spin on the “light linux desktop” you might want to go for Bodhi Linux.  It features an “Ubuntu 12.04 LTS” underground topped off with an Enlightenment (or E17) desktop and a pretty look and feel. I would describe the extra features of Bodhi as ‘added icing’ , but that would make this article resemble a Culinary cupcake review.

Not very impressive I hear you say : But wait ! Bodhi is also available for your MK802 AND your Chromebook  your Google Nexus AND your Raspberry Pi !  Talk about one OS to rule them all ! 

Download the 32 of 64 bit versions of Bodhi here. If not satisfied with the results, pimp it just the way you want it and make it into their “Desktop hall of fame”.

Links : Bodhi.

First listener who posts a pic in the comments section of HIS desktop/chromebook/stick/pi/kitchen sink  running Bodhi, wins the Geek-of-the-week badge !

Related Posts

Wordgrinder takes you back to the (productive) days of Wordperfect.

I mentioned a couple of interesting command line suggestions for a good Wordprocessor a while ago in a previous post. But thanks for the research I did for the “Return of the netbook” podcast, I came across Wordgrinder. Unlike most word processing applications from Redmont, Wordgrinder is not infested by a talking paper clip, and its menu bar has not been designed like a hidden Chinese puzzle that only Savants can solve.

Wordgrinder is also a different league from the  text editors like VIM or Emacs, and is not geared towards code manipulation like Nano. Wordgrinder reminds me of .. Wordperfect. Remember the little paper strip secretaries had taped to their keyboards in order to remind them what function key did what ? Wordgrinder is more like that. Hitting the escape key brings you into the menu bar where you can select all the functions you expect from a real Wordprocessor… from the early Nineties.

But in a world swamped with widgets, buttons and distractions, in a universe where every application at least has one dingdong to tweet whenever you even THOUGHT about farting in the elevator .. Wordgrinder is safe haven of simplicity and focus. Run it natively on any Linux system or access it via an SSH connection to your Linux system from your Mac or your Pc.  Sure it isn’t high tech, but it does the job pretty well. For all those times you need to knuckle down .. Wordgrinder is your friend.

Links : Wordgrinder. 

Install it from the command line (On Ubuntu)

sudo apt-get install wordgrinder

Related Posts

How about a Citrix session in Ubuntu on a Macbook Air.

The one upside of being a slider is that you can do whatever the hell you want with your computer. I mean, its not only thinking outside the box, its like thinking about the box outside the box before there ever IS a box. The fun part of doing all this is that you can hack your hard and software the way YOU want it to work for you.

one does not

As you know I have an 11.6 inch Macbook air that I drag around everywhere. It would be quite dull if it ONLY ran OSX. Of course it doesn’t. Since the day I got it I fought, tweaked and tinkered right up to the point that I had it running exactly like I wanted to. In my case : on Ubuntu 12.10. After tweaking the fans, the keyboard, the screen illumination and the function keys, I had trained my Macbook to behave like a Mac, while still running Windows.

The only time I had to really boot back into OSX is when I wanted to access our work Citrix server. Since I take my little bundle of joy to work from time to time, but also work from home, it was always a little sad to say bye bye Ubuntu, JUST to use the silly Citrix client.

And when you tell me I HAVE to use a CERTAIN operating system JUST to use a CERTAIN application .. I get antsy and start looking around. So my new goal for the week was : Get a Citrix client working on Ubuntu .. ( on a mac ) and access your work deskop (A Windows 2003 Terminal server environment).

After finding this brilliant howto on installing the 64 bit Ica Client under Ubuntu I had the Citrix client running in no time. The only downside came when I started typing.

Remember : This was a Windows 2003 session I had open, with a Ubuntu operating system and a Macintosh keyboard. So when I started typing it looked …. Fracked up.  So how was I going to fix it.

After some searching in my home folder I found the Ica client config file.  in  /home/%username%/ICAClient/wfclient.ini

The first lines in the config file pointed towards the keyboard layout looked like this.

KeyboardLayout = (User Default) 
KeyboardMappingFile = automatic.kbd
KeyboardDescription = Automatic (User Profile)
KeyboardType=(Default)

I remembered I had kinda the same problem when I tried to run the Citrix Receiver client on my Mac (under OSX) and got a wonky keyboard. The solution there was to also look for the config file an change the keyboard settings to FRENCH (Since I have a French Macintosh keyboard layout) So I changed the first line.

KeyboardLayout = FRENCH

Now everything works perfectly ! I can now happily run my work “Windows” session under Linux on my Macbook Air. Sliders rule !  

Link : Ubuntu howto on running the ICA client.

Related Posts

kw501: Ubuntu on the Nexus 7 with Alex Chiang.

We kick off season 5 of Knightwise.com by cutting into a hot topic : Ubuntu on Mobile phones. Oblivious to the announcement Canonical made a couple of days ago about bringing Ubuntu to the Mobile phone, we talked to one of their lead developers in December of 2012.  Alex Chaing tells us about the development of an Ubuntu distribution for mobile devices. What were the hurdles, how is it done and how do YOU get it on there. A sneak peak behind Canonicals roadmap, a geeks guide to getting Linux on your tablet.

Shownotes

Related Posts

Making bootable USB linux disks on your Mac the easy way.

As I mentioned in this weeks podcast, making bootable Live usb disks on a Mac is far from a joyous experience. It requires a bit of command line fu, and although thats pretty cool once you get it working its not always easy. So before you strangle a baby squirrel out of sheer frustration, lets give you an easy alternative.

With the Mac Usb loader from Seven Bits that is a thing of the past. A simple point and Click interface gives us the ease of use of its Linux and Pc cousin UnetBootin, but I am however not completely sure if it supports persistant disk images (So you can save the changes you did in the live OS) According to Ubuntu Vibes its still a little bit buggy .. but give it a go nonetheless. 

Link : Mac Linux Usb Loader.

Have you tried it out ?  Report your findings in the comment sections and share ! 

Related Posts

Saynonara mr Desktop

Sometimes being a geek means taking risks, trying things out and experimenting with new gadgets, technologies and trends that arrive on the shores between real and Cyberspace. Over the last couple of weeks I’ve been noticing such a “looming trend” in my techno-ecosphere and decided to bite the bullet and go head on into it .. 

But first let me explain : I live a very mobile lifestyle. Times where I am actually “in my home office” are quite sparse. I’m on the road a lot, I work abroad and the scarse moments that I AM home, I love to hang out with my beloved better half, our two dogs and our cat. Holing myself up in my office upstairs with the door shut .. is not an activity I favor so much. The result has been that my favorite “batcave” has been largely “unused” lately. The Dual screen I7 Mac Mini setup that I had setup was sparsely used (mostly as a server) and the i5 Linux desktop that sat along side it spent most of its time idling away or catching up on software and security update. Meanwhile I was either working from my Galaxy Nexus phone, reading stuff on my Nexus Tablet or iPad or punching away on the 11.6 inch Macbook Air that I drag around virtually anywhere. 

But when we look at the trends of technology, we are slowly seeing the processor powers of all of these different devices coming up to par with one another. My “Desktop machines” might sport a little more ram then my Laptops but overall, my laptop(s) have the power to haul what needs to be hauled. My phone / tablet enable me to communicate and consume content anywhere .. so the question came up : Why do I still NEED a desktop anyway ? To sit there ?

office

I bit the bullet 2 weeks ago when I disassembled my Mac Mini setup, and hooked the machine, together with a bunch of USB drives, up to our TV downstairs. The “Super Desktop” I had put together a couple of months ago, is no more. I have changed its roll from “production system” to “central home server”. Hooking it up to our tv and stereo system it serves up movies , tv shows and music when we want to, and uses its raw I7 power (and 16 gig of ram) to run multiple virtual machines. The machine is now almost constantly doing “Something” and gives me the power of a mediacenter and a small datacenter at my fingertips. Because all of the content is stored and backed up in a central location, I no longer need to worry about ‘what file is where’ since everything is stored right there on the server. With that I also alleviate one of the major hassles I had where some files would reside on desktop X and some files would reside on desktop Y … no more local files, period.  The i5 Linux desktop went out next. Whatever local data and settings still resided where either transferred to the downstairs sever or copies over to my Macbook air that is also running Linux.

So what am I left with.

So right now my ‘laptops’ have found their rightful place in my office. I’ve devided up the 24 inch Displays between my 13 inch Macbook pro running Mountain Lion and my 11.6 inch Macbook Air running Ubuntu Linux. I’ve given an nice “laptop stand ” to both and a comfortable keyboard. When I do ‘Arrive’ in the office, the laptop of choice can “land and charge” in its designated slot and the comfortable keyboard, mouse and screen give me the perfect “workstation”. (With an extra screen)

Simplicity, portability, elegance, 

In the end, Its not about the speed. If you would honestly ask me if I “miss” my desktops ? No. The impact on speed and disk space in negligible and the fact that I can now “carry around” my workstation everywhere offers me much more perks than downsides. By centralizing my storage and cpu load to the downstairs servers, I now have (with the additional use of Cloud solutions like Dropbox and Ubuntu one) everything I need on every system that I need. The last divide between home and mobile has hereby completely vanished.

What I have lost ? Nothing much actually. Since i’m not an avid gamer, my desktop(s) where no graphical powerhouses. When I do feel like Fragging something I either pop over to my game console or fire up Call of Duty on my Macbook pro (or any good game on Ubuntu, the ‘Air’ is able to hold its own there too)  When on the road I connect to my home shared using VPN tunnels and SSHFS mounts. Most of the file syncronisation is handled by Dropbox, Ubuntu one and my Google Apps environment.  Time to say “Sayonara” to the age of the desktop. The beige boxes, pimped powerhouses or multi-core mega-machines. They have lived long and prosper .. but its time to move on.

 So what about YOU ? Do you still have any desktops running ? Thinking of biting the bullet and dumping the “beige boxes” ? Tell us about it in the comments section.

Related Posts