Backing up to an external FAT32 disk

Rashkae ubuntu at tigershaunt.com
Thu Jul 12 17:10:22 UTC 2007


Nils Kassube wrote:
> Liam Proven wrote:
>> I am trying to backup a 98% full RAID array (some 100GB of stuff) onto
>> a 400GB FAT32 USB2 external hard drive. I don't have space on the RAID
>> itself to create the archive, nor on my 3G root FS.
>>
>> I tried (in my /media directory, the mountpoint for both the RAID and
>> the USB drive):
>>
>> tar -cvf usbdrive/raid.tar raid/
>>
>> This worked but I forgot one detail. FAT32 has a max file size of
>> about 4G. So when the archive got to 4G, it barfed.
> 
> Try this:
> 
> tar c raid | split -d --suffix-length=3 --bytes=1000m - usbdrive/raid_
> 
> That will give you files of 1000MB size with filenames usbdrive/raid_<nnn> 
> with <nnn> being numbers counting from 001.
> 
> You can test the archive with:
> 
> cat usbdrive/raid_* | tar tv
> 
> And you can restore a file with:
> 
> cat usbdrive/raid_* | tar x <filename>
> 
> 
> Nils
> 

This is the right approach, but I would use a command more like:

tar -cz raid | split -b 2000m - /media/usbdrive/raid.tar.gz.

And as already mentioned, to restore:

cat /media/usbdrive/raid.tar.gz.* | tar -xz   (run this in the location 
where you want the files restored.)




More information about the ubuntu-users mailing list