How to use multi-core CPU to acclerate the tar
1 |
|
for each dir create a tar file
1 |
|
Ref: https://stackoverflow.com/questions/15936003/for-each-dir-create-a-tar-file
78
The script that you wrote will not work if you have some spaces in a directory name, because the name will be split, and also it will tar files if they exist on this level.
You can use this command to list directories not recursively:
1 |
|
and this one to perform a tar on each one:
1 |
|
Progress bar
- Extract
Ref: https://stackoverflow.com/questions/19372373/how-to-add-progress-bar-to-a-somearchive-tar-xz-extract
Firstly, you’ll need to install pv, which on macOS can be done with:
1 |
|
On Debian or Ubuntu, it can be done with: apt install pv
.
Pipe the compressed file with pv to the tar command:
1 |
|
- Compress
https://superuser.com/questions/168749/is-there-a-way-to-see-any-tar-progress-per-file
1 |
|
For OSX (from Kenji’s answer)
1 |
|
Explanation:
1 |
|
pipe to
1 |
|