Skip to content

Commit ab3a3e1

Browse files
committed
fix snapshot download args
1 parent c739cca commit ab3a3e1

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

run/snapshot/download_snapshot.sh

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
#!/bin/bash
2+
set -eu
23

34
NETWORK_ID=${1:-""}
45

@@ -10,12 +11,14 @@ if [ -z "$URLS" ]; then
1011
exit 1
1112
fi
1213

13-
echo "$URLS" | xargs -n 1 -P 8 aria2c -x 16 -s 16 -d /data
14+
echo "$URLS" | xargs -n 1 -P 2 aria2c -x 4 -s 4 -d /data --retry-wait=10 --max-tries=3
1415
echo "Download snapshot completed. Unpacking..."
1516

1617
for FILE in /data/*.tar.lz4; do
1718
echo "Extracting $FILE..."
18-
tar --lz4 -xvf "$FILE" -C /data
19+
tar -I lz4 -xvf "$FILE" -C /
1920
rm "$FILE"
2021
done
22+
mv /geth /data
23+
2124
echo "Extract snapshot completed."

0 commit comments

Comments
 (0)