Polygon.

Post

Share your knowledge.

The Web3 Diva.
Mar 16, 2025
Expert Q&A

How to download and extract .tar.zst files without saving?

Hey folks, I'm trying to figure out if there's a way to download a snapshot image as a .tar.zst file and unzip (extract) it while it's downloading. The aim is to avoid saving the .tar.zst file to my hard disk entirely. Any tips on how to achieve this?

  • Polygon PoS
0
1
Share
Comments
.

Answers

1
AFL.
AFL78
Mar 16 2025, 21:24

One approach to achieve downloading and extracting a .tar.zst file in one go is by using a command line pipeline that avoids writing the compressed file to disk. You can try this command as a starting point:

wget -c http://link.tar.zst -O - | tar -I zstd -xf - -C . --strip-components=3

This command uses wget to download the file and pipes it directly to tar, which extracts the contents without saving the compressed file first . Keep in mind, if you're dealing with multiple files from Polygon, as mentioned, you'll need to repeat this command for each file you want to download and extract .

1
Best Answer
Comments
.

Do you know the answer?

Please log in and share it.

Polygon is a decentralised Ethereum scaling platform that enables developers to build scalable user-friendly dApps with low transaction fees without ever sacrificing on security.

84Posts176Answers
We use cookies to ensure you get the best experience on our website.
More info