mirror of
https://github.com/rootzoll/raspiblitz.git
synced 2024-11-20 10:12:06 +01:00
fixed detect HDD size
This commit is contained in:
parent
db77299b0c
commit
4ccdd8bb22
@ -1,5 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
|
||||
echo ""
|
||||
echo "*** Checking if HDD is connected ***"
|
||||
sleep 5
|
||||
@ -40,7 +43,6 @@ if [ ${existsHDD} -eq 1 ]; then
|
||||
minSize=31000000000
|
||||
fi
|
||||
isSize=$(lsblk -o NAME,SIZE -b | grep "${device}" | awk '$1=$1' | cut -d " " -f 2)
|
||||
echo "isSize(${num1Kblocks})"
|
||||
if [ ${isSize} -lt ${minSize} ]; then
|
||||
if [ ${isSize} -gt 1 ]; then
|
||||
echo "!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
echo ""
|
||||
echo "*** Check 1st HDD ***"
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
# get local ip
|
||||
localip=$(ip addr | grep 'state UP' -A2 | tail -n1 | awk '{print $2}' | cut -f1 -d'/')
|
||||
|
@ -1,6 +1,9 @@
|
||||
#!/bin/bash
|
||||
echo ""
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
# *** BITCOIN (just mainnet) ***
|
||||
bitcoinList="" # url to list with other sources
|
||||
#bitcoinUrl="ftp://anonymous:anonymous@91.83.237.185:21/raspiblitz-bitcoin-2018-07-16"
|
||||
@ -15,9 +18,6 @@ litecoinSize=22220000 # 22221160-tolerance
|
||||
# NOTE TO GET THE SIZE RIGHT: for new download add 9999999999 as size. Run download.
|
||||
# When finished the warning comes up and behind WARNING: copy that number
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
|
||||
# settings based on network
|
||||
list=$bitcoinList
|
||||
url=$bitcoinUrl
|
||||
|
@ -1,7 +1,7 @@
|
||||
#!/bin/bash
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
# only show warning when bitcoin
|
||||
if [ "$network" = "bitcoin" ]; then
|
||||
|
@ -5,7 +5,7 @@ echo ""
|
||||
# why there are two torrent files
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
# make sure rtorrent is available
|
||||
sudo apt-get install rtorrent -y
|
||||
|
@ -2,7 +2,7 @@
|
||||
echo ""
|
||||
|
||||
## get basic info
|
||||
source /home/admin/raspiblitz.info 2>/dev/null
|
||||
source /home/admin/raspiblitz.info
|
||||
|
||||
echo "*** Checking HDD ***"
|
||||
mountOK=$(df | grep -c /mnt/hdd)
|
||||
|
Loading…
Reference in New Issue
Block a user