I recently bought my very first Mac ever. After years of struggling with crappy movie editing software, draining system resources and general bloat on Windows I finally bought myself a beautiful 24″ iMac and so far the experience has been every bit the bundle of awesomeness I’d hoped it would be. Except for TimeMachine.
I’ve got a 500GB Buffalo Linkstation I used for backup and for storing music files for a year. It’s a great machine that just works and serves my two laptops and a desktop very well. The problem is that the backup software what comes with it only works on Windows.
Crap.
So, rather than let my Linkstation become an expensive bookend, I hit the Internet to find an answer and wasn’t entirely pleased with the options:
1) Turn on this undocumented and apparently not very stable feature on OS X.
2) Rebaseline my Linkstation with an “opened” firmware and use rsync.
3) Purchase some kind of third party backup software for Mac like SuperDuper! that does backup instead of TimeMachine
I went with option 2. Yeah, I know option 1 sounds easier, but the stuff I read really made it sound unstable and like a waste of time, and anyway the geek in me was really warming to the idea of a Linkstation that was basically a really cheap Linux computer with a giant hard drive.
Many hours later I’m ready to declare success. So what if I could have just bought a couple of TimeMachine devices (at the same hourly-billable equivalent rate). Instead I’d learned something new that reinforced my technical chops.
So dear readers, here’s how you do it. Specifically, here’s how you backup from an iMac running OS X 10.5.2 to a Buffalo Linkstation Pro LS-GL running on an ARM processor. With any other combination your results may vary so make sure you read up before you start.
Backup all your data
The stuff you’re about to do has the potential to brick your Linkstation if you screw it up. Yes, brick it, as in won’t turn on, unrecoverable, gone, expensive book-end. There are some instructions on un-bricking a Linkstation but thankfully I didn’t have to try them out.
Download the jtymod firmware for Linkstation
Some kind soul created a hacked firmware called jtymod that is basically the standard firmware with telnet, ssh, and a few other necessary services enabled. Make sure you get the “fixed” jtymod version not the regular jtymod version. I don’t know what the fix was for, but the forum posts I read made it sound pretty necessary. Once you’ve downloaded it, you just unzip it and you have both the installer and the binary images you need to install. This part worked like a dream for me so I don’t have any advice for troubleshooting. If you run into trouble, the Linkstation hacker wiki is an excellent resource.
Reset the Root Password

You should see an option to reset the root password on your linkstation now as shown in this screen shot. After you clear the password, you should be able to set it again by logging in as “root” with a blank password and then changing it:
ssh root@192.168.1.1 passwd root
Install it using the included installer exe
Took me a while to figure out the installer was included in the zip file. I looked all over Google for general instructions on “how to install firmware images on a Linkstation” before I finally figured out I didn’t need them. Just run the exe included in the firmware zip file. Maybe you’re smarter than I am and figured that out yourself.
Write a simple shell script using rsync
The BackupUsers.sh shell script is stone simple:
#!/bin/sh rm /Users/trcull/Documents/BackupUsers.stdout rm /Users/trcull/Documents/BackupUsers.stderr echo "Starting BackupUsers.sh" > /Users/trcull/Documents/BackupUsers.stdout date >> /Users/trcull/Documents/BackupUsers.stdout sleep -60 rsync -va /Users admin@192.168.1.6:/mnt/disk1/macbackup &> /Users/trcull/Documents/BackupUsers.stdout
You can see some much more involved examples on the rsync site and on the Linkstation wiki rsync page.
Setup some shared keys so you don’t have to type a password
If you want this job to run unattended, you have to set up some shared keys between your Linkstation and your Mac.
Configure it to run using launchd
Apple has decided to replace crond with something called launchd. There’s a decent writeup for using launchd to get you started. I ended up creating a plist file that looks like this:
< ?xml version="1.0" encoding="UTF-8"?> < !DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> <plist version="1.0"> <dict> <key>Debug</key> <true /> <key>ExitTimeOut</key> <integer>7100</integer> <key>Label</key> <string>net.kroppel.BackupUsers</string> <key>OnDemand</key> <false /> <key>Program</key> <string>/Library/Scripts/CustomScripts/BackupUsers.sh</string> <key>StartInterval</key> <integer>7200</integer> <key>ThrottleInterval</key> <integer>7000</integer> <key>UserName</key> <string>trcull</string> </dict> </plist>
You may wonder why I have a ThrottleInterval in there. That’s because my rsync exits with a code 23 because it doesn’t have permissions on some of the directories it’s trying to copy. This causes launchd to think the script failed and needs to be spawned again. It took me days of my Linkstation constantly thrashing on its drive before I realized what was going on.
Done!
Now you’re in backup heaven. Still glad you didn’t just give in and buy a Time Capsule instead?
July 9, 2008 at 5:29 pm
Hi there,
Thanks for the very helpful post. I found myself in the same situation as you and decided to do the same thing.
So do you know what is the root password after firmware change?
Thanks,
Alex
July 11, 2008 at 4:28 pm
Hi Alex,
Glad I could be helpful. After installing the new firmware, you will see a new button in the Linkstation admin console called “reset root password”. There’s a web page somewhere out there detailing what to do but I forgot to include it. If I can dig it up again I’ll try to add a link, or maybe someone can leave a comment with a link.
I’m curious to know how you get along.
–Tim
July 13, 2008 at 5:02 am
I must be blind because I don’t see any button called reset root password or anything similar. I’m also struggling setting up shared keys. Even though I follow every step on the page you linked I still get prompted for password. I’m such as linux novice.
Have you set that up yourself?
Thanks,
Alex
July 16, 2008 at 6:02 pm
Hi Alex,
I’ve added a screen shot of the reset root password.
Unfortunately, I’m a Linux novice, too, so don’t have much advice on the ssh keys. maybe you could try the forum on the page I linked to?
August 14, 2008 at 12:34 am
Yes, but it’s still not Time Machine.
As in, no incremental backups, no integration with Apple restore utilities, no cool UI … with almost a year having gone by since the Leopard release, you’d think there must be SOME way to get it working by now??!
December 23, 2008 at 4:43 pm
I want to do the same thing you are doing. Thanks for this post it gives me the confidence to try this. I have successfully upgraded my linkstation pro with the freestation jtymod 103 firmware and I have cleared the root password and set a new one. I may have missed it but I don’t see anything in your post about installing rsync. I found the rsync wiki and it has a bunch of installers but I don’t see a specific one for Freestation. I see one for FreeLink and OpenLink and also one for Linux but I’m not sure which I should download and install. Any details on this would be appreciated.
Thanks
jeff
January 4, 2009 at 9:43 pm
Hi Jeff,
I don’t recall having to install rsync. Hopefully it’s not a step I did but forgot I did, but I’m pretty sure it comes with jtymod
–Tim
November 11, 2010 at 7:48 am
Option 4? – Best integration I’ve found out-of-the-box comes from the Netgear ReadyNAS product line where Time Machine support is a default feature. That also has a cloud solution to back up the NAS, and the device can also run SVN, MySQL and a bunch of other useful tools developed by an engaged add-on community. From a sustainability perspective the devices manage power consumption when not in use by spinning the disks down or even running to a shut-down schedule over night.