PDA

View Full Version : Master/Slave server help


Mrquarter2
11-25-2009, 04:08 AM
Okay, so I don't know how to fully do this but here it goes.

Simply, I want to have my forums on a webhost, and have a game server running on my dedicated server. The game server uses the MySQL database from the vBulletin to read in the usernames, passwords, and other things. I had integrated them together for practical purposes.

My problem is now that the mysql database must stay on the database so that the server has the best response time. But with this, my forums are suffering speed because it has to load everything from a MySQL server that isn't local.

I am wondering if there is a way that it will write to the local one and the dedicated server one, but only read from the local one. Basically a master, slave set up.

My site also gets attacked frequently which would affect it more because the SQL isn't on the localhost, so it would cause much more of a delay. I am just looking for a way for it to write to the localhost and the dedicated server one, but only read from the localhost. So the speeds are good.

But I don't want to mess anything up. Can anybody tell me how I can achieve this?

Angel-Wings
11-28-2009, 02:36 AM
<a href="http://www.howtoforge.com/how-to-set-up-mysql-database-replication-on-fedora-10" target="_blank">http://www.howtoforge.com/how-to-set...n-on-fedora-10</a>

Has some inspirations on how to do it - Fedora related but just the paths differ for other Linux distro's or systems.
Generally I recommend using some encryption layer - had some bad experiences with MySQL's builtin SSL layer so maybe a SSH tunnel with automatic port forwarding or a VPN might be a useful solution.