Can rsync monitor a file system?

Tim H tim at simulat.com
Wed Jun 28 05:24:30 GMT 2006


couldnt you do something like this?:

----always running.sh---
while true
do
    if file not exists "isrunning.txt"
    sh checkfiles.sh
    sleep 30
done

----checkfiles.sh---
# compare dirlist here
if [ need to run rsync ] and [file not exist "isrunning.txt"]
    touch isrunning.txt
    rsync .....
    rm -f isrunning.txt
fi



----- Original Message -----
From: <tony at servacorp.com>
To: <cbiedl at gmx.de>; <rsync at lists.samba.org>
Sent: Tuesday, June 27, 2006 12:41 PM
Subject: RE: Re: Can rsync monitor a file system?


> cbiedl at gmx.de wrote:
> >
> >Charles.Berman at pfpc.com wrote...
> >
> >> How would you set a cron to run every 30 seconds?
> >Otherwise it could work
> >> for me.
> >
> >With a start every 30 seconds you're in the high
> >risk an an overrun.
> Possibly saved by max connections =1 or such.
>
> >Don't do cron, use a simple shell script with
> >"while true; " and
> >"sleep 30".
> >
> >But believe me, this is a bad idea.
> I suspect you're right;)
> When things take off automatically on their own, you get
> troubles in places you didn't know you had places.
> Debris from failed transfers.
> Subtle errors that put an extra copy one level off.
> (mirror in a mirror, ...  ... until you run out of ...)
> (and that's without knowing what I'm talking about)
> (Figure reality has several considerably worse ...)
>
> I think that handling deletes becomes a nightmare, or
> at least must be handled carefully and severly restricts
> the choices possible for updates.
> --
> To unsubscribe or change options:
https://lists.samba.org/mailman/listinfo/rsync
> Before posting, read: http://www.catb.org/~esr/faqs/smart-questions.html



More information about the rsync mailing list