|
#1
| |||
| |||
|
Hi, I'm using pax to backup some files but I get an error I run this short bash script Code: ./BackupSomething.bash "/Users/iainb/Library/Mail/" "Mail" Code: #! /bin/bash set -u set -e #script to back things up #pass in the file to be backed up as the 1st parameter #and the name of the backup dir as the 2nd parameter INFILE=$1 OUTDIR=/Volumes/LaCie\ Disk/backups/$(date +%Y)/$(date +%B)/$(date +%d\ %b\ %Y) OUTFILE=$2 OUTPATH=$(date +%d\ %b\ %Y)\ $OUTFILE\ Backup.tar.gz echo infile $INFILE echo outdir "$OUTDIR" echo outdir and outpath "$OUTDIR/$OUTPATH" mkdir -pv "$OUTDIR" pax -wzf "$OUTDIR/$OUTPATH" "$INFILE" pax: File name too long for ustar /Users/iainb/Library/Mail/Bundles/MailTags.mailbundle/Contents/Resources/MailTagsHeaderCellIcon.tiff The pax man pages say that ustar (the default format) handles paths up tp 250 chars long, but the path in the error is 100 chars long. I'm quite new to bash and I don't see how I can control the length of the path, or why this error is occurring? Any help or input is much appreciated. |
|
#2
| |||
| |||
|
I have not used pax, so I do not know its limits. You might like to try either tar or cpio (cpio is the backup system Unix systems normally use; with addition to dumps etc.) I noticed you use Lacie for your backup device. I have also Lacie for backups. However, I use rdiff-backup. With it I can take incremental backups, but the result is copy of the source hierarchy (the increments are stored on some different place). Also, it has support to Mac file attributes. |
|
#3
| |||
| |||
|
Thanks, I will give it a look. Sorry I didn't reply earlier, my access to internet has been severely limited since I moved into a new place, and I got the shakes and sweats - I'm an addict! ![]() Thanks again. |
![]() |
| Bookmarks |
| Thread Tools | |
|
|