I facing an error in the node running. i use a script which is pinned in discord but still issue is not resolved.
use this script- rpc call fail. try to use the script to auto restart when node stop
sudo apt install nano
sudo apt install screen
rm -rf /root/.avail/data
screen -S node
sudo systemctl stop avail
sudo nano availscript.sh
Copy script and paste into it
#!/bin/bash
# official script command of Avail scrtip from daningyn
COMMAND="curl -sL1 avail.sh | bash"
# Here is script making LC restart if getting errors
while true; do
echo "Starting command: $COMMAND"
# Chạy lệnh trong background
bash -c "$COMMAND" &
PID=$!
wait $PID
EXIT_STATUS=$?
if [ $EXIT_STATUS -eq 0 ]; then
echo "Command exited successfully. Restarting..."
else
echo "Command failed with status $EXIT_STATUS. Restarting..."
fi
#
sleep 10
done
ctrl+x, y enter to save and run
bash availscript.sh
press three key CTRL+a+d together to save the screen