how to compress my 2TB of space into multiple tar.gz files?

Status
Not open for further replies.

Storms

Dabbler
Joined
Jun 12, 2012
Messages
27
Hi,

I am a home user. I have approx 2TB of used storage in my NAS (and 2Tb of free space). I want to back it up. My plan was to tar the data into multiple tar files of 50GB capacity using the multivolume feature of tar as explained here http://www.thewebhelp.com/linux/creating-multivolume-tar-files/

Unfortunately tar does not seem to work with the -ML options using the freeNas command line

Does anyone know how I can get this to work?

PS if you're wondering why I'm trying the compress to 50GB chunks; the reason is that I want to backup the full 2TB on to various other devices.... (e.g 150GB on my wifes laptop, 50GB on my other PC, etc, etc) and i dont want to fork out on more harddrives!. Then when I've rebuilt my NAS i'll bring it all back down the line again.

Thanks

Storms
 

Storms

Dabbler
Joined
Jun 12, 2012
Messages
27
i'll reply to my own message. Do this instead

tar a folder
then split the tar file (split -b 102400m file.tar.gz file.tar.gz.part-)
 

fracai

Guru
Joined
Aug 22, 2012
Messages
1,212
If you're low on space and want to avoid the intermediary tar file, you can pipe tare directly to split:

Code:
tar -czf - /input/directory | split -b 102400m - /output/file.tar.gz.part-
 
Status
Not open for further replies.
Top