Hi Shawn, Try doing this.
mount -t smbfs -o username=SOMEUSER,password=SOMEPASSWORD //COMPUTERNAME/SHARENAME /mnt/network/COMPUTERNAME/SHARENAME tar -czvf /backup/COMPUTERNAME/COMPUTERNAME-SHARENAME-`date +d%d-m%m-y%y-t%H.%M`.tgz --ignore-case --exclude Windows --exclude Winnt --exclude pagefile.sys --exclude NTDETECT.COM --exclude ntldr --exclude IO.SYS" /mnt/network/COMPUTERNAME/SHARENAME This would mount a share, ignore case, and backup everything from this share except "Windows", "Winnt", "Pagefile.sys", "NTDETECT.COM", "ntldr", and "IO.SYS". You can use the exclude flag as many times as you want. This isn't the best way of doing it. Doing it this way becomes quite challenging to perform incremental backups. Also, I have found this method to hang on occasionally without continuing. The advantage of doing it this way though is that you can compress your backups on the fly. The other method is using SMBTAR.... datevar=`date +d%d-m%m-y%y-t%H.%M` smbtar -v -s IPADDRESS -u SOMEUSER -p SOMEPASSWORD -x SHARENAME -t /backup/COMPUTERNAME/COMPUTERNAME-INCREMENTAL-SHARENAME-$dateVar.tar -i gzip /backup/COMPUTERNAME/COMPUTERNAME-INCREMENTAL-SHARENAME-$dateVar.tar rm -f /backup/COMPUTERNAME/COMPUTERNAME-INCREMENTAL-SHARENAME-$dateVar.tar This would do an incremental backup. To exclude you can use the "-X" flag. To do a full backup instead of incremental get rid of the "-i" flag. This method will not compress in real time (if you find a way please let me know). Regards, Brian Horncastle -----Original Message----- From: Shawn [mailto:[EMAIL PROTECTED] Sent: Friday, November 28, 2003 12:18 AM To: CLUG (E-mail) Subject: [clug-talk] RE: Tar Question Hi all. I've taken my cue from Brian and his efforts to provide a backup over an SMB share. I'm trying to backup my Windows data to my Linux server. I've got the SMB parts working right but am having some troubles with TAR. When I enter this command: tar -cvzf /backup/win.tar /root/peon/ everything works fine. However, there's a few large folders that I do not want to backup (Linux ISOs for instance). So, I'm trying to tell tar to exclude those files like so: tar -cvzf /backup/win.tar /root/peon/ --exclude-from /root/cron/bkup_cfg/win_exclude and my win_exclude file contains: '*/Internet/*' The problem is that the moment I include the exclude-from option, tar refuses to run. I don't get any errors though. So, suspect my usage of the exclude-from option is wrong (though this seems fine based on what the man pages tell me, and what info I could find online), or the contents of my win_exclude file is wrong. I read the details at http://www.gnu.org/software/tar/manual/html_mono/tar.html#SEC90, and the section below that one, and it seems I'm trying to do things right. Can any tar guru's shed some light on this? In particular, I want to grab everything on the share point, but ignore certain folders. Thanks. Shawn _______________________________________________ clug-talk mailing list [EMAIL PROTECTED] http://clug.ca/mailman/listinfo/clug-talk_clug.ca _______________________________________________ clug-talk mailing list [EMAIL PROTECTED] http://clug.ca/mailman/listinfo/clug-talk_clug.ca

