[Csync2] speed of "-cr /"
Lars Ellenberg
lars.ellenberg at linbit.com
Mon Jun 7 16:02:31 CEST 2010
On Sat, Jun 05, 2010 at 02:46:48AM +1000, Aristedes Maniatis wrote:
> When I want to check all files for updates, I need to run 'csync -cr /'. But that command is far too slow.
>
> Looking at the configuration, I might only be Including a dozen folders in various parts of the filesystem and if I perform:
>
> csync -cr /usr/local/etc/apache22
>
> for instance, then the command is extremely fast. Why does csync not
> look at the values of the 'include' statements when traversing through
> the file system to check for file changes?
csync2 -cr /
does exactly that:
it looks at its database, and stats all files listed in that database,
as well as directories, and compares the recorded stat info with the
"live" stat info.
In case a directory stat info has changed, that directory needs to be
scanned for potentially added files.
Excludes (or non-includes) are respected.
> I don't want to have to
> call csync separately with every path I've already gone to the trouble
> of "including" in the config file.
csync2 does already what you ask for.
You may add a few -v to your csync2 command line,
or use strace, to see what it is doing?
If all else fails, contact someone experienced with csync2
(read: LINBIT) for consultancy ;-)
--
: Lars Ellenberg
: LINBIT | Your Way to High Availability
: DRBD/HA support and consulting http://www.linbit.com
DRBD® and LINBIT® are registered trademarks of LINBIT, Austria.
More information about the Csync2
mailing list