PeriodicPreoccupationsProjectsPicturesPersonPing

Recent musings

Notes on using Time Machine to a ZFS backing store

I'm trying to set down the steps that I did to enable me to do Time Machine backups to an AFP store on top of ZFS running on OpenSolaris. It just happens to be the combination I'm running. There's no real need to combine all these steps as they apply to you: I just want to make note of what I had to do.

First, I installed netatalk, mostly working from the instructions listed at confessions of a unix junkie. Since Leopard strongly deprecates sending AFP passwords in the clear, I had to build with OpenSSL. Since I used pkgsrc to build the dependencies, my ./configure command looked more like:
LDFLAGS=-R/opt/local/lib RANLIB=echo CC=gcc ./configure --prefix=/opt/local --without-pam --disable-ddp --disable-tcp-wrappers --disable-srvloc --with-bdb=/opt/local/include/db4 --with-cnid-dbd-backend --with-ssl-dir=/opt/local

The Diffie-Hellman Exchange UAM (uams_dhx.so) is fairly critical to use with Leopard, so the "unix junkie" recommendations for the cleartext password should be ignored.

With that accomplished, set up the backing store. For me, it's a ZFS dataset (filesystem) on a centralised mount point. Make sure that the owner points to the user who will be using the AFP share (with a chown). Make sure the AppleVolumes.default entry for each share points to the right directory and user, such as:
/Storage/atl-backup "TimeMachine" rwlist:atl allow:atl

Once the mac could connect securely, there were only two steps needed. Allow Time Machine to deal with unsupported AFP shares:defaults write com.apple.systempreferences TMShowUnsupportedNetworkVolumes 1and tickle the mounted share into being recognised for this unsupported hack:
touch /Volumes/TimeMachine/.com.apple.timemachine.supported

That was enough to get the backup started. As I'm still running the initial backup, I have no idea of the stability of this solution, but I hope to be able to report back. I also notice that reports say you must mount the "sparsebundle" disk image manually in order for the Time Machine recovery GUI to be of use.

Related Entries:
More storage desires
ZFS performance models for a streaming server
Further benchmarks, and a step back for consideration
Pause for Testing
Install 2 of N. Continue?
 Permalink

Leopard finder redesign: the webified windows explorer redux?

I was distinctly unimpressed by the WWDC keynote as I "saw" it in realtime, taking advantage of the live updates by various websites. Now that I've seen some of the online demo videos, it triggers some further thoughts.

Seeing Finder being made over to look like iTunes triggered strongly mixed emotions. On one hand, it feels very much like Windows' misadventure with making over Windows Explorer to look and work like Internet Explorer. Microsoft did that for some different reasons, but it did share the reason that it wanted to tie in with a familiar, popular interface that people dealt with every day. Hey! iTunes is familiar! People like iTunes! Let's leverage that!

On the other, I'm cautiously optimistic about the new finder features. I spent about fifteen minutes with a recent Leopard seed, and found myself missing the Quick Look feature for the rest of the day and during the next day. That's a seriously powerful feature. Expanding that to the CoverFlow view seems like it will have a lot of potential for browsing certain types of documents, but I'm not sure. I'd also have serious concerns about performance on my PowerBook.

Overall, I'm not sure if the new Finder features are glossy demo-ware that I seldom (spotlight) or never use (dashboard), or that it will make for a helpful step forward. The only things that will ultimately matter with the new Finder is performance, stability, and ease-of-use. We shall see...

Related Entries:
Notes on using Time Machine to a ZFS backing store
Musings on AppleTV Take 2
AppleTV: the next generation?
iTunes High-Definition coming soon! (again)
Windows Safari presages iLife on Windows?
 Permalink

Mac OSType to string

I googled this, but couldn't get very far: I wanted to be able to convert from a decimal to a four-character OSType because mdls only returns large integer representations of type or creator codes which had traditionally been represented as 4-character ascii strings. The quickest, laziest approach that occurred to me was to shift things around using a perl one-liner.

perl -e 'printf ("%c%c%c%c\n", \
 (@ARGV[0]        )>>24,(@ARGV[0]<< 8)>>24, \
 (@ARGV[0]<<16)>>24,(@ARGV[0]<<24)>>24)' 

This works fine on my PowerBook, but have doubts about running on 64-bit and/or Intel architecture hardware. Still, I thought it would be useful to save this snippet somewhere.

Why do I need to do this? Well, mdls gives a result that is really unhelpful:

% mdls -name kMDItemFSCreatorCode 00index
00index -------------
kMDItemFSCreatorCode = 1297307460

So, to continue with the example, you'd use backticks from the command line to process the result value from querying kMDItemFSCreatorCode or kMDItemFSTypeCode:

perl -e 'printf ("%c%c%c%cn",  \
 (@ARGV[0]        )>>24,(@ARGV[0]<< 8)>>24,  \
 (@ARGV[0]<<16)>>24,(@ARGV[0]<<24)>>24)'  \
 `mdls -name kMDItemFSCreatorCode 00index |   \
  awk -F= '{print $2}'`
MSWD
Related Entries:
Notes on using Time Machine to a ZFS backing store
Windows Safari presages iLife on Windows?
Leopard finder redesign: the webified windows explorer redux?
ZFS performance models for a streaming server
OpenID and MicroID
 Permalink
1-3/3