Matthew Hutchinson

Auto-syncing your local database from a remote MySQL Server (Dreamhost)

no comments yet, post one now

While redesigning this blog (which I still havent finished), I thought it
would be a good idea to setup an automatic synch; from my Live Typo
database at Dreamhost – through to my local Windows machine. Setup as a
daily cron, I now have all my Typo data fed through to my windows machine,
including all the posts, and settings I add and change here on the live

My local Typo install runs on Apache with FastCGi and MySQL. The cronjob
on dreamhost runs daily at 9pm (when im sure that my local machine is
turned on) – and simply calls this mysqldump command.

mysqldump --add-drop-table remotedatabasename -h remotehostname -u
remoteusername -premotepassword | mysql -u localusername -plocalpassword
-h localdatabasename

In order for this command to work, you’ll also have to setup the following;

  • Your local MySQL server must be configured to allow incoming connections
    from remote machines.
  • The MySQL user on your local server to access the database, should be
    configured to allow login from a remote connection, or a specific IP (e.g.
    your Dreamhosts box, IP address or hostname)
  • If you use a hardware firewall/router on your local machine, it must be
    configured to port forward on MySQL (usually port 3306) – to your local
    machine that has MySQL running.
  • Unless your firewall or local machine has been issued with a static IP,
    your going to need to use a service like
    - that gives your local router or PC a hostname you can always reference -
    and that is automatically updated when changed. After registering, offer this as a free service.
April 24, 2006 09:13 by

Multiple SVN users on Dreamhost

no comments yet, post one now

I recently recieved an email from Jonathan Arthur of OpenWebDesign, asking how I had managed to setup Subversion on Dreamhost with multiple SVN users. The Dreamhost SVN wiki page goes some way to explain the process, but heres what I did (with success);

The process is a little tricky, due to folder permissions and the way dreamhost sets up users and groups.

This mini-guide assumes you already have one repository setup and are able to access it with a single subversion user – as described in the dh SVN wiki page

To start, create new users (with shell accounts) to your server; I created ones with usernames like mattsvn etc. Do this in your dh web control panel, under Users→manage users→Add New User. Each of these users will get their own home directory on the dreamhost box.

Now (still in the web panel) create a new group; (Users→Groups→Add New Custom Group) call it something like devteamsvn – and add all your new svn users into this group (also add the user you already had svn working for)

Next – follow dreamhost’s instructions to create ssh public/private keys for each of these users in turn. (doing this in each of the users new home directories)

Take a note of all the passphrases you use – and also keep the public session keys you generate for each user – So they can be handed out for use with “Putty Pageant”: later.

Now, terminal into your dh box (as the orginal ssh user who created the repository to begin with) and change the group ownership (recursively) on the subversion repository folder; ie.

chgrp devteamsvn -R ~/path/to/your/svn/repository

And make sure that this group has full read/write/execute access to all files inside here with;

chmod 775 -R ~/path/to/your/svn/repository

Also – if you have a live web accessible folder online that you want everyone to be able to checkout into; you’ll need to change the group there as well;

chgrp devteamsvn -R ~/path/to/your/web/folder/you/plan/to/checkout/to
chmod 775 -R ~/path/to/your/web/folder/you/plan/to/checkout/to

Your now ready to try it all; Use Putty / Tortoise SVN and Putty Pageant with one of the new users details – Try connecting to the repository and committing a simple change or add.

For this user to checkout/update from the repository on the dreamhost to the dreamhost web folder – simply terminal into the dreamhost box using the new svn users details and run the command;

svn up /home/orginal_ssh_users_name/path/to/your/web/folder/you/checkout/to
April 24, 2006 05:56 by

Prepping for a MacBook Pro

no comments yet, post one now

Last week I finally gave in and placed an order for a new 2Ghz MacBook Pro. Being a PC user all my life, this will be my first switch to working on a Mac environment. I chose the MacBook Pro for 3 main reasons;

  • to test websites and work in a mac environment
  • for portability (I currently don’t own a laptop)
  • performance-wise it seems like it will have enough longevity to last me at least 3 years

Gearing up for this monumentous event, Ive been collecting bookmarks of Mac tips and tools I hope will be useful;

And for people switching from Windows to a Mac, or for those trying Bootcamp (Windows on an Intel Mac)

April 18, 2006 09:16 by

Taking sides in the enterprise argument

no comments yet, post one now

Debate is raging across the web against the Enterprise App, what it stands for, what Enterprise even means and how can companies justify huge complicated projects and budgets on what are essentially the simplest of tasks. Here are some excellent conuterpoints;

From which I quote …

We work in environments where IT budgets are in the tens of millions, and in a number of cases, hundreds of millions of dollars.

Response from Chris,

This is laughable. Huge budgets are usually indicative of run-away architecture and absurd turf-wars and protectionism, not actual success. Most IT budgets I’ve been around could be shaved 30-70% by the judicious use of the word “no”, and the refusal to accept stock answers from astronauts and certification-wielding automatons.

For example, I watched a large government agency—who asked me to do an analysis of mail requirements for an organization of several hundred thousand users—choose the absolute worst option because it was the “industry standard”. It cost 14x more than the lowest cost in simple capital, and had a on-going support run-rate that was approximately 5-6x anything else. The defense was that it was what the “industry” had chosen. The reality is, it was chosen because budgets equal power, and people equal promotions.

Shameless Bragging

1 comment

Jamie at Front has kindly informed me that PaperJam, a Flash website I built last year at Front, has recently been featured in the new Taschen Flash Sites book.

PaperJam (based in Belfast), do some amazing design work, which you can check out at the site – Note this book does not ‘glow white’ when opened, as the photo depicts.

April 15, 2006 07:57 by

Minty Fresh

no comments yet, post one now

Ive recently added Shaun Inman’s excellent (PHP/MySQL based) stats analyser Mint, providing me with a very fresh look at my site – By adding the GeoMint Pepper (plugin) I can now see where all you visitors are actually coming from (roughly).

It was all incredibly easy to install – 25mins from actually buying the thing I had it up and running with a bunch of peppers.

If you’re interested in listening about how the development of Mint encourages good API development listen to Shaun’s presentation at the Carson Workshops Conference earlier this year.

April 15, 2006 06:21 by

Upgrading to Rails 1.1

1 comment

While it may be considered good news that Dreamhost has upgraded their Rails distribution to 1.1 – it is causing a large number of problems with existing rails apps. There are reports of this happening across the web (Dreamhost, Textdrive etc.) as hosting providers install the new framework.

On a plus note Rails 1.1 looks promising and coupled with a new release of RadRails it should be a joy to work with.

March 29, 2006 08:38 by

Slowness, and back to Scribbish ...

no comments yet, post one now

Isnt this better ? Ive had my fun configuring Typo and playing around with its template engine. Its been a great introduction to Ruby; Unfortunately I have come to the conclusion that Typo – (although an excellent blogging application) – doesnt run with stability (or speed) on Dreamhost

Its fine locally on my machine and even throttling it through my debian box. But the Apache FCGI performance on here is lacking with Typo, perhaps because its a shared server – or the way Typo caches. Im not sure. If anyone else has experienced this or knows of ways to speed up Typo on Dreamhost – let me know. — edit.. ive stumbled upon this, which might help.

Also – since I didnt spend that long on my theme, I dont really mind ditching it for this one until I can dedicate some real time to it.

March 10, 2006 12:54 by

Holy miss-timed photo snaps Batman !

no comments yet, post one now

In probably the worst celebrity photo of all time, I managed to catch George Clooney coming out of the The Dorchester before heading to the 2006 Bafta awards last night, when some idiot Batman fan thrusts a photo in to get it signed right in front of me.


February 20, 2006 02:33 by



After weeks of dilberating and few hours of work, Ive managed to finish building a new Typo theme for this site. Ive left announcing it here until now, because im still not happy with it. Part of me wants to remove all images (header, icon etc.) and go for something plainer and quicker. So i’ll probably do that – I actually prefer the look of the footer to the header which is really just a grungy placeholder image for now.

Theres a little bit of AJAX and some moo.fx in the sidebar now – which should speed loading times up a little on the homepage which used to use the rather heavier scriptaculous – and all entries and comments are now using Textile (instead of Markdown)

February 17, 2006 04:02 by
← (k) prev | next (j) →