mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-08-02 15:37:49 +00:00
netmount: add loop until network is up, use 'mount' instead 'mount.cifs' to avoid problems with readonly '/etc/mtab' (mtab locking)
Signed-off-by: Stephan Raue <stephan@openelec.tv>
This commit is contained in:
parent
45843816fa
commit
70677c91fa
@ -46,19 +46,19 @@ IFS="
|
||||
mkdir -p $MOUNTPOINT
|
||||
|
||||
case "$SERVICE" in
|
||||
cifs)
|
||||
mount.cifs "$SHARE" "$MOUNTPOINT" -o "$OPTIONS"
|
||||
;;
|
||||
samba)
|
||||
mount.cifs "$SHARE" "$MOUNTPOINT" -o "$OPTIONS"
|
||||
;;
|
||||
smb)
|
||||
mount.cifs "$SHARE" "$MOUNTPOINT" -o "$OPTIONS"
|
||||
cifs|smb|samba)
|
||||
for i in 1 2 3 4 5 6 7 8 9 10; do
|
||||
ERR_ENV=1
|
||||
mount -n -t cifs "$SHARE" "$MOUNTPOINT" -o "$OPTIONS" > /dev/null 2>&1
|
||||
[ $? -eq 0 ] && ERR_ENV=0 && break
|
||||
usleep 750000
|
||||
done
|
||||
;;
|
||||
# nfs)
|
||||
# mount.nfs $SHARE $MOUNTPOINT -o $OPTIONS
|
||||
# ;;
|
||||
esac
|
||||
[ "$ERR_ENV" -ne 0 ] && echo "... could not mount $SHARE to $MOUNTPOINT"
|
||||
done
|
||||
fi
|
||||
fi
|
||||
|
Loading…
x
Reference in New Issue
Block a user