Projects
Home Projects About Me
Meaow! Building blocks...
Linkstation 2

The “fun” I had Recovering and Upgrading my Buffalo Linkstation 2 NAS Drive…

Recovery

When your Buffalo LS2 fails, it is very worrying - the throbbing red light and the thought of losing all your data is quite unpleasant. Even if you have a backup, you have still lost the easy access to your data.

Now there seems to be two forms of LS2 failure:

Hardware fail - the LS2 circuitry or the HDD fails. That is what your backup is for… you do have a backup, don’t you?

A problem with the firmware image. Now this is where I can help!

I have had a few issues with my OpenLink LS2 firmware image. One was due to some power interruptions affecting where I live. Another was due to me trashing it when a bash script went wrong. On all occasions I have been able to recover the system with no loss of data. I have refined an easy technique over time. The secret is that the LS2 firmware and all your data occupy different partitions of the LS2 HDD.

In easy steps:

Remove the LS2 HDD from the LS2 enclosure and connect it to your favourite Linux build. I currently use Mint 17v2.

Copy the entire contents of the 3rd partition to a “.tgz” file.
“sudo tar -zcvpf /home/archive.tgz
    --directory /mnt/point/ --exclude spool --exclude lost+found .”

   Do notice the “.” at the end of that tar command. It really is needed!
This will copy all the data from all your shares into single file. The file will be as big as the data is, so ensure your Linux box has the space.

Wipe the LS2 HDD. Yes, delete all 3 partitions. Then put the LS2 HDD back into the LS2 enclosure and fire it up.

Use the restore tool in the OpenLink zip to restore OpenLink. Then use the LS2 GUI to check and re-enter your configuration.

Again, remove the LS2 HDD from the LS2 enclosure and connect it to your favourite Linux build.

Restore your data back to the 3rd partition from the “.tgz” file.
“cd /mnt/point”
   “sudo tar -zxvpf /home/archive.tgz”

Return the LS2 HDD back to the LS2 enclosure and fire it up.


Great, OpenLink now works and your data has been restored. Job done!

Upgrade

This is basically the same process as recovery, except that the LS2 HDD you remove is not the one you return to the LS2 enclosure.

I have successfully upgraded my LS2 HDD twice. The first time was from the original 250GB HDD to a new 320GB HDD. The next time was to a 500GB HDD that I got via eBay. Never had any  issues - it just worked.

Backup

The LS2 does have a backup feature that is configurable via the GUI, but I have found it to be unreliable and not exactly what I wanted.

Using the CLI access that comes with the OpenLink firmware I have written a simple bash script which does the Sync-Diff-Mirror type backup I want. Effectively it does what “rsync” would do, but without using “rsync”, which is not part of the OpenLink build. Perfect!

Additionally, this can be automated via “cron”. Even better - a backup automated!

Annoyingly, I have found that using the GUI to enable or amend the NTP update function will wipe any manual “crontab” entries you have made. Watchout!

An Essential Resource

There is a ton of LS2 information on the Buffalo NAS Central site.

It is well worth a visit!