axkibe/lsyncd — Issue #26: Another binary/script with parameters
Author: axkibe
Created: 2011-11-16 14:58:40+00:00
State: open
Labels: Type-Other

Originally filed by gerhard....@gmail.com on 2010-08-16T09:35:55

Hi,
I don't know, if my question is right here (sorry for bad english ;) )

I have Archlinux and install lsyncd-1.37.

I plan to bild a backup like windows shadowcopy.
I find incron, but incron can't watch recusive.

In find --binary in the lsyncd manpage. Start lsyncd only the binary, or can I give the binary parameters (varied filename /path) ?

If I can use parameters, then I wirte a bash script and use cp to copy the file like that:

################################
time=$(date '+%H_%M')
cp -r "$1" "/path/to/the/backups/$(date '+%Y')/$(date '+%m')/$(date '+%d')/$time"
################################

$1 is the parameter of the file, witch is, varied.

Thanks
GerhardSchr

PS.: If I must write these question somewhere else, please tell me this :)