File tree Expand file tree Collapse file tree 1 file changed +31
-0
lines changed
lib/sui/lib/assets/user-data Expand file tree Collapse file tree 1 file changed +31
-0
lines changed Original file line number Diff line number Diff line change
1
+ #! /bin/bash
2
+
3
+ set -e # Exit immediately if a command exits with a non-zero status
4
+
5
+ sudo apt-get install -y libpq-dev
6
+
7
+ # Stop fullnode
8
+ sudo systemctl stop suid || true # Continue even if suid is not running
9
+
10
+ # Create a sui-tool folder and switch to it
11
+ mkdir -p ~ /sui-tool
12
+ cd ~ /sui-tool
13
+
14
+ # Downloading sui-tool
15
+ wget https://github.com/MystenLabs/sui/releases/download/mainnet-v1.27.4/sui-mainnet-v1.27.4-ubuntu-x86_64.tgz
16
+ tar -xvzf sui-mainnet-v1.27.4-ubuntu-x86_64.tgz
17
+ sudo mv ./sui-tool /usr/local/bin/
18
+
19
+ # Run sui tool to download the latest epoch
20
+ sui-tool download-db-snapshot --latest --network testnet --path /home/ubuntu/.sui/db --num-parallel-downloads 50 --skip-indexes --no-sign-request
21
+
22
+ # Verify the download completion
23
+ if [ $? -eq 0 ]; then
24
+ echo " Download completed successfully."
25
+ else
26
+ echo " Download failed." >&2
27
+ exit 1
28
+ fi
29
+
30
+ # Start fullnode
31
+ sudo systemctl start suid
You can’t perform that action at this time.
0 commit comments