Mark Wass wrote:

Hi All

I'm using Rsync to backup my servers and was wondering how I would specify backing up only zip files in my config.

For example here is my tree structure

/Folder1
 |
 -Files
 -Temp
 |  |
 |  - File1.zip
 |  - File2.doc
 |  - File3.zip
 |  - File4.exe
 |
 -Hello

If my config file had a share name like this:

$Conf{RsyncShareName} = ['/Folder1/Temp'];

How do I only backup the zip files in this location?

Could I use this combination in the config?

'--exclude', '*.*',
'--include', '*.zip',

Reading this would say, exclude all files in the
/Folder1/Temp folder and then include all zip files found in the /Folder1/Temp folder. Is this valid?

You should only need to do something like this.....

$Conf{BackupFilesOnly} = [ '*.zip' ];
 

Try that.

Les

Reply via email to