diff --git a/files/initrd/opt/rr/boot.sh b/files/initrd/opt/rr/boot.sh index ab41546a..e2dc4fcf 100755 --- a/files/initrd/opt/rr/boot.sh +++ b/files/initrd/opt/rr/boot.sh @@ -441,10 +441,10 @@ else echo "${IP}" | grep -q "^169\.254\." && IP="" [ -n "${IP}" ] && URL="http://${IP}:5000" || URL="http://find.synology.com/" python3 "${WORK_PATH}/include/functions.py" "makeqr" -d "${URL}" -l "6" -o "${TMP_PATH}/qrcode_boot.png" - [ -f "${TMP_PATH}/qrcode_boot.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_boot.png" >/dev/null 2>/dev/null || true + [ -f "${TMP_PATH}/qrcode_boot.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_boot.png" >/dev/null 2>&1 || true python3 "${WORK_PATH}/include/functions.py" "makeqr" -f "${WORK_PATH}/include/qhxg.png" -l "7" -o "${TMP_PATH}/qrcode_qhxg.png" - [ -f "${TMP_PATH}/qrcode_qhxg.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_qhxg.png" >/dev/null 2>/dev/null || true + [ -f "${TMP_PATH}/qrcode_qhxg.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_qhxg.png" >/dev/null 2>&1 || true fi # Executes DSM kernel via KEXEC diff --git a/files/initrd/opt/rr/init.sh b/files/initrd/opt/rr/init.sh index 5f68d4d4..1e9a76a2 100755 --- a/files/initrd/opt/rr/init.sh +++ b/files/initrd/opt/rr/init.sh @@ -12,10 +12,13 @@ set -e . "${WORK_PATH}/include/functions.sh" . "${WORK_PATH}/include/addons.sh" -if type -p vmware-toolbox-cmd; then - if [ ! "Enabled" = "$(vmware-toolbox-cmd timesync status 2>/dev/null)" ]; then +if type vmware-toolbox-cmd >/dev/null 2>&1; then + if [ "Disable" = "$(vmware-toolbox-cmd timesync status 2>/dev/null)" ]; then vmware-toolbox-cmd timesync enable >/dev/null 2>&1 || true fi + if [ "Enabled" = "$(vmware-toolbox-cmd timesync status 2>/dev/null)" ]; then + vmware-toolbox-cmd timesync disable >/dev/null 2>&1 || true + fi fi [ -z "${LOADER_DISK}" ] && die "$(TEXT "Loader is not init!")" @@ -251,10 +254,10 @@ if [ "${DSMLOGO}" = "true" ] && [ -c "/dev/fb0" ] && [ ! "LOCALBUILD" = "${LOADE echo "${IP}" | grep -q "^169\.254\." && IP="" [ -n "${IP}" ] && URL="http://${IP}:${TTYD:-7681}" || URL="http://rr:${TTYD:-7681}" python3 "${WORK_PATH}/include/functions.py" makeqr -d "${URL}" -l "0" -o "${TMP_PATH}/qrcode_init.png" - [ -f "${TMP_PATH}/qrcode_init.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_init.png" >/dev/null 2>/dev/null || true + [ -f "${TMP_PATH}/qrcode_init.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_init.png" >/dev/null 2>&1 || true python3 "${WORK_PATH}/include/functions.py" makeqr -f "${WORK_PATH}/include/qhxg.png" -l "7" -o "${TMP_PATH}/qrcode_qhxg.png" - [ -f "${TMP_PATH}/qrcode_qhxg.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_qhxg.png" >/dev/null 2>/dev/null || true + [ -f "${TMP_PATH}/qrcode_qhxg.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode_qhxg.png" >/dev/null 2>&1 || true fi # Check memory