[Sussex] MySQL replication

Jon Fautley jon at geekpeople.net
Fri Dec 3 16:49:28 UTC 2004


On 3 Dec 2004, at 16:14, matthew Macdonald-Wallace wrote:

> All,
>
> I've got a database that I keep on my laptop that I'd like to be able 
> to
> sync to my desktop every now and then.
>
> I'm after a way to basically sync the mysql databases between hosts,
> however as it is not a permanent connection (the database has a lot of
> GPS locations on it and the laptop collects more waypoints as I
> drive around), setting them up as a master and a slave seems excessive.
>
> Is there a way of syncing them over ssh or telnet?

The only problem I see with doing that is that you could end up with 
data collisions, but as I know what you're doing with your laptop, I'm 
guessing you won't be updating the DB on the desktop? If that's the 
case, then you could write a little script (probably in Perl, because 
it rocks) to dump the database to a CSV, then reimport it into the 
desktop whenever you a) run a command or b) have your GPS reciever 
detect you're outside your house, logon to the network, sync, then 
disconnect, or c) (probably easier, not half as geeky tho) wait for it 
to lock onto a wireless network :)

HTH,

Jon





More information about the Sussex mailing list