Search code examples
backuprsyncrsnapshot

Rsnapshot Issue


I am trying to do some backups with Rsnapshot and am constantly getting this error:

/usr/bin/rsync -av --delete --numeric-ids --relative --delete-excluded \
--stats -L --whole-file --exclude=*/web/ --exclude=*/tmp/ \
--exclude=*/dms/ --exclude=*/Recycle\ Bin/ --exclude=*/app/logs/ \
--exclude=*/app/cache/ --exclude=*/vendor/ --exclude=/var/www/files/ \
--exclude=*/releases/ \
--exclude=/var/www/www.xxx.net/app/var/sessions/ \
--rsync-path=rsync_wrapper.sh --exclude=/var/www/psan-static/ \
--rsh=/usr/bin/ssh -p 9922 [email protected]:/var/www \
/data-ext/backups/rsnapshot/daily.0/myserver/

Unexpected remote arg: [email protected]:/var/www
rsync error: syntax or usage error (code 1) at main.c(1348) [sender=3.1.0]
----------------------------------------------------------------------------
rsnapshot encountered an error! The program was invoked with these options:
/usr/bin/rsnapshot daily
----------------------------------------------------------------------------
ERROR: /usr/bin/rsync returned 1 while processing [email protected]:/var/www/
/usr/bin/logger -i -p user.err -t rsnapshot /usr/bin/rsnapshot daily: \
ERROR: /usr/bin/rsync returned 1 while processing \
[email protected]:/var/www/

I was trying to play with parameters but cannot figure out what's the issue


Solution

  • The issue was with the

    --exclude=*/Recycle\ Bin/

    This needs to be quoted as spaces seems not to work.

    --exclude="*/Recycle\ Bin/"