Saturday, May 24, 2008

It was so easy I thought I was kidding myself

I came home today to find my mantis server had stopped working. Something was wrong with the some aspect of the HDD. Not entirely sure yet, but I've put the drive in another machine and copied all the valuable data of it.

I was impressed just how easy it was to restore some aspects of the server. The physical machine I moved it to already had Apache on it. So it was a cut and paste of the Virtual Host and Listen line to configure and a bounce to get it going.

The next step was to reconfigure the router so that the server could be reach from the interwub. This was a 5 second job. Quick test, no database! Of course!

So I jumped on to the machine and quickly realised I couldn't access the existing MySQL install. Argh, what was I going to do? Try and reconfigure the current install of MySQL to point at the dodgy servers data? I thought I would have a look in the MySQL folder to see how the data was stored. There was a folder called data, and in that a folder with the same name as the database.

I wonder what would happen if I just cut and paste that

So I tempted fate (I have backups) and logged into MySQL, show databases and there it was. Ha! How awesome is that? OK, now for a real test. to access it via the mantis web-app. Works perfectly. Once again, awesome! Awesome like a million hot dogs.

Now, allow me to digress. I love it when applications don't bind themselves to the system that they are running on or force uses jump through some farcical ceremony just to perform a simple task. For instance, my brother has a Toshiba Gigabeat for his mp3 player. I remember him trying to get his songs onto it. You had to install their application and then work this ghastly interface just to transfer some songs. I think it was more than 24 hour period before he had everything working.

My Creative MuVo is literally a flash drive that I could drag and drop files onto. The music player app was smart enough to work out folder structures and to not trust the file system state as it last remembered it. My Nokia N95 8GB thankfully supports both methods.

Last time I checked most users know how to drag and drop a file and while it might not be immediately obvious that your application can support such advanced functionality, it is nothing that good documentation can't fix. If you have to spend lots of money writing an application, try making it one that wraps a GUI around the cut and paste process. You will save money if nothing else.

Anyway, I have just finished copying some music onto my phone. Time to go to sleep with some soft tunes ghosting through my headphones.

No comments: