Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a VPS with our Ubuntu LoCo Team's blog, but I want to setup a message that says the server is down when it happens, like Reddit and Twitter does.

For example, if I restart the server or my VPS goes down, I want the user to load another page, from another server, saying the site is down and will be back soon.

I guess that can be done with redundancy, but I don't know anything about it to be honest. Is that possible and there is any tutorial about it?

I searched a lot, but since I don't know how to call this "feature", I don't really know what to look for.

Anyway, if it helps, I use Nginx, PHP-FPM, PHP-APC and Ubuntu Server 12.04. My DNS is hosted at CloudFlare Pro.

Thanks in advance :)

share|improve this question

closed as not constructive by Sven, mdpc, Magellan, Ward, John Gardeniers Jan 13 '13 at 5:38

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

CloudFlare already provides such a page for you. – Michael Hampton Jan 12 '13 at 19:21
@MichaelHampton I know, but it I want to create my own. – Julian Fernandes Jan 12 '13 at 21:34

Such solutions are typically achieved through a proxy or a load balancer.

A large site like reddit doesn't serve everything from one server. There's a load balancer in the front. And when it detects that it's web servers (such as one running php-fpm) is no longer responding, it responds with an error 503.

You already have two tools that can achieve this. Cloudflare and nginx.

Cloudflare is a mix of CDN & proxy service and offers you such tool already. This will be the simplest route.

Nginx also has the ability to act like a proxy and/or load balancer and can serve custom errors depending on certain situations. Like the php-fpm not responding. However, this would obviously require you to have at least 2 independent servers.

share|improve this answer
Thanks for the answer. CloudFlare does offer this solution, but I want to create my own. I can create custom ones there, but it must have they brand on it, by what I saw :/ – Julian Fernandes Jan 12 '13 at 21:36
@JulianFernandes You can use nginx then as already mentioned. – Grumpy Jan 12 '13 at 23:40

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