Subject: Re: [TAG] Mirror 2 web servers (fwd)

From: John Karns <[email-masked]>
Date: Wed, 24 Mar 2004 11:11:39 -0500 (COT)

Hmm, re-sending, as it didn't get through the first time.  Seems that my
ISP here has changed their mail server cfg yet again, and is not allowing
relay as before.  Probably would help if they would quit using redmond
OS's on their servers and switch to something a little more reliable.

--  
John Karns

---------- Forwarded message ----------
Date: Tue, 23 Mar 2004 00:28:41 -0500 (COT)
From: John Karns <[email-masked]>
To: Love Sundin <[email-masked]>
Cc: [email-masked]
Subject: Re: [TAG] Mirror 2 web servers

On Thu, 18 Mar 2004, Love Sundin so eloquently said:

> Hi  folks at ,The Answer Gang
> 
> I have two webservers running linux (redhat)
> one of them is the primary server and the other one acts as backup
> 
> the thing is that i want to be able to mirror these servers in both ways
> 
> including this:
> 
> * mysql databases
> *http folder
> *httpdconfig
> 
> i was thinking a shell script would do the trick!
> but my competence ends just after #!/bin/bash!
> 
> i am not asking for a complete script
> 
> just some were to turn for help :)

Just thought I'd mention a few general suggestions.

To read up on bash scripting, you might want to take a look at the 
"advanced bash scripting guide" at one of the following URL's:

===============================================================

Linux Documentation Project:
http://www.tldp.org/LDP/abs/html/
http://www.tldp.org/LDP/abs/html/index.html
http://www.tldp.org/LDP/abs/abs-guide.html.tar.gz
http://www.tldp.org/LDP/abs/abs-guide.pdf

Sunsite:
http://www.ibiblio.org/pub/Linux/docs/linux-doc-project/abs-guide/
Postscript --
http://www.ibiblio.org/pub/Linux/docs/linux-doc-project/abs-guide/abs-guide.ps.gz
Text --
http://www.ibiblio.org/pub/Linux/docs/linux-doc-project/abs-guide/abs-guide.txt.gz

Sunsite:
http://www.ibiblio.org/pub/Linux/docs/linux-doc-project/abs-guide/

Author's home page:
http://personal.riverusers.com/~thegrendel/abs-guide-2.6.tar.bz2  [ 624k ]
   (bzip2-ed tarball containing SGML source, all example scripts,
    and rendered HTML)

===============================================================

"man bash" at the command prompt will yield the extensive bash man page,
assuming that you have it available on your system.

Also, there are some articles on the subject in the archives of the Linux 
Gazette, some of which were authored by Ben Okopnik, one of the members of 
the answer gang.

The rsync utility is often used for mirroring and can save bandwidth.  For 
the MySQL side of it, you may need to get a bit more creative.  I would 
suggest fishing around on the 'net for DB mirroring with MySQL, as I 
think rsync is intended more as a tool to deal with plain ASCII files, 
although I could be off on that.

--  
John Karns
_______________________________________________
TAG mailing list
[email-masked]
http://linuxgazette.net/mailman/listinfo/tag

---

From: Ben Okopnik <[email-masked]>
Date: Wed, 24 Mar 2004 11:54:07 -0500

> Gazette, some of which were authored by Ben Okopnik, one of the members of 
 
Yep. Just search for "shell scripting" (including the double-quotes) at
<http://linuxgazette.net/search.html> and you'll see it right at the top
of the stack.

> although I could be off on that.

[grin] Just a little, John. "rsync" is intended for file transfer in
general, no restriction as to type. I use it with the "-e ssh" option
(actually, I have "RSYNC_RSH=/usr/bin/ssh" set in my "~/.bash_profile"),
so it uses SSH as the underlying mechanism, but "rsh", although
deprecated in most situations, is also type-independent (although it's
somewhat clunky - the STDIN/STDOUT method of transferring data does make
it _look_ like a text-specific gadget.)

* Ben Okopnik * okopnik.freeshell.org * Technical Editor, Linux Gazette *
-=-=-=-=-=o0o=-=-=-=-= <http://linuxgazette.net/> =-=-=-=-=o0o=-=-=-=-=-
_______________________________________________
TAG mailing list
[email-masked]
http://linuxgazette.net/mailman/listinfo/tag