LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 05-20-2010, 04:12 AM   #1
cooljai
Member
 
Registered: May 2007
Location: /dev/random
Distribution: CentOS, Fedora, RHEL, SuSE
Posts: 62

Rep: Reputation: 15
Question which is the better way to rsync files between web servers?


Hi,

I've 15 web servers (in private network) running RHEL, Apache. Needs to sync web files between them. each server is accessible to each other via public key (with passphares).

Here are two cases, I can think about, Please let me know your views and best possible way to implement it.

1) Main server is web1 (where dev upload files initially). So I can make all other servers accessible by web1 without password/passphares and run rsync periodically to update files between them. But security is an issue here as all servers will become easily accessible.

2) Run rsync daemon in all other servers (except web1) on designated port and run rsync command from web1 to sync files. This will do the work but running daemon in all servers might increase overhead and making sure that daemon is running all the time etc. are my concern for this implementation.

Kindly suggest. Thanks in advance.
 
Old 05-20-2010, 04:24 AM   #2
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
Option 1 is fine, security is not really an issue as the account performing the rsync would have to be compromised first. Another possible option is mounting a central location via NFS ...
 
Old 05-20-2010, 05:54 AM   #3
cooljai
Member
 
Registered: May 2007
Location: /dev/random
Distribution: CentOS, Fedora, RHEL, SuSE
Posts: 62

Original Poster
Rep: Reputation: 15
Thanks kbp for reply but isn't NFS mount will create a single point of failure? At this moment, servers are almost independent to each other and only needs file refresh once in while. Using NFS might make them more vulnerable to issues I think.

Please advice.
 
Old 05-20-2010, 09:37 AM   #4
JD50
Member
 
Registered: Nov 2007
Location: Virginia
Distribution: Fedora, RHEL, CentOS
Posts: 67

Rep: Reputation: 17
Quote:
Originally Posted by cooljai View Post
Thanks kbp for reply but isn't NFS mount will create a single point of failure? At this moment, servers are almost independent to each other and only needs file refresh once in while. Using NFS might make them more vulnerable to issues I think.

Please advice.
Have you thought about clustering?
 
Old 05-20-2010, 09:16 PM   #5
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
You can create a simple active/passive nfs cluster using keepalived...
 
Old 05-21-2010, 05:14 AM   #6
cooljai
Member
 
Registered: May 2007
Location: /dev/random
Distribution: CentOS, Fedora, RHEL, SuSE
Posts: 62

Original Poster
Rep: Reputation: 15
Quote:
Originally Posted by kbp View Post
You can create a simple active/passive nfs cluster using keepalived...
that's seems quite interesting.. can you provide more insight.. link? tried googling but seems process of setting up such cluster is not so simple, IMO.
 
Old 05-21-2010, 05:21 AM   #7
EricTRA
LQ Guru
 
Registered: May 2009
Location: Gibraltar, Gibraltar
Distribution: Fedora 20 with Awesome WM
Posts: 6,805
Blog Entries: 1

Rep: Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297Reputation: 1297
Hello,

Have a look at Unison Synchronizer. I'm sure it'll suit your needs perfectly and it's a lot easier to set up, runs over an SSH tunnel (which takes care of the security part), allows changes on multiple instances on a file, and so on. I use it for little over a year now on production servers and hasn't failed me yet. No need to set up extra configurations, file systems, nothing.

Kind regards,

Eric
 
Old 05-21-2010, 09:51 PM   #8
kbp
Senior Member
 
Registered: Aug 2009
Posts: 3,790

Rep: Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653Reputation: 653
I've modified/sanitised a script I used recently, rename to .sh

cheers
Attached Files
File Type: txt keepalived_nfs_cluster.txt (3.5 KB, 57 views)
 
Old 05-21-2010, 11:32 PM   #9
JD50
Member
 
Registered: Nov 2007
Location: Virginia
Distribution: Fedora, RHEL, CentOS
Posts: 67

Rep: Reputation: 17
Quote:
Originally Posted by cooljai View Post
that's seems quite interesting.. can you provide more insight.. link? tried googling but seems process of setting up such cluster is not so simple, IMO.
Look into Red Hat Cluster Suite, or use the free version from CentOS if you don't have or don't want to pay for a Red Hat subscription.
 
  


Reply

Tags
rsync


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Could I run rsync to download files from a server without rsync daemon? Richard.Yang Linux - Software 1 09-18-2009 04:08 AM
SSL and web page files on different servers sbarkey Linux - Newbie 2 07-03-2008 06:59 AM
Web Servers don't want to show [larger] .tar and .rar files? brokenpromises Linux - Server 1 01-22-2008 11:53 PM
Mirroring servers using RSYNC RKris Linux - Networking 1 05-15-2003 06:26 AM
Software for synchronizing files on web servers josephswagner Linux - Software 2 02-06-2003 12:13 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 12:34 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration