MacFUSE

So, yesterday, I overheard someone mentioning MacFUSE in a conversation and my reaction was pretty much “hey, someone ported that to the Mac?!??”  Indeed, and I’m apparently a little out of touch because it’s been out for a while.  This is one really handy tool for a sysadmin.

Anyone who’s admined an RPM-based system knows that when you install a newer version of something, it will often drop in new configuration files, either along side the existing one with an .rpmnew extension on the end, or move your existing one to filename.rpmsave before writing it out to the original location.  Of course, if you’re behaving like a proper sysadmin, you have to go look and see what they changed and try to merge your existing config with the new one.  This is best accomplished using a visual diff/merge utility.  The best one of these I’ve seen for Linux is called meld.  Unfortunately it has a ton of dependencies (mostly related to GNOME and X11) which are a bit much to install on every server in your farm, especially if there’s no other reason you need X11 on them.

Now back to MacFUSE.  Apple distributes an awesome visual diff/merge utility with the Mac OS X developer tools called FileMerge, which works a lot like meld (but of course, it’s a bit more polished).  MacFUSE is a kernel extension that allows plugins to define interfaces to arbitrary filesystems.  One of the plugins available for it is called “sshfs.”  sshfs uses the sftp server available via most ssh servers to access the filesystem of almost any machine you can ssh into.  This means if I can open an ssh connection to one of my servers, I can now mount its filesystem in the Finder in Mac OS X (and also via the shell).  This makes it easy to navigate to the server’s /etc directory and type “opendiff config1.conf config1.conf.rpmnew” which invokes Apple’s FileMerge to compare/merge those two files.  It’s a huge effort saver for a sysadmin using OS X on their workstation.  🙂

Mad props to Amit Singh and all the people helping him make MacFUSE a reality!

The results are in

Wow, that was fast.  They said they’d have the results of the RHCE exam posted sometime in the next 3 business days (which would mean sometime next week), but I had an email waiting for me when I got home tonight with the results.  I passed.  So I’m now officially a Red Hat Certified Engineer.

The exam is done

So I think the exam went pretty well.  I know I passed the first half, I’ll get the results of the second half and the overall sometime in the next three business days.  Now I have to get out of here in a hurry to try to get home ahead of the incoming storm at home.  It’s likely I’ll be driving at least part of the way through the middle of a blizzard.  Originally I was planning on staying here another day (I’m in Chicago for the class), and heading home tomorrow, but the weather forecast looks like if I don’t go now I’ll be stuck here until Tuesday or so.

The class and the exam were a lot of fun.  Lots of challenging problems and it was a lot of fun to fix them up. 🙂 I did learn enough new tricks from the class part to have made it well worth my while taking the class.  I’d highly recommend it to anyone with good Linux experience that’s interested.  Just make sure you have an employer willing to pay for it because it’s expensive. 🙂

Geeklog to WordPress converter

I’ve been intending to convert my blog from Geeklog to WordPress for probably the better part of a year.  I’m a stickler for preventing dataloss though, and I really wanted to keep all my old blog posts.  I searched the web on and off for a month or two looking for a way to convert the data, and the best I could find was the RSS import in WordPress.  Unfortunately, the RSS export in Geeklog sucks rocks, and even hacking on it a bit, I couldn’t get all the data out in one piece.

So I finally gave up searching and wrote my own WordPress import module for Geeklog that would copy and translate the data directly from one database to the other. It’s heavily based on the existing importer for TextPattern that’s included with the current WordPress distributions.  It imports categories, users, posts, and comments.  It also stores the Geeklog Story ID (sid) into the post metadata, for use in making the old permalinks keep working.  I have an article.php stub you can drop into your wordpress directory that takes the Geeklog permalinks and redirects to the new WordPress ones.

I’m posting this here so the next person who has to convert a Geeklog to a WordPress can save themselves a bunch of trouble. :)  It’s all been posted to WordPress’ Trac system.  If you make use of it and make any improvements to it while you’re at it, feel free to add them to that bug.