Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

We are a small startup. In our current setup we have a dedicated server in a remote location. Our website and applications are hosted in that server. Website and some applications are in PHP and the rest are java applications using Tomcat and JBoss. Our database server is mysql. We backup mysql data to our local server using replication. Obviously thing can go wrong in multiple ways in this setup and they have. We had some serious downtime issues and other scares recently.

The new setup we have in mind is as follows.

1) Buying a new server with the same configuration as the current one. Setting this up similar to the current server with all the apps and software

2) Doing hot backup to the new server using BackupPC. (syncing only the often changing files like website, php apps, jboss and tomcat apps)

3) Running a mysql slave in the new server with semi-synchronous replication

4) Running apache/nginx/lighttpd as a reverse proxy in a separate server that points to the primary server.

5) Continue to run a slave in the local server

In case of downtime we can point the reverse proxy to the secondary server. We don't want to do automatic failover, because we have to make sure that the secondary server is fully synced before pointing to it.

What are the pros and cons of the above approach? Or how this can be improved? I understand the reverse proxy will be a SPOF. At this point we are looking for a cost effective solution. Can the reverse proxy be a low priced server with somewhat decent configuration?

I just put this together by reading various articles. It is possible that some of my understandings are wrong. Please feel free to correct them.

share|improve this question
    
You should elaborate a bit more on the kind of outages you want to prepare for. What you should do largely depends on what you want to prevent. –  the-wabbit Feb 8 '12 at 16:32
    
There was a spambot issue once. We had to disconnect the server and clean up the system. Then there was a bad sectors issue which resulted in some downtime. Mostly we want a backup server we can resort to in case of emergency so the we can work on the problem without worrying about the increasing downtime. –  Steve Feb 8 '12 at 16:45

1 Answer 1

a cheap and easy solution that would eliminate your SPOF and need for a reverse proxy would be to set your DNS with low TTL value (e.g. 60 seconds), and simply change the IP address when you want to switch servers.

If you use a DNS provider with Dynamic DNS support (or Amazon Route 53), you can even write a small script that would even automate the process for you.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.