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!

4 Replies to “MacFUSE”

Leave a Reply to Piotr Komoda Cancel reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.