mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-10-06 18:12:14 +02:00
LCD restart infos
This commit is contained in:
@@ -124,17 +124,28 @@ else
|
|||||||
height=6
|
height=6
|
||||||
width=43
|
width=43
|
||||||
title="Node is Syncing (${scriptRuntime})"
|
title="Node is Syncing (${scriptRuntime})"
|
||||||
|
actionString="Please wait - this can take some time"
|
||||||
|
|
||||||
# formatting progress values
|
# formatting progress values
|
||||||
if [ ${#syncProgress} -eq 0 ]; then
|
if [ ${#syncProgress} -eq 0 ]; then
|
||||||
|
if [ ${startcountBlockchain} -eq 0 ]; then
|
||||||
syncProgress="waiting"
|
syncProgress="waiting"
|
||||||
|
else
|
||||||
|
syncProgress="${startcountBlockchain} restarts"
|
||||||
|
actionString="Please SSH in for more detail:"
|
||||||
|
fi
|
||||||
elif [ ${#syncProgress} -lt 6 ]; then
|
elif [ ${#syncProgress} -lt 6 ]; then
|
||||||
syncProgress=" ${syncProgress} %"
|
syncProgress=" ${syncProgress} %"
|
||||||
else
|
else
|
||||||
syncProgress="${syncProgress} %"
|
syncProgress="${syncProgress} %"
|
||||||
fi
|
fi
|
||||||
if [ ${#scanProgress} -eq 0 ]; then
|
if [ ${#scanProgress} -eq 0 ]; then
|
||||||
|
if [ ${startcountLightning} -eq 0 ]; then
|
||||||
scanProgress="waiting"
|
scanProgress="waiting"
|
||||||
|
else
|
||||||
|
scanProgress="${startcountLightning} restarts"
|
||||||
|
actionString="Please SSH in for more detail:"
|
||||||
|
fi
|
||||||
elif [ ${#scanProgress} -lt 6 ]; then
|
elif [ ${#scanProgress} -lt 6 ]; then
|
||||||
scanProgress=" ${scanProgress} %"
|
scanProgress=" ${scanProgress} %"
|
||||||
else
|
else
|
||||||
@@ -142,7 +153,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# setting info string
|
# setting info string
|
||||||
infoStr=" Blockchain Progress : ${syncProgress}\n Lightning Progress : ${scanProgress}\n Please wait - this can take some time"
|
infoStr=" Blockchain Progress : ${syncProgress}\n Lightning Progress : ${scanProgress}\n ${actionString}"
|
||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
@@ -29,13 +29,9 @@ uptime=$(awk '{printf("%d\n",$1 + 0.5)}' /proc/uptime)
|
|||||||
echo "uptime=${uptime}"
|
echo "uptime=${uptime}"
|
||||||
|
|
||||||
# count restarts of bitcoind/litecoind
|
# count restarts of bitcoind/litecoind
|
||||||
startcountBlockchain=$(cat systemd.blockchain.log | grep -c "STARTED")
|
startcountBlockchain=$(cat systemd.blockchain.log 2>/dev/null | grep -c "STARTED")
|
||||||
echo "startcountBlockchain=${startcountBlockchain}"
|
echo "startcountBlockchain=${startcountBlockchain}"
|
||||||
|
|
||||||
# count restarts of bitcoind/litecoind
|
|
||||||
startcountLightning=$(cat systemd.lightning.log | grep -c "STARTED")
|
|
||||||
echo "startcountLightning=${startcountLightning}"
|
|
||||||
|
|
||||||
# is bitcoind running
|
# is bitcoind running
|
||||||
bitcoinRunning=$(systemctl status ${network}d.service 2>/dev/null | grep -c running)
|
bitcoinRunning=$(systemctl status ${network}d.service 2>/dev/null | grep -c running)
|
||||||
echo "bitcoinActive=${bitcoinRunning}"
|
echo "bitcoinActive=${bitcoinRunning}"
|
||||||
@@ -111,11 +107,12 @@ else
|
|||||||
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# count restarts of bitcoind/litecoind
|
||||||
|
startcountLightning=$(cat systemd.lightning.log 2>/dev/null | grep -c "STARTED")
|
||||||
|
echo "startcountLightning=${startcountLightning}"
|
||||||
|
|
||||||
# is LND running
|
# is LND running
|
||||||
lndRunning=$(systemctl status lnd.service 2>/dev/null | grep -c running)
|
lndRunning=$(systemctl status lnd.service 2>/dev/null | grep -c running)
|
||||||
|
|
||||||
# TODO: check how long running ... try to find out if problem on starting
|
|
||||||
|
|
||||||
echo "lndActive=${lndRunning}"
|
echo "lndActive=${lndRunning}"
|
||||||
|
|
||||||
if [ ${lndRunning} -eq 1 ]; then
|
if [ ${lndRunning} -eq 1 ]; then
|
||||||
|
Reference in New Issue
Block a user