LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Enterprise (https://www.linuxquestions.org/questions/linux-enterprise-47/)
-   -   How can I instantly mirror data from 1 linux server to another? (https://www.linuxquestions.org/questions/linux-enterprise-47/how-can-i-instantly-mirror-data-from-1-linux-server-to-another-268940/)

abefroman 12-21-2004 05:06 PM

How can I instantly mirror data from 1 linux server to another?
 
How can I instantly mirror data from 1 linux server to another?

I want to have high availability in the event of a hardware failure.

sigsegv 12-21-2004 05:16 PM

You can't "instantly" mirror data to anything (including a raid mirror), but you can have a cron job that fires rsync to mirror two directories every hour or whatever.

sunwj82 12-21-2004 05:50 PM

You may find out the answer in


/etc/sysconfig/syslog

/etc/syslog.conf

sigsegv 12-21-2004 06:30 PM

Quote:

Originally posted by sunwj82
You may find out the answer in


/etc/sysconfig/syslog

/etc/syslog.conf

This is one of those times when I'll readily admit my ignorance ... How will syslog help mirror two servers so that you can have a warm standby in the event of a catastrophic failure?

abefroman 12-21-2004 06:36 PM

So, corporations use something similar to
* * * * * rsync -r 10.10.0.1:/ 10.10.0.2:/

To ensure high availability and 100% uptime?

sigsegv 12-21-2004 07:18 PM

Something like that. Ours uses several things like this, but a typical sync line looks like this:

rsync -avWHe ssh / root@server2:/

Be aware though -- to have true 99.999% uptime, you're going to need a load balancer or some other device to handle failover.

And really, it's not very efficient to sync the whole server. You're probably better off to juust sync the stuff that's not part of the base system -- i.e. html files or whatever.

abefroman 12-21-2004 10:21 PM

What is the best way to mirror a whole server? I have a hardware loadbalancer, I just need the data to be mirrored

How are they likely doing it:
http://powweb.com/PowWeb/Technology/Overview

sigsegv 12-21-2004 10:48 PM

I have no idea how powweb does it. I can tell you how I do it though.

Our site has 10 webservers with mirrored disks. The machines html/images are sync'd at build time, and then the servers are layer 3/4 balanced in front of that.

You can't sync the whole machine or you'll overwrite access logs, messages logs, network interface settings and all the stuff that makes an individual machine individual.

Builder 12-22-2004 05:59 AM

Quote:

Originally posted by abefroman
So, corporations use something similar to
* * * * * rsync -r 10.10.0.1:/ 10.10.0.2:/

To ensure high availability and 100% uptime?

No - we used shared storage on an HDS SAN. But I'm guessing you don't have that kind of spare change :)

If you look at the Red Hat Cluster Suite, you'll see that it requires simultaneous access to the shared storage from all machines in the cluster. This means that SAN is often the only way to go in a production environment as even the external storage units from HP won't allow you to dual initiate with their dual port scsi controller.

I think that the best way to achieve what you seem to be asking for on a budget is rsync. The next best solution might be an HP StorageWorks MSA1000 or the MSA30 MI. But with both of these, while you'll have access to your data from two machines, data lost in a single place is gone from both.

I guess what I'm getting at is are you looking to build an HA solution for availability, are you looking to protect your data from hardware failure, are you looking to protect your data from software failure or are you looking to protect your data from user error - all of these have different solutions :)

abefroman 12-22-2004 07:43 PM

Quote:

Originally posted by Builder
are you looking to protect your data from hardware failure, are you looking to protect your data from software failure or are you looking to protect your data from user error - all of these have different solutions :)
From hardware failure.

Has anyone used unison?
http://www.cis.upenn.edu/~bcpierce/unison

anand_kt 01-13-2005 02:58 AM

what server are you trying to failsafe ?
Is it like a webserver, datacenter or ... ?

Cos if its a webserver you can easily do it from your router itself by using round-robin
or some sort of load balancing schema based on ip's

ps : i have not worked with unison. But am guessing its advanced rsync. and not a failsafe.


All times are GMT -5. The time now is 09:33 PM.