Monthly Archives: October, 2008

Limiting the size of your Time Machine

If you use Apple’s wonderful Time Machine backup system, the best thing to do is to give it a hard disk of its own, or a partition of its own, because it tends to grow over time to fill the space available, and trimming it later is not easy.

I’ve got about 3TB of space on my Drobo, and I don’t want it all used for TM, but partitioning is a bit of a nuisance. Fortunately, there’s a free tool you can download from Drobo called Time Tamer, which you can use for any large disk, and which will limit your TM backup space to twice the size of your internal hard drive.

For those of you who want more control and who are interested in what’s happening under the bonnet, though, you can do this yourself. It involves creating a sparse disk image file with the right characteristics and name. TM will then use that instead of creating its own folder structure, and you can limit the size to which the sparse image will grow.

Here’s my command line:

hdiutil create -size 400g -fs HFS+J -volname "TM-backup-of-tafelberg" /Volumes/Drobo/tafelberg_0016cb9125cf.sparsebundle

  • 400g is the max amount of space I want it to take – the max size of the sparse image.
  • tafelberg is the name of my machine
  • Drobo is the name of the hard disk I’m using
  • 0016cb9125cf is the MAC address of my machine’s ethernet port

This creates a sparse image on the disk called, in my case, tafelberg_0016cb9125cf.sparsebundle.
If you switch off Time Machine, move, rename or delete any Backups.backupdb folder that TM may have created there, run an appropriately modified version of this command, and then switch TM back on and select the original disk as the one to use, TM should notice this image and use it to store the backups.

I guess you’ll know if it worked if TM doesn’t create Backups.backupdb again at the top level of the disk!

Followup: Mmm. I found that, when I used this method, and then went into Time Machine, I didn’t get the pretty windows disappearing into the past – it just showed Today. If I mounted the image as a drive, however, the backups seemed to be there and I could restore from them. The moral being that you should check that restoring works for you too if you use this method!

The World Wide Wardrobe

I have a large number of business ideas which I’ll never get a chance to turn into companies. For most of them, that’s probably just as well. Here’s one I’ve been thinking about recently…

Many people travel regularly to another city. Not regularly enough to have an apartment there, but sufficiently often that the process of carrying a suitcase of clothes back and forth is a real pain. I think what is needed is a way to have a wardrobe in the places you visit most often. I’d like to create a business which does this and the great thing is that I can just piggy-back it on existing services. Here’s how it works:

You go to a hotel, stay for a few days, and on departing you just leave behind any clothes that you’d like to stay in that city. The hotel laundry washes your clothes, and puts them in a specially design cardboard wardrobe, which is then picked up and put into storage. When you’re next returning to that city, you just call up or log on and say where you’ll be staying, and the clothes are hanging in your wardrobe when you get there. The cardboard wardrobe might have a special drawer for toiletries etc as well.

If you stop visiting that city, then for a modest charge, the wardrobe can be shipped back home, or to wherever your business is taking you now.

Neat, huh? Now, I was explaining this to a couple of lady friends of mine over lunch recently, and they pointed out that this was clearly a male-centric view of the world, because women would (a) want to have much more control over the precise clothing they had available for a particular trip and (b) wouldn’t want to leave valuable outfits behind in some far-flung part of the world. I suggested that part of the storage process could include an automatic photographing of each of the items of clothing, so you could see on the website exactly what would greet you when you opened your wardrobe in San Francisco, but they still seemed unconvinced.

For the average travelling bloke, though, I think this could work quite well. What do you think? Anyone feel like investing in an exciting new globe-spanning venture?

More debunking

A couple of people have told me how much they enjoyed James Randi’s talks.

If you liked those, and you haven’t yet seen it, you really owe it to yourself to watch Michael Shermer’s TED talk, which is one of my favourites.

“Some people call us debunkers, which is a kind of negative term but, let’s face it, there’s a lot of bunk!”

Google hint of the day

You can associate multiple email addresses with your Google account. Just edit your account info.

Then when people send you invitations to join calendars, share documents etc, at something other than your Google address, they will all be associated with your one Google account.

Some Linux backup utilities

For some years I’ve been backing up my various Linux-based servers, websites etc using a custom script which makes incremental tar-based backups of key directory hierarchies, dumps some MySQL databases, and then copies the lot to a remote machine using scp or rsync. We run this each night using cron. It’s worked well, but it’s becoming rather spaghetti-like since we run some version of it on several machines, copying stuff to several other machines. And the process of pruning old backups to keep disk usage under control at both the sources and the destinations is somewhat haphazard.

So I’ve been looking at various other backup systems which may do a more manageable job. The big systems in the Unix world are the venerable Amanda and the more recent but highly-respected Bacula. I may do something based around Bacula in due course, but for now I needed something quick. Here’s a quick rundown of some useful backing-up scripts. They all make use of rsync, or the rsync algorithm, in some way, but do more than just copy from A to B.

rdiff-backup
You can think of this as an rsync which keeps some history. The destination ends up with a copy of the source but also has a subdirectory containing reverse-diffs so you can get back to earlier versions. This is rather nice, I think, and it can pull the backups from or push them to a remote machine, though it does need to be installed at both ends. It’s mostly Python and relies on librsync. The standard Ubuntu rdiff-backup package isn’t very recent so I built and installed it by hand.
duplicity
This looks good and is being actively maintained. It’s a bit like rdiff-backup but focuses on encryption, and uses incremental tar-based backups. For me, the downside was that it’s push-only – you run it on one machine to send backups to another – and I was more keen on pulling from several machines under centralised control. Update: I later discovered that pushing can have some real advantages. One is that it can often be easier to manage the permissions of the backup user on the machine where the data exists. It might be a cron job run as root, for example. Another is that you may not always be able to install software or cron jobs on the machine where you want to store the backups. Also, duplicity has some interesting backends for things like Amazon S3. I’m using duplicity more now than when I first wrote this.
rsnapshot
In the short term, I think this is the one that will suit me best. You can create categories like ‘hourly’, ‘daily’, ‘monthly’, and specify how many of each you’d like kept. It creates complete copy directories for each copy of each one, but where the files haven’t changed they are simply hard links to the previous ones, so it’s pretty efficient on space. And a single configuration file can perform lots of remote and local backups. I suppose the downside is that the hard-link based architecture limits the range of filesystems on which you can store your backups, but if you’re firmly in the Unix world this seems to work rather well.

Just in case anyone else is looking…

Update: Emanuel Carnevale reminded me about:

Unison
Unison is a bit like rsync but does bi-directional synchronisation – it can cope with changes being made at either end. I hadn’t really thought of it as a backup tool, but – perhaps because two-way synchronisation can sometimes do unexpected things – it does have the ability to keep backups of any files it replaces. One more option if you need it…!

Falling markets

My first computer, a Sinclair ZX81, cost £69.95. Since then, every computer I’ve owned has cost more – usually substantially more. Until today.

Today I bought a new laptop for £179 inc. VAT, which in real terms is less than my ZX81 of 27 years ago. Progress at last! And this one I didn’t have to plug into a cassette deck and an elderly black-and-white TV!

It’s an Acer Aspire One, and I have to say that, so far, I’m really impressed. It runs OpenOffice, Firefox, Thunderbird and Skype very nicely, and it includes a few things like a camera and microphone that work remarkably well – I’ve just had a video-Skype call with my pal Jason while walking around the house.

2008-10-24_20-25-16

Of course, it has some limitations – it boots up very much faster than any Windows machine I’ve ever seen but it’s not like a Mac’s almost instantaneous wake-up from sleep. I couldn’t write this post on it but only because it can’t read the RAW-format images from my SLR, and I couldn’t watch movie trailers on the Apple site because you can’t get Quicktime for Linux. But the number of things it can do rather well are remarkable, and I could happily survive with it for a weekend when I didn’t want to carry anything heavier, or use it to catch up on news at the breakfast table.

It may not be a Mac, but it’s certainly not a ZX81!

Putting it to the test

A very good way to pass an enjoyable few minutes on YouTube is to search for James Randi. Randi, for those who don’t know, is a magician, but he’s better known as a debunker of the paranormal and pseudoscientific. He’s also an amusing speaker… here’s a little clip where he explains homeopathy:

And there are lots of other nice examples out there – a TV appearance where he puts a graphologist to the test, for example.

And here he talks about Uri Geller, and the faith healer Peter Popoff:

The J. Randi Educational Foundation has, for several decades now, been offering a prize – now standing at $1M – to anybody who can demonstrate any psychic, supernatural or paranormal ability under proper scientific observation. Here are the details if you want to have a go, and the process is documented in the open on the JREF forums. Even getting past the preliminary test will get you $10,000. So far, none of the hundreds of applicants has got that far.

Wind & sun

The evening sun caught these wind turbines on Friday, just as we were descending into Frankfurth-Hahn airport.

I know some people consider them a blot on the landscape, but I’ve always thought them rather majestic.

Infrequently Asked Questions

From RyanAir’s FAQ:

DOES RYANAIR CARRY HUMAN REMAINS?

Ryanair only carry human remains on the London Stansted-Knock route. To make a reservation you must contact Skytrader in Birmingham on +44 870 4422979.

Somehow I feel there must be an interesting story behind that.

Quote of the day

Another one from Dr Seuss:

“Don’t cry because it’s over. Smile because it happened.”

Elephant sends text message

The mobile phone revolution really is sweeping across Africa.

Story here.

If the world could vote…

Martin sent me a link to this quite interesting site – if the world could vote for the US president, whom would you pick?

Now, this is a cute idea, though of course the rest of us won’t have to live with the domestic decisions, the tax burden, the healthcare system etc. of whomever gets chosen. And I wish it had been done by somebody inside the country rather than an outsider.

None the less, it’s valuable data, so as long as you can say with a clear conscience that you wouldn’t mind Americans making suggestions about your next leader, cast your vote!

© Copyright Quentin Stafford-Fraser