xfs
[Top] [All Lists]

Re: using xfsdump to synchronise filesystems?

To: Matthijs van der Klip <matthijs.van.der.klip@xxxxxx>
Subject: Re: using xfsdump to synchronise filesystems?
From: ivanr@xxxxxxx
Date: Thu, 6 Dec 2001 11:46:56 +1100
Cc: Linux XFS Mailing List <linux-xfs@xxxxxxxxxxx>
In-reply-to: <Pine.SGI.4.33.0112051455310.1353054-100000@kwek.omroep.nl>
Sender: owner-linux-xfs@xxxxxxxxxxx
On Wed, 5 Dec 2001, Matthijs van der Klip wrote:

> I know this is a bit of a crazy idea, but I'd like to know if something
> like this is (remotely) possible...
>
> 1) Take a server with a 10Gb (max) volume. This volume is live: files are
>    being added/deleted through ftp (Read/Write).
>
> 2) Take x clients which need to receive a synchronised copy of the
>    mentioned volume above. Contents have to be served out through http
>    (Read only).
>
> Would it be possible to say make a level 0 dump every night, a level 1
> dump every hour, and a level 2 dump every 5 minutes (or use even more
> levels?) and then restore these dumps on the clients to keep their volumes
> synchronised?
>
> Reason I'm asking this is I'm looking for a way to distribute only changes
> in a filesystem. Rsync has to scan the whole filesystem and just takes to
> long.

I don't think xfsdump is a very good choice here.  xfsdump will scan the
entire filesystem every time you run it, even if you select a higher level
dump.  I doubt that for a 10GB filesystem it will be able to run to
completion within 5 minutes ('course this depends on your circumstances).

Try timing this:

  xfsdump -L session -M media -f - /path/to/filesystem > /dev/null

and see how long it takes.

Specifying higher levels for xfsdump only reduces the amount of data that
it writes out, it will not necessarily reduce it's running time. Certainly
the initial setup phase will take longer (how long depends on the
filesystem).

I think you'd be better off monitoring the ftp log to see what files have
changed and then use rsync on those.  I'm sure it'd be fairly easy to do
this in something like perl.

Ivan

-- 
Ivan Rayner
ivanr@xxxxxxx


<Prev in Thread] Current Thread [Next in Thread>