Linux – Mirroring linux installation

linuxmirroring

I have a live server that I want to completely mirror to a 2nd server so if something were to happen to the live server the backup server could simply be plugged in and ready to go.

How do I setup a mirror between 2 separate machines?

Best Answer

One way to do it is to use the heartbeat package. Install it on both servers and configure them in active-passive mode. If one server failed, the other will be ready to serve the users.

For debian-based systems such as ubuntu, you can install it by;

$ sudo apt-get install heartbeat

You can use three IP addresses for two servers. One IP is assigned for each machine and the third IP (called VIP: virtual IP) is assigned by heartbeat to the currently active server. The users will access the provided service via the VIP.

Related Topic