Re: Mirror applications on Linux Server
I am building an application which needs to have high reliability.
I have two essentially identical Linux servers which can host the
application. Right now, I have the programs - a bash script and a c
binary, running on one machine every minute in a cron job. I also
have an rsync cron job running to synchronize the files on the
standby machine so the data (and binaries, of course) will be identical.
Thanks. I skimmed the intro, and I'm not sure heartbeat is really what
I need. These aren't server applications that run full-time on the
machine. They are relatively simple programs that only take a few
seconds to run, and then terminate (hopefully with a return value of
0), to be run again in 60 seconds. I don't need the inter-machine
service to cause something to happen on the standby system if the apps
are no longer running, or at least not immediately so. Rather, I need
the standby machine to take over if:
This might work:
1. Use DRBD to keep your disks (or specific volumes) in sync. Run it in
it's standard primary-secondary mode.
2. Run the job on both machines. When it starts, have it check whether
the volume is in primary or secondary mode; if in secondary mode, abort.
Of course that only works if your backup machine doesn't need to access
the disk volume for other things.
In theory, there is no difference between theory and practice.
In<fnord> practice, there is. .... Yogi Berra