mirror of
https://github.com/raspiblitz/raspiblitz.git
synced 2025-09-26 11:37:19 +02:00
dataConfigFound
This commit is contained in:
@@ -69,7 +69,7 @@ if [ "$1" = "status" ]; then
|
|||||||
dataDevice=""
|
dataDevice=""
|
||||||
storageBlockchainGB=0
|
storageBlockchainGB=0
|
||||||
dataInspectSuccess=0
|
dataInspectSuccess=0
|
||||||
dataInspectConfigFound=0
|
dataConfigFound=0
|
||||||
combinedDataStorage=0
|
combinedDataStorage=0
|
||||||
remainingDevices=0
|
remainingDevices=0
|
||||||
|
|
||||||
@@ -212,6 +212,12 @@ if [ "$1" = "status" ]; then
|
|||||||
echo "# - no data found on partition"
|
echo "# - no data found on partition"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Check: CONFIG FILE
|
||||||
|
if [ -f "${mountPath}/raspiblitz.conf" ] || [ -f "${mountPath}/app-data/raspiblitz.conf" ]; then
|
||||||
|
dataConfigFound=1
|
||||||
|
echo "# * found raspiblitz.conf"
|
||||||
|
fi
|
||||||
|
|
||||||
# Datainspect: copy setup relevant data from partition to temp location
|
# Datainspect: copy setup relevant data from partition to temp location
|
||||||
if [ "$dataInspectPartition" = "1" ]; then
|
if [ "$dataInspectPartition" = "1" ]; then
|
||||||
if [ "$userWantsInspect" = "0" ]; then
|
if [ "$userWantsInspect" = "0" ]; then
|
||||||
@@ -228,7 +234,6 @@ if [ "$1" = "status" ]; then
|
|||||||
cp -a ${mountPath}/raspiblitz.conf /var/cache/raspiblitz/hdd-inspect/raspiblitz.conf 2>/dev/null
|
cp -a ${mountPath}/raspiblitz.conf /var/cache/raspiblitz/hdd-inspect/raspiblitz.conf 2>/dev/null
|
||||||
cp -a ${mountPath}/app-data/raspiblitz.conf /var/cache/raspiblitz/hdd-inspect/raspiblitz.conf 2>/dev/null
|
cp -a ${mountPath}/app-data/raspiblitz.conf /var/cache/raspiblitz/hdd-inspect/raspiblitz.conf 2>/dev/null
|
||||||
if [ -f "/var/cache/raspiblitz/hdd-inspect/raspiblitz.conf" ]; then
|
if [ -f "/var/cache/raspiblitz/hdd-inspect/raspiblitz.conf" ]; then
|
||||||
dataInspectConfigFound=1
|
|
||||||
echo "# * raspiblitz.conf copied to RAMDISK"
|
echo "# * raspiblitz.conf copied to RAMDISK"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -431,11 +436,11 @@ if [ "$1" = "status" ]; then
|
|||||||
scenario="ready"
|
scenario="ready"
|
||||||
|
|
||||||
# recover: drives there but unmounted & blitz config exists (check raspiblitz.conf with -inspect if its update)
|
# recover: drives there but unmounted & blitz config exists (check raspiblitz.conf with -inspect if its update)
|
||||||
elif [ ${#storageDevice} -gt 0 ] && [ ${#storageMountedPath} -eq 0 ] && [ ${dataInspectConfigFound} -eq 1 ]; then
|
elif [ ${#storageDevice} -gt 0 ] && [ ${#storageMountedPath} -eq 0 ] && [ ${dataConfigFound} -eq 1 ]; then
|
||||||
scenario="recover"
|
scenario="recover"
|
||||||
|
|
||||||
# setup: drives there but unmounted & no blitz config exists
|
# setup: drives there but unmounted & no blitz config exists
|
||||||
elif [ ${#storageDevice} -gt 0 ] && [ ${#storageMountedPath} -eq 0 ] && [ ${dataInspectConfigFound} -eq 0 ]; then
|
elif [ ${#storageDevice} -gt 0 ] && [ ${#storageMountedPath} -eq 0 ] && [ ${dataConfigFound} -eq 0 ]; then
|
||||||
scenario="setup"
|
scenario="setup"
|
||||||
|
|
||||||
# UNKNOWN SCENARIO
|
# UNKNOWN SCENARIO
|
||||||
@@ -466,8 +471,8 @@ if [ "$1" = "status" ]; then
|
|||||||
echo "dataWarning='${dataWarning}'"
|
echo "dataWarning='${dataWarning}'"
|
||||||
echo "dataPartition='${dataPartition}'"
|
echo "dataPartition='${dataPartition}'"
|
||||||
echo "dataMountedPath='${dataMountedPath}'"
|
echo "dataMountedPath='${dataMountedPath}'"
|
||||||
|
echo "dataConfigFound='${dataConfigFound}'"
|
||||||
echo "dataInspectSuccess='${dataInspectSuccess}'"
|
echo "dataInspectSuccess='${dataInspectSuccess}'"
|
||||||
echo "dataInspectConfigFound='${dataInspectConfigFound}'"
|
|
||||||
echo "combinedDataStorage='${combinedDataStorage}'"
|
echo "combinedDataStorage='${combinedDataStorage}'"
|
||||||
echo "bootFromStorage='${bootFromStorage}'"
|
echo "bootFromStorage='${bootFromStorage}'"
|
||||||
echo "bootFromSD='${bootFromSD}'"
|
echo "bootFromSD='${bootFromSD}'"
|
||||||
|
Reference in New Issue
Block a user