Saturday, October 22, 2011

Arch Linux on a Pogoplug

The hard drive that I was using for Time Machine died (I/O errors), so I went to Best Buy to get a new one.  While I was there, I noticed that they had a Pogoplug which I also purchased. 

Although the box said the model number was a POGO-P21 (which is the model number for the Pogoplug v3), the sticker on the Pogoplug itself said that it was a POGO-E02 (Pogoplug v2). While the v3 has a faster processor, the v2 has more memory (256 MB vs 128 MB).  I didn't notice until just now that I could have installed Optware on it and kept access to my.pogoplug.com.  Instead, I installed Arch Linux ARM on it (on a 2 GB flash drive).  In retrospect, I probably could have done what I wanted with Optware, but since I already have Arch Linux working, I'll probably leave it as is.

I used pacman to install ffmpeg on the Pogoplug and configured my netcams to upload to it instead of my Western Digital MyBook Live since the ffmpeg binary on Arch Linux includes the mpeg4 and H.264 codecs where as the MyBook does not.  Encoding to H.264 is too slow, so I'm encoding to mpeg4 (I was encoding to motion jpeg on the MyBook).  Although I am storing the images and videos on a 16 GB flash drive (formatted ext2 to reduce flash wear), I'm uploading the compressed files once a night to the MyBook for easier remote access and more permanent storage.

Friday, October 21, 2011

More efficient NAS backups using Carbon Copy Cloner

By default, when backing up to a sparse bundle disk image, Carbon Copy Cloner uses a band size of 8MB. This might be already for use on a local disk, but seems to cause a slow down when reading from a mounted drive on a NAS such as the Western Digital MyBook Live.  This is probably due to have so many files in the band directory of the bundle.  To rectify this, one can create the sparse bundle ahead of time by doing something like this:

hdiutil create -verbose -type SPARSEBUNDLE -size 1T -imagekey sparse-band-size=262144 -fs HFS+J -volname myVolume myVolume
 This will increase the band size to 128 MB which should improve performance.

Point Carbon Copy Cloner to this pre-created disk image when doing the backup.