Jump to content
Forums in Read-Only Mode - Please use Reddit ×

Taking a system backup as a tar archive.


Recommended Posts

you can use that of course is as the Stage 3 is compress don't have any problem 

 

but you can use a personal script, I use that 

 

more faster but more size on disk : 

tar -cvpf /stage4.tar.xz --directory=/ --exclude=/stage4.tar.xz --exclude=/dev/* --exclude=/lost+found --exclude=/mnt/* --exclude=/proc/* --exclude=/run/* --exclude=/sys/* --exclude=/tmp/* --exclude=/var/log/* --exclude=/var/run/* --exclude=/var/tmp/* /

or that more slow(very slow) but less than half of the other option :

tar -cpvf - --directory=/ --exclude=/stage4.tar.xz --exclude=/dev/* --exclude=/lost+found --exclude=/mnt/* --exclude=/proc/* --exclude=/run/* --exclude=/sys/* --exclude=/tmp/* --exclude=/var/log/* --exclude=/var/run/* --exclude=/var/tmp/* . | xz -9e -c - > /stage4.tar.xz

of course you can change the exclude folders and files as you wish.

Link to comment
Share on other sites

×
×
  • Create New...