httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roland RoLaNd <>
Subject RE: [users@httpd] syncing across web cluster
Date Mon, 23 Jan 2012 15:02:38 GMT

Thank you for your prompt reply.
I'm considering the rsync option as such;
for i in {1..7};do rsync -auze ssh  Source user@$i:destination  #on all 7 servers
though i might have a prob if a user edits a document (.doc files) on lets say ws1 and the
other servers sync to it ..

> Date: Mon, 23 Jan 2012 09:56:37 -0500
> From:
> To:
> CC:
> Subject: Re: [users@httpd] syncing across web cluster
> On January 23, 2012 9:35 , Roland RoLaNd <> wrote:
> > i've successfully setup web clustering between 7 web servers.
> How did you set up clustering?  There are several ways, and which one 
> you chose can affect the answer to your question below.
> > now i'm having a prob where a user uploads a file, and it only exists 
> > on the server that his session landed on.
> >
> > I'm seeking your help in possible ways to propagate files uploaded 
> > across servers.
> Let's assume your web servers are running under Linux.
> The easiest way (ignoring what you've already done to set up clustering) 
> is to use NFS to share the document root directories for your web 
> virtual hosts and/or to share the upload directories.  That is, one of 
> your machines will be a fileserver and export these directories to all 
> of the other web servers in your cluster.  If you need fault tolerance, 
> you can have multiple front-end servers with heartbeat and automatic 
> failover, possibly backed by a SAN.
> Another option is to have all web servers in your cluster periodically 
> (say, once every 5 minutes) synchronize their upload directories with 
> one another -- or, better and easier, a central host -- via rsync.
> What may be the best way is to not store the files in a filesystem, but 
> instead store them in a database -- preferably a NoSQL database such as 
> MongoDB or Cassandra -- so that all web servers can access them.  This 
> would require changing any script that uses the uploaded files to 
> retrieve them from the database instead of from the filesystem.
> --
>    Mark Montague
View raw message