From ab83c4b696a6c88f8a7b7f3db12ad1a67065c5d9 Mon Sep 17 00:00:00 2001 From: Ing Date: Sat, 28 Oct 2023 22:27:51 +0800 Subject: [PATCH] RR init 2 --- .gitignore | 1 + files/initrd/opt/rr/boot.sh | 53 +- files/initrd/opt/rr/include/addons.sh | 15 +- files/initrd/opt/rr/include/configFile.sh | 9 + files/initrd/opt/rr/include/consts.sh | 35 +- files/initrd/opt/rr/include/functions.py | 63 + files/initrd/opt/rr/include/functions.sh | 96 +- files/initrd/opt/rr/include/i18n.sh | 23 +- files/initrd/opt/rr/include/logo.png | Bin 0 -> 1271 bytes files/initrd/opt/rr/init.sh | 146 +- files/initrd/opt/rr/install-addons.sh | 15 - files/initrd/opt/rr/lang/{arpl.pot => rr.pot} | 487 ++--- files/initrd/opt/rr/lang/zh_CN.po | 613 +++--- files/initrd/opt/rr/lang/zh_HK.po | 911 ++++---- files/initrd/opt/rr/lang/zh_TW.po | 1933 ++++++++++------- files/initrd/opt/rr/menu.sh | 210 +- .../opt/rr/model-configs/FS6400.yml.disabled | 3 + .../opt/rr/model-configs/HD6500.yml.disabled | 3 + files/initrd/opt/rr/model-configs/RS2423+.yml | 3 - files/initrd/opt/rr/model-configs/SA3410.yml | 2 + files/initrd/opt/rr/model-configs/SA3610.yml | 2 + files/initrd/opt/rr/ramdisk-patch.sh | 24 +- files/initrd/opt/rr/vmlinux-to-bzImage.sh | 4 +- files/initrd/opt/rr/zimage-patch.sh | 10 +- files/p1/EFI/BOOT/SynoBootLoader.conf | 19 - files/p1/EFI/BOOT/SynoBootLoader.efi | 0 guide.md | 10 + img-gen.sh | 19 +- scripts/func.sh | 2 +- update-check.sh | 38 +- 30 files changed, 2550 insertions(+), 2199 deletions(-) create mode 100644 files/initrd/opt/rr/include/functions.py create mode 100644 files/initrd/opt/rr/include/logo.png delete mode 100755 files/initrd/opt/rr/install-addons.sh rename files/initrd/opt/rr/lang/{arpl.pot => rr.pot} (75%) delete mode 100755 files/p1/EFI/BOOT/SynoBootLoader.conf delete mode 100755 files/p1/EFI/BOOT/SynoBootLoader.efi diff --git a/.gitignore b/.gitignore index 667d0002..054e33cd 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,4 @@ cache files/initrd/opt/rr/lang/*.mo tests /extractor +/br diff --git a/files/initrd/opt/rr/boot.sh b/files/initrd/opt/rr/boot.sh index 238a63a5..7536cd79 100755 --- a/files/initrd/opt/rr/boot.sh +++ b/files/initrd/opt/rr/boot.sh @@ -1,18 +1,18 @@ #!/usr/bin/env bash set -e +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" -. /opt/rr/include/functions.sh +. ${WORK_PATH}/include/functions.sh +[ -z "${LOADER_DISK}" ] && die "$(TEXT "Loader is not init!")" # Sanity check loaderIsConfigured || die "$(TEXT "Loader is not configured!")" # Check if machine has EFI [ -d /sys/firmware/efi ] && EFI=1 || EFI=0 -LOADER_DISK="$(blkid | grep 'LABEL="RR3"' | cut -d3 -f1)" -BUS=$(udevadm info --query property --name ${LOADER_DISK} | grep ID_BUS | cut -d= -f2) -[ "${BUS}" = "ata" ] && BUS="sata" +BUS=$(getBus "${LOADER_DISK}") # Print text centralized clear @@ -23,20 +23,15 @@ printf "\033[1;44m%*s\033[A\n" ${COLUMNS} "" printf "\033[1;32m%*s\033[0m\n" $(((${#TITLE} + ${COLUMNS}) / 2)) "${TITLE}" printf "\033[1;44m%*s\033[0m\n" ${COLUMNS} "" TITLE="BOOTING:" -[ -d "/sys/firmware/efi" ] && TITLE+=" [UEFI]" || TITLE+=" [BIOS]" +[ ${EFI} -eq 1 ] && TITLE+=" [UEFI]" || TITLE+=" [BIOS]" [ "${BUS}" = "usb" ] && TITLE+=" [${BUS^^} flashdisk]" || TITLE+=" [${BUS^^} DoM]" printf "\033[1;33m%*s\033[0m\n" $(((${#TITLE} + ${COLUMNS}) / 2)) "${TITLE}" -DSMLOGO="$(readConfigKey "dsmlogo" "${USER_CONFIG_FILE}")" -if [ "${DSMLOGO}" = "true" -a -c "/dev/fb0" -a -f "${CACHE_PATH}/logo.png" ]; then - echo | fbv -acuf "${CACHE_PATH}/logo.png" >/dev/null 2>/dev/null || true -fi - # Check if DSM zImage changed, patch it if necessary ZIMAGE_HASH="$(readConfigKey "zimage-hash" "${USER_CONFIG_FILE}")" -if [ "$(sha256sum "${ORI_ZIMAGE_FILE}" | awk '{print$1}')" != "${ZIMAGE_HASH}" ]; then +if [ -f ${PART1_PATH}/.build -o "$(sha256sum "${ORI_ZIMAGE_FILE}" | awk '{print$1}')" != "${ZIMAGE_HASH}" ]; then echo -e "\033[1;43m$(TEXT "DSM zImage changed")\033[0m" - /opt/rr/zimage-patch.sh + ${WORK_PATH}/zimage-patch.sh if [ $? -ne 0 ]; then dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Error")" \ --msgbox "$(TEXT "zImage not patched,\nPlease upgrade the bootloader version and try again.\nPatch error:\n")$(<"${LOG_FILE}")" 12 70 @@ -47,9 +42,9 @@ fi # Check if DSM ramdisk changed, patch it if necessary RAMDISK_HASH="$(readConfigKey "ramdisk-hash" "${USER_CONFIG_FILE}")" RAMDISK_HASH_CUR="$(sha256sum "${ORI_RDGZ_FILE}" | awk '{print $1}')" -if [ "${RAMDISK_HASH_CUR}" != "${RAMDISK_HASH}" ]; then +if [ -f ${PART1_PATH}/.build -o "${RAMDISK_HASH_CUR}" != "${RAMDISK_HASH}" ]; then echo -e "\033[1;43m$(TEXT "DSM Ramdisk changed")\033[0m" - /opt/rr/ramdisk-patch.sh + ${WORK_PATH}/ramdisk-patch.sh if [ $? -ne 0 ]; then dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Error")" \ --msgbox "$(TEXT "Ramdisk not patched,\nPlease upgrade the bootloader version and try again.\nPatch error:\n")$(<"${LOG_FILE}")" 12 70 @@ -58,6 +53,7 @@ if [ "${RAMDISK_HASH_CUR}" != "${RAMDISK_HASH}" ]; then # Update SHA256 hash writeConfigKey "ramdisk-hash" "${RAMDISK_HASH_CUR}" "${USER_CONFIG_FILE}" fi +[ -f ${PART1_PATH}/.build ] && rm -f ${PART1_PATH}/.build # Load necessary variables MODEL="$(readConfigKey "model" "${USER_CONFIG_FILE}")" @@ -77,20 +73,20 @@ echo -e "$(TEXT "DMI: ") \033[1;36m${DMI}\033[0m" echo -e "$(TEXT "CPU: ") \033[1;36m${CPU}\033[0m" echo -e "$(TEXT "MEM: ") \033[1;36m${MEM}\033[0m" -if [ ! -f "${MODEL_CONFIG_PATH}/${MODEL}.yml" ] || [ -z "$(readConfigKey "productvers.[${PRODUCTVER}]" "${MODEL_CONFIG_PATH}/${MODEL}.yml")" ]; then +if [ ! -f "${WORK_PATH}/model-configs/${MODEL}.yml" ] || [ -z "$(readModelKey ${MODEL} "productvers.[${PRODUCTVER}]")" ]; then echo -e "\033[1;33m*** $(printf "$(TEXT "The current version of bootloader does not support booting %s-%s, please upgrade and rebuild.")" "${MODEL}" "${PRODUCTVER}") ***\033[0m" exit 1 fi HASATA=0 -for D in $(lsblk -dnp -o name); do +for D in $(lsblk -dpno NAME); do [ "${D}" = "${LOADER_DISK}" ] && continue - if [ "$(udevadm info --query property --name ${D} | grep ID_BUS | cut -d= -f2)" = "ata" ]; then + if [ "$(getBus "${D}")" = "sata" -o "$(getBus "${D}")" = "scsi" ]; then HASATA=1 break fi done -[ ${HASATA} = "0" ] && echo -e "\033[1;33m*** $(TEXT "Please insert at least one sata disk for system installation, except for the bootloader disk.") ***\033[0m" +[ ${HASATA} = "0" ] && echo -e "\033[1;33m*** $(TEXT "Please insert at least one sata/scsi disk for system installation, except for the bootloader disk.") ***\033[0m" VID="$(readConfigKey "vid" "${USER_CONFIG_FILE}")" PID="$(readConfigKey "pid" "${USER_CONFIG_FILE}")" @@ -98,6 +94,8 @@ SN="$(readConfigKey "sn" "${USER_CONFIG_FILE}")" MAC1="$(readConfigKey "mac1" "${USER_CONFIG_FILE}")" KERNELPANIC="$(readConfigKey "kernelpanic" "${USER_CONFIG_FILE}")" +NETIFNUM=$(ls /sys/class/net/ | grep eth | wc -l); [ ${NETIFNUM} -eq 0 ] && NETIFNUM=1 + declare -A CMDLINE # Automatic values @@ -108,7 +106,7 @@ CMDLINE['vid']="${VID}" CMDLINE['pid']="${PID}" CMDLINE['sn']="${SN}" CMDLINE['mac1']="${MAC1}" -CMDLINE['netif_num']="1" +CMDLINE['netif_num']="${NETIFNUM}" # set fixed cmdline if grep -q "force_junior" /proc/cmdline; then @@ -120,8 +118,7 @@ else CMDLINE['noefi']="" fi if [ ! "${BUS}" = "usb" ]; then - LOADER_DEVICE_NAME=$(echo ${LOADER_DISK} | sed 's|/dev/||') - SIZE=$(($(cat /sys/block/${LOADER_DEVICE_NAME}/size) / 2048 + 10)) + SIZE=$(($(cat /sys/block/${LOADER_DISK/\/dev\//}/size) / 2048 + 10)) # Read SATADoM type DOM="$(readModelKey "${MODEL}" "dom")" CMDLINE['synoboot_satadom']="${DOM}" @@ -204,7 +201,7 @@ else break fi COUNT=$((${COUNT} + 1)) - IP=$(ip route show dev ${ETHX[${N}]} 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p') + IP="$(getIP ${ETHX[${N}]})" if [ -n "${IP}" ]; then echo -en "\r${ETHX[${N}]}(${DRIVER}): $(printf "$(TEXT "Access \033[1;34mhttp://%s:5000\033[0m to connect the DSM via web.")" "${IP}")\n" break @@ -234,6 +231,14 @@ else echo -e "\033[1;37m$(TEXT "Loading DSM kernel...")\033[0m" + DSMLOGO="$(readConfigKey "dsmlogo" "${USER_CONFIG_FILE}")" + if [ "${DSMLOGO}" = "true" -a -c "/dev/fb0" ]; then + IP="$(getIP)" + [ -n "${IP}" ] && URL="http://${IP}:5000" || URL="http://find.synology.com/" + python ${WORK_PATH}/include/functions.py makeqr -d "${URL}" -l "br" -o "${TMP_PATH}/qrcode.png" + [ -f "${TMP_PATH}/qrcode.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode.png" >/dev/null 2>/dev/null || true + fi + # Executes DSM kernel via KEXEC KVER=$(readModelKey "${MODEL}" "productvers.[${PRODUCTVER}].kver") if [ "${KVER:0:1}" = "3" -a ${EFI} -eq 1 ]; then @@ -244,9 +249,9 @@ else fi echo -e "\033[1;37m$(TEXT "Booting...")\033[0m" for T in $(w | grep -v "TTY" | awk -F' ' '{print $2}'); do - echo -e "\n\033[1;43m$(TEXT "[This interface will not be operational.\nPlease wait for a few minutes before using the http://find.synology.com/ or Synology Assistant find DSM and connect.]")\033[0m\n" >"/dev/${T}" 2>/dev/null || true + echo -e "\n\033[1;43m$(TEXT "[This interface will not be operational. Please wait a few minutes.\nFind DSM via http://find.synology.com/ or Synology Assistant and connect.]")\033[0m\n" >"/dev/${T}" 2>/dev/null || true done KERNELWAY="$(readConfigKey "kernelway" "${USER_CONFIG_FILE}")" [ "${KERNELWAY}" = "kexec" ] && kexec -f -e || poweroff exit 0 -fi \ No newline at end of file +fi diff --git a/files/initrd/opt/rr/include/addons.sh b/files/initrd/opt/rr/include/addons.sh index 1f0f35f2..96d839fc 100755 --- a/files/initrd/opt/rr/include/addons.sh +++ b/files/initrd/opt/rr/include/addons.sh @@ -53,7 +53,7 @@ function installAddon() { [ ${HAS_FILES} -ne 1 ] && return 1 cp -f "${TMP_PATH}/${ADDON}/install.sh" "${RAMDISK_PATH}/addons/${ADDON}.sh" 2>"${LOG_FILE}" || dieLog chmod +x "${RAMDISK_PATH}/addons/${ADDON}.sh" - [ -d ${TMP_PATH}/${ADDON}/root ] && (cp -Rf "${TMP_PATH}/${ADDON}/root/"* "${RAMDISK_PATH}/" 2>"${LOG_FILE}" || dieLog) + [ -d ${TMP_PATH}/${ADDON}/root ] && (cp -rnf "${TMP_PATH}/${ADDON}/root/"* "${RAMDISK_PATH}/" 2>"${LOG_FILE}" || dieLog) rm -rf "${TMP_PATH}/${ADDON}" return 0 } @@ -72,3 +72,16 @@ function untarAddon() { mv -f "${TMP_PATH}/addon" "${ADDONS_PATH}/${ADDON}" echo "${ADDON}" } + +############################################################################### +# Detect if has new local plugins to install/reinstall +function updateAddons() { + for F in $(ls ${PART3_PATH}/*.addon 2>/dev/null); do + ADDON=$(basename "${F}" | sed 's|.addon||') + rm -rf "${ADDONS_PATH}/${ADDON}" + mkdir -p "${ADDONS_PATH}/${ADDON}" + echo "Installing ${F} to ${ADDONS_PATH}/${ADDON}" + tar -xaf "${F}" -C "${ADDONS_PATH}/${ADDON}" + rm -f "${F}" + done +} diff --git a/files/initrd/opt/rr/include/configFile.sh b/files/initrd/opt/rr/include/configFile.sh index 9de0be5d..a549ffaf 100755 --- a/files/initrd/opt/rr/include/configFile.sh +++ b/files/initrd/opt/rr/include/configFile.sh @@ -25,6 +25,15 @@ function readConfigKey() { [ "${RESULT}" == "null" ] && echo "" || echo ${RESULT} } +############################################################################### +# Write to yaml config file if key not exists +# 1 - Path of Key +# 2 - Value +# 3 - Path of yaml config file +function initConfigKey() { + [ -z "$(readConfigKey "${1}" "${3}")" ] && writeConfigKey "${1}" "${2}" "${3}" || true +} + ############################################################################### # Read Entries as map(key=value) from yaml config file # 1 - Path of key diff --git a/files/initrd/opt/rr/include/consts.sh b/files/initrd/opt/rr/include/consts.sh index 30ea7b9b..57d96406 100755 --- a/files/initrd/opt/rr/include/consts.sh +++ b/files/initrd/opt/rr/include/consts.sh @@ -1,27 +1,30 @@ RR_VERSION="23.10.4" -RR_TITLE="rr v${RR_VERSION}" +RR_TITLE="RR v${RR_VERSION}" # Define paths + +PART1_PATH="/mnt/p1" +PART2_PATH="/mnt/p2" +PART3_PATH="/mnt/p3" +DSMROOT_PATH="/mnt/dsmroot" TMP_PATH="/tmp" + UNTAR_PAT_PATH="${TMP_PATH}/pat" RAMDISK_PATH="${TMP_PATH}/ramdisk" LOG_FILE="${TMP_PATH}/log.txt" -USER_CONFIG_FILE="${BOOTLOADER_PATH}/user-config.yml" -GRUB_PATH="${BOOTLOADER_PATH}/boot/grub" +USER_CONFIG_FILE="${PART1_PATH}/user-config.yml" +GRUB_PATH="${PART1_PATH}/boot/grub" -ORI_ZIMAGE_FILE="${SLPART_PATH}/zImage" -ORI_RDGZ_FILE="${SLPART_PATH}/rd.gz" +ORI_ZIMAGE_FILE="${PART2_PATH}/zImage" +ORI_RDGZ_FILE="${PART2_PATH}/rd.gz" -RR_BZIMAGE_FILE="${CACHE_PATH}/bzImage-rr" -RR_RAMDISK_FILE="${CACHE_PATH}/initrd-rr" -MOD_ZIMAGE_FILE="${CACHE_PATH}/zImage-dsm" -MOD_RDGZ_FILE="${CACHE_PATH}/initrd-dsm" -ADDONS_PATH="${CACHE_PATH}/addons" -LKM_PATH="${CACHE_PATH}/lkms" -MODULES_PATH="${CACHE_PATH}/modules" -USER_UP_PATH="${CACHE_PATH}/users" +RR_BZIMAGE_FILE="${PART3_PATH}/bzImage-rr" +RR_RAMDISK_FILE="${PART3_PATH}/initrd-rr" +MOD_ZIMAGE_FILE="${PART3_PATH}/zImage-dsm" +MOD_RDGZ_FILE="${PART3_PATH}/initrd-dsm" -MODEL_CONFIG_PATH="/opt/rr/model-configs" -INCLUDE_PATH="/opt/rr/include" -PATCH_PATH="/opt/rr/patch" +LKM_PATH="${PART3_PATH}/lkms" +ADDONS_PATH="${PART3_PATH}/addons" +MODULES_PATH="${PART3_PATH}/modules" +USER_UP_PATH="${PART3_PATH}/users" diff --git a/files/initrd/opt/rr/include/functions.py b/files/initrd/opt/rr/include/functions.py new file mode 100644 index 00000000..4dc91212 --- /dev/null +++ b/files/initrd/opt/rr/include/functions.py @@ -0,0 +1,63 @@ +# -*- coding: utf-8 -*- +# +# Copyright (C) 2022 Ing +# +# This is free software, licensed under the MIT License. +# See /LICENSE for more information. +# + +import os, click + +WORK_PATH = os.path.abspath(os.path.dirname(__file__)) + +@click.group() +def cli(): + """ + The CLI is a commands to arpl. + """ + pass + +@cli.command() +@click.option('-d', "--data", type=str, required=True, help="The data of QRCode.") +@click.option('-l', "--location", type=str, required=True, help="The location of QRCode. (tl, tr, bl, br, mid)") +@click.option('-o', "--output", type=str, required=True, help="The output file of QRCode.") +def makeqr(data, location, output): + """ + Generate a QRCode. + """ + import qrcode + from PIL import Image + qr = qrcode.QRCode(version=1, box_size=10, error_correction=qrcode.constants.ERROR_CORRECT_H, border=4) + qr.add_data(data) + qr.make(fit=True) + img = qr.make_image(fill_color="purple", back_color="white") + img = img.convert("RGBA") + pixels = img.load() + for i in range(img.size[0]): + for j in range(img.size[1]): + if pixels[i, j] == (255, 255, 255, 255): + pixels[i, j] = (255, 255, 255, 0) + + if os.path.exists(os.path.join(WORK_PATH, "logo.png")): + icon = Image.open(os.path.join(WORK_PATH, "logo.png")) + icon = icon.convert("RGBA") + img.paste(icon.resize((int(img.size[0] / 5), int(img.size[1] / 5))), (int((img.size[0] - int(img.size[0] / 5)) / 2), int((img.size[1] - int(img.size[1] / 5)) / 2))) + + alpha = Image.new("RGBA", (img.size[0] * 4, img.size[1] * 3), (0, 0, 0, 0)) + if location == "tl": + loc = (0, 0) + elif location == "tr": + loc = (alpha.size[0] - img.size[0], 0) + elif location == "bl": + loc = (0, alpha.size[1] - img.size[1]) + elif location == "br": + loc = (alpha.size[0] - img.size[0], alpha.size[1] - img.size[1]) + else: # elif location == "mid": + loc = (int((alpha.size[0] - img.size[0]) / 2), int((alpha.size[1] - img.size[1]) / 2)) + + alpha.paste(img, loc) + alpha.save(output) + + +if __name__ == "__main__": + cli() diff --git a/files/initrd/opt/rr/include/functions.sh b/files/initrd/opt/rr/include/functions.sh index cd022d34..c1a4ecd5 100755 --- a/files/initrd/opt/rr/include/functions.sh +++ b/files/initrd/opt/rr/include/functions.sh @@ -1,6 +1,9 @@ -. /opt/rr/include/i18n.sh -. /opt/rr/include/consts.sh -. /opt/rr/include/configFile.sh + +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")/../" >/dev/null 2>&1 && pwd)" + +. ${WORK_PATH}/include/consts.sh +. ${WORK_PATH}/include/configFile.sh +. ${WORK_PATH}/include/i18n.sh ############################################################################### # Read key value from model config file @@ -8,7 +11,7 @@ # 2 - Key # Return Value function readModelKey() { - readConfigKey "${2}" "${MODEL_CONFIG_PATH}/${1}.yml" + readConfigKey "${2}" "${WORK_PATH}/model-configs/${1}.yml" } ############################################################################### @@ -17,7 +20,7 @@ function readModelKey() { # 2 - Path of key # Returns map of values function readModelMap() { - readConfigMap "${2}" "${MODEL_CONFIG_PATH}/${1}.yml" + readConfigMap "${2}" "${WORK_PATH}/model-configs/${1}.yml" } ############################################################################### @@ -26,7 +29,7 @@ function readModelMap() { # 2 - Path of key # Returns array/map of values function readModelArray() { - readConfigArray "${2}" "${MODEL_CONFIG_PATH}/${1}.yml" + readConfigArray "${2}" "${WORK_PATH}/model-configs/${1}.yml" } ############################################################################### @@ -239,37 +242,81 @@ EOF fi ETHLIST="$(echo -e "${ETHLIST}" | grep -v '^$')" - echo -e "${ETHLIST}" > /tmp/ethlist - # cat /tmp/ethlist + echo -e "${ETHLIST}" >${TMP_PATH}/ethlist + # cat ${TMP_PATH}/ethlist # sort IDX=0 while true; do - # cat /tmp/ethlist - [ ${IDX} -ge $(wc -l < /tmp/ethlist) ] && break - ETH=$(cat /tmp/ethlist | sed -n "$((${IDX} + 1))p" | awk '{print $3}') + # cat ${TMP_PATH}/ethlist + [ ${IDX} -ge $(wc -l <${TMP_PATH}/ethlist) ] && break + ETH=$(cat ${TMP_PATH}/ethlist | sed -n "$((${IDX} + 1))p" | awk '{print $3}') # echo "ETH: ${ETH}" if [ -n "${ETH}" ] && [ ! "${ETH}" = "eth${IDX}" ]; then # echo "change ${ETH} <=> eth${IDX}" ip link set dev eth${IDX} down ip link set dev ${ETH} down sleep 1 - ip link set dev eth${IDX} name tmp + ip link set dev eth${IDX} name ethN ip link set dev ${ETH} name eth${IDX} - ip link set dev tmp name ${ETH} + ip link set dev ethN name ${ETH} sleep 1 ip link set dev eth${IDX} up ip link set dev ${ETH} up sleep 1 - sed -i "s/eth${IDX}/tmp/" /tmp/ethlist - sed -i "s/${ETH}/eth${IDX}/" /tmp/ethlist - sed -i "s/tmp/${ETH}/" /tmp/ethlist + sed -i "s/eth${IDX}/ethN/" ${TMP_PATH}/ethlist + sed -i "s/${ETH}/eth${IDX}/" ${TMP_PATH}/ethlist + sed -i "s/ethN/${ETH}/" ${TMP_PATH}/ethlist sleep 1 fi IDX=$((${IDX} + 1)) done - rm -f /tmp/ethlist + rm -f ${TMP_PATH}/ethlist +} + +############################################################################### +# get bus of disk +# 1 - device path +function getBus() { + BUS="" + # usb/ata(sata/ide)/scsi + [ -z "${BUS}" ] && BUS=$(udevadm info --query property --name "${1}" 2>/dev/null | grep ID_BUS | cut -d= -f2 | sed 's/ata/sata/') + # usb/sata(sata/ide)/nvme + [ -z "${BUS}" ] && BUS=$(lsblk -dpno KNAME,TRAN 2>/dev/null | grep "${1}" | awk '{print $2}') + # usb/scsi(sata/ide)/virtio(scsi/virtio)/nvme + [ -z "${BUS}" ] && BUS=$(lsblk -dpno KNAME,SUBSYSTEMS 2>/dev/null | grep "${1}" | awk -F':' '{print $(NF-1)}') + echo "${BUS}" +} + +############################################################################### +# get IP +# 1 - ethN +function getIP() { + IP="" + if [ -n "${1}" -a -d "/sys/class/net/${1}" ]; then + IP=$(ip route show dev ${1} 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p') + [ -z "${IP}" ] && IP=$(ip addr show ${1} | grep -E "inet .* eth" | awk '{print $2}' | cut -f1 -d'/' | head -1) + else + IP=$(ip route show 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p' | head -1) + [ -z "${IP}" ] && IP=$(ip addr show | grep -E "inet .* eth" | awk '{print $2}' | cut -f1 -d'/' | head -1) + fi + echo "${IP}" +} + +############################################################################### +# get logo of model +# 1 - model +function getLogo() { + MODEL="${1}" + rm -f "${PART3_PATH}/logo.png" + fastest=$(_get_fastest "www.synology.com" "www.synology.cn") + STATUS=$(curl -skL -w "%{http_code}" "https://${fastest}/api/products/getPhoto?product=${MODEL/+/%2B}&type=img_s&sort=0" -o "${PART3_PATH}/logo.png") + if [ $? -ne 0 -o ${STATUS} -ne 200 -o -f "${PART3_PATH}/logo.png" ]; then + convert -rotate 180 "${PART3_PATH}/logo.png" "${PART3_PATH}/logo.png" 2>/dev/null + magick montage "${PART3_PATH}/logo.png" -background 'none' -tile '3x3' -geometry '350x210' "${PART3_PATH}/logo.png" 2>/dev/null + convert -rotate 180 "${PART3_PATH}/logo.png" "${PART3_PATH}/logo.png" 2>/dev/null + fi } ############################################################################### @@ -277,7 +324,7 @@ EOF # (based on pocopico's TCRP code) function findAndMountDSMRoot() { [ $(mount | grep -i "${DSMROOT_PATH}" | wc -l) -gt 0 ] && return 0 - dsmrootdisk="$(blkid /dev/sd* | grep -i raid | awk '{print $1 " " $4}' | grep UUID | grep sd[a-z]1 | head -1 | awk -F ":" '{print $1}')" + dsmrootdisk="$(blkid | grep -i linux_raid_member | grep /dev/.*1: | head -1)" [ -z "${dsmrootdisk}" ] && return -1 [ $(mount | grep -i "${DSMROOT_PATH}" | wc -l) -eq 0 ] && mount -t ext4 "${dsmrootdisk}" "${DSMROOT_PATH}" if [ $(mount | grep -i "${DSMROOT_PATH}" | wc -l) -eq 0 ]; then @@ -286,3 +333,16 @@ function findAndMountDSMRoot() { fi return 0 } + +############################################################################### +# Rebooting +# (based on pocopico's TCRP code) +function rebootTo() { + [ "${1}" != "junior" -a "${1}" != "config" ] && exit 1 + # echo "Rebooting to ${1} mode" + GRUBPATH="$(dirname $(find ${PART1_PATH}/ -name grub.cfg | head -1))" + ENVFILE="${GRUBPATH}/grubenv" + [ ! -f "${ENVFILE}" ] && grub-editenv ${ENVFILE} create + grub-editenv ${ENVFILE} set next_entry="${1}" + reboot +} diff --git a/files/initrd/opt/rr/include/i18n.sh b/files/initrd/opt/rr/include/i18n.sh index bee4eb72..03b69fc5 100755 --- a/files/initrd/opt/rr/include/i18n.sh +++ b/files/initrd/opt/rr/include/i18n.sh @@ -1,6 +1,19 @@ -if [ -f ${BOOTLOADER_PATH}/.locale ]; then - export LANG="$(cat ${BOOTLOADER_PATH}/.locale)" -fi +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")/../" >/dev/null 2>&1 && pwd)" -alias TEXT='gettext "rr"' -shopt -s expand_aliases +if [ -d "/usr/share/locale" ]; then + if [ $(ls ${WORK_PATH}/lang/*.mo 2>/dev/null | wc -l) -gt 0 ]; then + for F in $(ls ${WORK_PATH}/lang/*.mo); do + install "${F}" "/usr/share/locale/$(basename "${F}" .mo)/LC_MESSAGES/rr.mo" + done + fi + + if [ -f ${PART1_PATH}/.locale ]; then + export LANG="$(cat ${PART1_PATH}/.locale)" + fi + + alias TEXT='gettext "rr"' + shopt -s expand_aliases +else + alias TEXT='echo' + shopt -s expand_aliases +fi \ No newline at end of file diff --git a/files/initrd/opt/rr/include/logo.png b/files/initrd/opt/rr/include/logo.png new file mode 100644 index 0000000000000000000000000000000000000000..fc493fbe1accaadc253936857cbc2c2e99233fcc GIT binary patch literal 1271 zcmaJ>`&SYM6s9GHm_~-pDWxbY&1|Ci%AFag`5G1;P06zPNGoki4Ie{kA}JQ7qEcs+ z&#Bo_d>j#okTkMVBRXj!7#bGVR6sX@Cdudz*nYV8JKuM{bMLwLoO>&dMTc2|?ZE&5 zz$zj!k_?v-bzbDGSI{=E{5ZB0RU^^ zm)KP2ZtY<5P$NQ6u?0!X49wlQIOvmE{u($EwHF(HD|#4a2d?(-Df`reu(f$v-F73S zuqm1pa={t(lo6ZekA)xXZ6-rWJ=HOa#%+RQdvRqIl&flOV*Yoff7cg_xQ+{1?~J9- zrI}pqbS57!n$Bp*-DQIY!O4*SPLy(b*%-S2L|3xV1r`1p93@l238vfCifTxm+D#_SvjW_+1nA!0j%-xdl z`bbW|hx5=P_T2hIQBjp=yN4?3*3`~*SH0Bs0i$_*8(npm=cILEzef~(pP-oYJ2Gr} zvdiq}ZlhDy9gdx8pvo@%fbuzrzB+LNQcC`X_H+?pU@*Lf)L0?WrheD{$-~r}+g*ltn2`VG4IhG$55L$HY9Q#eJ1@edT9=nFE zbOi!yDtb9gQWtZna@BS)PK_N5?o5}X2~a8V33LhNB%2$cCeciJQ&TT-C8V3W4u(5&a z%j=UkpEvGp1!*HcnY))#jKh?>oe}Nz1Q/dev/null 2>&1 && pwd)" -. /opt/rr/include/functions.sh +. ${WORK_PATH}/include/functions.sh +. ${WORK_PATH}/include/addons.sh -# Wait kernel enumerate the disks -CNT=3 -while true; do - [ ${CNT} -eq 0 ] && break - LOADER_DISK="$(blkid | grep 'LABEL="RR3"' | cut -d3 -f1)" - [ -n "${LOADER_DISK}" ] && break - CNT=$((${CNT} - 1)) - sleep 1 -done - -[ -z "${LOADER_DISK}" ] && die "$(TEXT "Loader disk not found!")" -NUM_PARTITIONS=$(blkid | grep "${LOADER_DISK}[0-9]\+" | cut -d: -f1 | wc -l) -[ ${NUM_PARTITIONS} -lt 3 ] && die "$(TEXT "Loader disk seems to be damaged!")" -[ ${NUM_PARTITIONS} -gt 3 ] && die "$(TEXT "There are multiple loader disks, please insert only one loader disk!")" - -# Check partitions and ignore errors -fsck.vfat -aw ${LOADER_DISK}1 >/dev/null 2>&1 || true -fsck.ext2 -p ${LOADER_DISK}2 >/dev/null 2>&1 || true -fsck.ext4 -p ${LOADER_DISK}3 >/dev/null 2>&1 || true -# Make folders to mount partitions -mkdir -p ${BOOTLOADER_PATH} -mkdir -p ${SLPART_PATH} -mkdir -p ${CACHE_PATH} -mkdir -p ${DSMROOT_PATH} -# Mount the partitions -mount ${LOADER_DISK}1 ${BOOTLOADER_PATH} || die "$(printf "$(TEXT "Can't mount %s")" "${BOOTLOADER_PATH}")" -mount ${LOADER_DISK}2 ${SLPART_PATH} || die "$(printf "$(TEXT "Can't mount %s")" "${SLPART_PATH}")" -mount ${LOADER_DISK}3 ${CACHE_PATH} || die "$(printf "$(TEXT "Can't mount %s")" "${CACHE_PATH}")" - -# Although i18n.sh is included in functions.sh, but i18n.sh dependent ${BOOTLOADER_PATH}/${LOADER_DISK}1, so need to call it again. -. /opt/rr/include/i18n.sh +[ -z "${LOADER_DISK}" ] && die "$(TEXT "Loader is not init!")" # Shows title clear +[ -z "${COLUMNS}" ] && COLUMNS=50 TITLE="$(printf "$(TEXT "Welcome to %s")" "${RR_TITLE}")" printf "\033[1;44m%*s\n" ${COLUMNS} "" printf "\033[1;44m%*s\033[A\n" ${COLUMNS} "" printf "\033[1;32m%*s\033[0m\n" $(((${#TITLE} + ${COLUMNS}) / 2)) "${TITLE}" printf "\033[1;44m%*s\033[0m\n" ${COLUMNS} "" -# Move/link SSH machine keys to/from cache volume -[ ! -d "${CACHE_PATH}/ssh" ] && cp -R "/etc/ssh" "${CACHE_PATH}/ssh" -rm -rf "/etc/ssh" -ln -s "${CACHE_PATH}/ssh" "/etc/ssh" -# Link bash history to cache volume -rm -rf ~/.bash_history -ln -s ${CACHE_PATH}/.bash_history ~/.bash_history -touch ~/.bash_history -if ! grep -q "menu.sh" ~/.bash_history; then - echo "menu.sh " >>~/.bash_history -fi -# Check if exists directories into P3 partition, if yes remove and link it -if [ -d "${CACHE_PATH}/model-configs" ]; then - rm -rf "${MODEL_CONFIG_PATH}" - ln -s "${CACHE_PATH}/model-configs" "${MODEL_CONFIG_PATH}" -fi - -if [ -d "${CACHE_PATH}/patch" ]; then - rm -rf "${PATCH_PATH}" - ln -s "${CACHE_PATH}/patch" "${PATCH_PATH}" -fi - # Get first MAC address ETHX=($(ls /sys/class/net/ | grep eth)) # real network cards list # No network devices @@ -74,36 +25,36 @@ ETHX=($(ls /sys/class/net/ | grep eth)) # real network cards list # If user config file not exists, initialize it if [ ! -f "${USER_CONFIG_FILE}" ]; then touch "${USER_CONFIG_FILE}" - writeConfigKey "lkm" "prod" "${USER_CONFIG_FILE}" - writeConfigKey "dsmlogo" "true" "${USER_CONFIG_FILE}" - writeConfigKey "directboot" "false" "${USER_CONFIG_FILE}" - writeConfigKey "prerelease" "false" "${USER_CONFIG_FILE}" - writeConfigKey "bootwait" "10" "${USER_CONFIG_FILE}" - writeConfigKey "bootipwait" "10" "${USER_CONFIG_FILE}" - writeConfigKey "kernelway" "power" "${USER_CONFIG_FILE}" - writeConfigKey "kernelpanic" "5" "${USER_CONFIG_FILE}" - writeConfigKey "odp" "false" "${USER_CONFIG_FILE}" - writeConfigKey "model" "" "${USER_CONFIG_FILE}" - writeConfigKey "productver" "" "${USER_CONFIG_FILE}" - writeConfigKey "buildnum" "" "${USER_CONFIG_FILE}" - writeConfigKey "smallnum" "" "${USER_CONFIG_FILE}" - writeConfigKey "paturl" "" "${USER_CONFIG_FILE}" - writeConfigKey "patsum" "" "${USER_CONFIG_FILE}" - writeConfigKey "sn" "" "${USER_CONFIG_FILE}" - writeConfigKey "mac1" "" "${USER_CONFIG_FILE}" - # writeConfigKey "maxdisks" "" "${USER_CONFIG_FILE}" - writeConfigKey "layout" "qwerty" "${USER_CONFIG_FILE}" - writeConfigKey "keymap" "" "${USER_CONFIG_FILE}" - writeConfigKey "zimage-hash" "" "${USER_CONFIG_FILE}" - writeConfigKey "ramdisk-hash" "" "${USER_CONFIG_FILE}" - writeConfigKey "cmdline" "{}" "${USER_CONFIG_FILE}" - writeConfigKey "synoinfo" "{}" "${USER_CONFIG_FILE}" - writeConfigKey "addons" "{}" "${USER_CONFIG_FILE}" - writeConfigKey "addons.misc" "" "${USER_CONFIG_FILE}" - writeConfigKey "addons.acpid" "" "${USER_CONFIG_FILE}" - writeConfigKey "addons.reboottorr" "" "${USER_CONFIG_FILE}" - writeConfigKey "modules" "{}" "${USER_CONFIG_FILE}" fi +initConfigKey "lkm" "prod" "${USER_CONFIG_FILE}" +initConfigKey "dsmlogo" "true" "${USER_CONFIG_FILE}" +initConfigKey "directboot" "false" "${USER_CONFIG_FILE}" +initConfigKey "prerelease" "false" "${USER_CONFIG_FILE}" +initConfigKey "bootwait" "10" "${USER_CONFIG_FILE}" +initConfigKey "bootipwait" "10" "${USER_CONFIG_FILE}" +initConfigKey "kernelway" "power" "${USER_CONFIG_FILE}" +initConfigKey "kernelpanic" "5" "${USER_CONFIG_FILE}" +initConfigKey "odp" "false" "${USER_CONFIG_FILE}" +initConfigKey "model" "" "${USER_CONFIG_FILE}" +initConfigKey "productver" "" "${USER_CONFIG_FILE}" +initConfigKey "buildnum" "" "${USER_CONFIG_FILE}" +initConfigKey "smallnum" "" "${USER_CONFIG_FILE}" +initConfigKey "paturl" "" "${USER_CONFIG_FILE}" +initConfigKey "patsum" "" "${USER_CONFIG_FILE}" +initConfigKey "sn" "" "${USER_CONFIG_FILE}" +initConfigKey "mac1" "" "${USER_CONFIG_FILE}" +# initConfigKey "maxdisks" "" "${USER_CONFIG_FILE}" +initConfigKey "layout" "qwerty" "${USER_CONFIG_FILE}" +initConfigKey "keymap" "" "${USER_CONFIG_FILE}" +initConfigKey "zimage-hash" "" "${USER_CONFIG_FILE}" +initConfigKey "ramdisk-hash" "" "${USER_CONFIG_FILE}" +initConfigKey "cmdline" "{}" "${USER_CONFIG_FILE}" +initConfigKey "synoinfo" "{}" "${USER_CONFIG_FILE}" +initConfigKey "addons" "{}" "${USER_CONFIG_FILE}" +initConfigKey "addons.misc" "" "${USER_CONFIG_FILE}" +initConfigKey "addons.acpid" "" "${USER_CONFIG_FILE}" +initConfigKey "addons.reboottoloader" "" "${USER_CONFIG_FILE}" +initConfigKey "modules" "{}" "${USER_CONFIG_FILE}" # _sort_netif "$(readConfigKey "addons.sortnetif" "${USER_CONFIG_FILE}")" @@ -119,14 +70,13 @@ done # Get the VID/PID if we are in USB VID="0x46f4" PID="0x0001" -BUS=$(udevadm info --query property --name ${LOADER_DISK} | grep ID_BUS | cut -d= -f2) -[ "${BUS}" = "ata" ] && BUS="sata" +BUS=$(getBus "${LOADER_DISK}") if [ "${BUS}" = "usb" ]; then VID="0x$(udevadm info --query property --name ${LOADER_DISK} | grep ID_VENDOR_ID | cut -d= -f2)" PID="0x$(udevadm info --query property --name ${LOADER_DISK} | grep ID_MODEL_ID | cut -d= -f2)" -elif [ "${BUS}" != "sata" -a "${BUS}" != "scsi" ]; then - die "$(TEXT "Loader disk neither USB or DoM")" +elif [ "${BUS}" != "sata" -a "${BUS}" != "scsi" -a "${BUS}" != "nvme" ]; then + die "$(TEXT "Loader disk neither USB or SATA/SCSI/NVME DoM")" fi # Save variables to user config file @@ -136,16 +86,6 @@ writeConfigKey "pid" ${PID} "${USER_CONFIG_FILE}" # Inform user echo -e "$(TEXT "Loader disk:") \033[1;32m${LOADER_DISK}\033[0m (\033[1;32m${BUS^^} flashdisk\033[0m)" -# Check if partition 3 occupies all free space, resize if needed -LOADER_DEVICE_NAME=$(echo ${LOADER_DISK} | sed 's|/dev/||') -SIZEOFDISK=$(cat /sys/block/${LOADER_DEVICE_NAME}/size) -ENDSECTOR=$(($(fdisk -l ${LOADER_DISK} | awk '/'${LOADER_DEVICE_NAME}3'/{print$3}') + 1)) -if [ ${SIZEOFDISK} -ne ${ENDSECTOR} ]; then - echo -e "\033[1;36m$(printf "$(TEXT "Resizing %s")" "${LOADER_DISK}3")\033[0m" - echo -e "d\n\nn\n\n\n\n\nn\nw" | fdisk "${LOADER_DISK}" >"${LOG_FILE}" 2>&1 || dieLog - resize2fs "${LOADER_DISK}3" >"${LOG_FILE}" 2>&1 || dieLog -fi - # Load keymap name LAYOUT="$(readConfigKey "layout" "${USER_CONFIG_FILE}")" KEYMAP="$(readConfigKey "keymap" "${USER_CONFIG_FILE}")" @@ -210,7 +150,7 @@ for N in $(seq 0 $(expr ${#ETHX[@]} - 1)); do break fi COUNT=$((${COUNT} + 1)) - IP=$(ip route show dev ${ETHX[${N}]} 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p') + IP="$(getIP ${ETHX[${N}]})" if [ -n "${IP}" ]; then echo -en "\r${ETHX[${N}]}(${DRIVER}): $(printf "$(TEXT "Access \033[1;34mhttp://%s:7681\033[0m to configure the loader via web terminal.")" "${IP}")\n" break @@ -228,6 +168,14 @@ echo -e "$(TEXT "User config is on") \033[1;32m${USER_CONFIG_FILE}\033[0m" echo -e "$(TEXT "Default SSH Root password is") \033[1;31mrr\033[0m" echo +DSMLOGO="$(readConfigKey "dsmlogo" "${USER_CONFIG_FILE}")" +if [ "${DSMLOGO}" = "true" -a -c "/dev/fb0" ]; then + IP="$(getIP)" + [ -n "${IP}" ] && URL="http://${IP}:7681" || URL="http://arpl:7681/" + python ${WORK_PATH}/include/functions.py makeqr -d "${URL}" -l "bl" -o "${TMP_PATH}/qrcode.png" + [ -f "${TMP_PATH}/qrcode.png" ] && echo | fbv -acufi "${TMP_PATH}/qrcode.png" >/dev/null 2>/dev/null || true +fi + # Check memory RAM=$(free -m | awk '/Mem:/{print$2}') if [ ${RAM} -le 3500 ]; then @@ -238,4 +186,4 @@ mkdir -p "${ADDONS_PATH}" mkdir -p "${LKM_PATH}" mkdir -p "${MODULES_PATH}" -install-addons.sh +updateAddons diff --git a/files/initrd/opt/rr/install-addons.sh b/files/initrd/opt/rr/install-addons.sh deleted file mode 100755 index 3b405f97..00000000 --- a/files/initrd/opt/rr/install-addons.sh +++ /dev/null @@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -set -e - -. /opt/rr/include/functions.sh - -# Detect if has new local plugins to install/reinstall -for F in $(ls ${CACHE_PATH}/*.addon 2>/dev/null); do - ADDON=$(basename "${F}" | sed 's|.addon||') - rm -rf "${ADDONS_PATH}/${ADDON}" - mkdir -p "${ADDONS_PATH}/${ADDON}" - echo "Installing ${F} to ${ADDONS_PATH}/${ADDON}" - tar -xaf "${F}" -C "${ADDONS_PATH}/${ADDON}" - rm -f "${F}" -done diff --git a/files/initrd/opt/rr/lang/arpl.pot b/files/initrd/opt/rr/lang/rr.pot similarity index 75% rename from files/initrd/opt/rr/lang/arpl.pot rename to files/initrd/opt/rr/lang/rr.pot index 30fccfe0..aa8d629d 100644 --- a/files/initrd/opt/rr/lang/arpl.pot +++ b/files/initrd/opt/rr/lang/rr.pot @@ -8,7 +8,7 @@ msgid "" msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-10-09 19:57+0800\n" +"POT-Creation-Date: 2023-10-27 17:04+0800\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" @@ -17,201 +17,184 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: boot.sh:8 init.sh:160 +#: boot.sh:8 init.sh:9 menu.sh:9 +msgid "Loader is not init!" +msgstr "" + +#: boot.sh:10 init.sh:102 msgid "Loader is not configured!" msgstr "" -#: boot.sh:20 init.sh:41 +#: boot.sh:20 init.sh:14 msgid "Welcome to %s" msgstr "" -#: boot.sh:38 +#: boot.sh:33 msgid "DSM zImage changed" msgstr "" -#: boot.sh:41 boot.sh:54 menu.sh:817 menu.sh:825 menu.sh:851 menu.sh:880 -#: menu.sh:892 menu.sh:916 menu.sh:924 menu.sh:975 menu.sh:988 menu.sh:995 +#: boot.sh:36 boot.sh:49 menu.sh:819 menu.sh:827 menu.sh:853 menu.sh:882 +#: menu.sh:894 menu.sh:918 menu.sh:926 menu.sh:958 menu.sh:975 menu.sh:982 msgid "Error" msgstr "" -#: boot.sh:42 menu.sh:989 +#: boot.sh:37 menu.sh:976 msgid "" "zImage not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" msgstr "" -#: boot.sh:51 +#: boot.sh:46 msgid "DSM Ramdisk changed" msgstr "" -#: boot.sh:55 menu.sh:996 +#: boot.sh:50 menu.sh:983 msgid "" "Ramdisk not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" msgstr "" -#: boot.sh:73 +#: boot.sh:68 msgid "Model:" msgstr "" -#: boot.sh:74 +#: boot.sh:69 msgid "Build:" msgstr "" -#: boot.sh:75 +#: boot.sh:70 msgid "LKM: " msgstr "" -#: boot.sh:76 +#: boot.sh:71 msgid "DMI: " msgstr "" -#: boot.sh:77 +#: boot.sh:72 msgid "CPU: " msgstr "" -#: boot.sh:78 +#: boot.sh:73 msgid "MEM: " msgstr "" -#: boot.sh:81 +#: boot.sh:76 msgid "" "The current version of bootloader does not support booting %s-%s, please " "upgrade and rebuild." msgstr "" -#: boot.sh:93 +#: boot.sh:88 msgid "" -"Please insert at least one sata disk for system installation, except for the " -"bootloader disk." +"Please insert at least one sata/scsi disk for system installation, except " +"for the bootloader disk." msgstr "" -#: boot.sh:142 +#: boot.sh:149 msgid "Cmdline:\\n" msgstr "" -#: boot.sh:148 +#: boot.sh:155 msgid "Reboot to boot directly in DSM" msgstr "" -#: boot.sh:154 init.sh:173 +#: boot.sh:161 init.sh:115 msgid "Detected %s network cards." msgstr "" -#: boot.sh:155 init.sh:174 +#: boot.sh:162 init.sh:116 msgid "Checking Connect." msgstr "" -#: boot.sh:175 +#: boot.sh:182 msgid "Waiting IP.(For reference only)" msgstr "" -#: boot.sh:182 init.sh:199 +#: boot.sh:189 init.sh:141 msgid "DOWN" msgstr "" -#: boot.sh:186 init.sh:203 +#: boot.sh:193 init.sh:145 msgid "NOT CONNECTED" msgstr "" -#: boot.sh:190 init.sh:207 +#: boot.sh:197 init.sh:149 msgid "TIMEOUT (Please check the IP on the router.)" msgstr "" -#: boot.sh:196 +#: boot.sh:203 msgid "Access \\033[1;34mhttp://%s:5000\\033[0m to connect the DSM via web." msgstr "" -#: boot.sh:208 +#: boot.sh:215 msgid "%2ds (Changing access(ssh/web) status will interrupt boot)" msgstr "" -#: boot.sh:212 +#: boot.sh:219 msgid "access(ssh/web) status has changed and booting is interrupted." msgstr "" -#: boot.sh:222 +#: boot.sh:229 msgid "Loading DSM kernel..." msgstr "" -#: boot.sh:226 +#: boot.sh:242 msgid "Warning, running kexec with --noefi param, strange things will happen!!" msgstr "" -#: boot.sh:231 +#: boot.sh:247 msgid "Booting..." msgstr "" -#: boot.sh:233 +#: boot.sh:249 msgid "" -"[This interface will not be operational.\\nPlease wait for a few minutes " -"before using the http://find.synology.com/ or Synology Assistant find DSM " -"and connect.]" +"[This interface will not be operational. Please wait a few minutes.\\nFind " +"DSM via http://find.synology.com/ or Synology Assistant and connect.]" msgstr "" -#: init.sh:17 -msgid "Loader disk not found!" -msgstr "" - -#: init.sh:19 -msgid "Loader disk seems to be damaged!" -msgstr "" - -#: init.sh:20 -msgid "There are multiple loader disks, please insert only one loader disk!" -msgstr "" - -#: init.sh:32 init.sh:33 init.sh:34 -msgid "Can't mount %s" -msgstr "" - -#: init.sh:72 +#: init.sh:23 msgid "Network devices not found!" msgstr "" -#: init.sh:127 -msgid "Loader disk neither USB or DoM" +#: init.sh:79 +msgid "Loader disk neither USB or SATA/SCSI/NVME DoM" msgstr "" -#: init.sh:135 +#: init.sh:87 msgid "Loader disk:" msgstr "" -#: init.sh:142 -msgid "Resizing %s" -msgstr "" - -#: init.sh:153 +#: init.sh:95 msgid "Loading keymap" msgstr "" -#: init.sh:163 +#: init.sh:105 msgid "User requested edit settings." msgstr "" -#: init.sh:192 +#: init.sh:134 msgid "Waiting IP." msgstr "" -#: init.sh:213 +#: init.sh:155 msgid "" "Access \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via web " "terminal." msgstr "" -#: init.sh:223 +#: init.sh:165 msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" msgstr "" -#: init.sh:225 +#: init.sh:167 msgid "User config is on" msgstr "" -#: init.sh:226 +#: init.sh:168 msgid "Default SSH Root password is" msgstr "" -#: init.sh:232 +#: init.sh:182 msgid "" "You have less than 4GB of RAM, if errors occur in loader creation, please " "increase the amount of memory." @@ -225,16 +208,16 @@ msgstr "" msgid "Reading models" msgstr "" -#: menu.sh:120 -msgid "Disable flags restriction" +#: menu.sh:100 +msgid "Compatibility judgment" msgstr "" #: menu.sh:121 -msgid "Show all models" +msgid "Disable flags restriction" msgstr "" #: menu.sh:122 -msgid "Compatibility judgment" +msgid "Show all models" msgstr "" #: menu.sh:124 @@ -267,7 +250,7 @@ msgid "" msgstr "" #: menu.sh:240 -msgid "Get pat data .." +msgid "Get pat data ..." msgstr "" #: menu.sh:259 @@ -288,7 +271,7 @@ msgstr "" msgid "Reconfiguring Synoinfo, Addons and Modules" msgstr "" -#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1826 +#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1813 msgid "Choose a option" msgstr "" @@ -312,8 +295,8 @@ msgstr "" msgid "Upload a external addon" msgstr "" -#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1049 menu.sh:1823 -#: menu.sh:2001 menu.sh:2073 +#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1036 menu.sh:1810 +#: menu.sh:1988 menu.sh:2061 msgid "Exit" msgstr "" @@ -343,7 +326,7 @@ msgstr "" msgid "Select addon to remove" msgstr "" -#: menu.sh:416 menu.sh:1368 menu.sh:1399 menu.sh:1432 menu.sh:1900 +#: menu.sh:416 menu.sh:1355 menu.sh:1386 menu.sh:1419 menu.sh:1887 msgid "This feature is only available when accessed via web/ssh." msgstr "" @@ -351,7 +334,7 @@ msgstr "" msgid "Please upload the *.addons file." msgstr "" -#: menu.sh:434 menu.sh:572 menu.sh:1927 menu.sh:1941 +#: menu.sh:434 menu.sh:572 menu.sh:1914 menu.sh:1928 msgid "Not a valid file, please try again!" msgstr "" @@ -529,644 +512,650 @@ msgstr "" msgid "Select synoinfo entry to remove" msgstr "" -#: menu.sh:791 +#: menu.sh:792 msgid "%s cached." msgstr "" -#: menu.sh:795 +#: menu.sh:796 msgid "Cleaning cache" msgstr "" -#: menu.sh:802 +#: menu.sh:804 msgid "" "Based on the current network situation, switch to %s mirror to downloading." msgstr "" -#: menu.sh:806 +#: menu.sh:808 msgid "Downloading %s" msgstr "" -#: menu.sh:816 menu.sh:879 +#: menu.sh:818 menu.sh:881 msgid "Check internet or cache disk space.\\nError: %d" msgstr "" -#: menu.sh:823 +#: menu.sh:825 msgid "Checking hash of %s: " msgstr "" -#: menu.sh:826 -msgid "md5 hash of pat not match, Please reget pat data from the version menu and try again!" +#: menu.sh:828 +msgid "" +"md5 hash of pat not match, Please reget pat data from the version menu and " +"try again!" msgstr "" -#: menu.sh:830 menu.sh:933 menu.sh:943 +#: menu.sh:832 menu.sh:935 menu.sh:945 msgid "OK" msgstr "" -#: menu.sh:834 +#: menu.sh:836 msgid "Disassembling %s: " msgstr "" -#: menu.sh:839 +#: menu.sh:841 msgid "Uncompressed tar" msgstr "" -#: menu.sh:843 +#: menu.sh:845 msgid "Compressed tar" msgstr "" -#: menu.sh:847 +#: menu.sh:849 msgid "Encrypted" msgstr "" -#: menu.sh:852 +#: menu.sh:854 msgid "" "Could not determine if pat file is encrypted or not, maybe corrupted, try " "again!" msgstr "" -#: menu.sh:862 +#: menu.sh:864 msgid "Extractor cached." msgstr "" -#: menu.sh:869 +#: menu.sh:871 msgid "Downloading old pat to extract synology .pat extractor..." msgstr "" -#: menu.sh:910 menu.sh:913 +#: menu.sh:912 menu.sh:915 msgid "Extracting..." msgstr "" -#: menu.sh:925 +#: menu.sh:927 msgid "pat Invalid, try again!" msgstr "" -#: menu.sh:928 +#: menu.sh:930 msgid "Setting hash: " msgstr "" -#: menu.sh:935 +#: menu.sh:937 msgid "Copying files: " msgstr "" -#: menu.sh:976 +#: menu.sh:959 msgid "Addon %s not found!" msgstr "" -#: menu.sh:1002 menu.sh:2052 +#: menu.sh:989 menu.sh:2040 msgid "Cleaning" msgstr "" -#: menu.sh:1004 +#: menu.sh:991 msgid "Ready!" msgstr "" -#: menu.sh:1017 +#: menu.sh:1004 msgid "Switch LKM version:" msgstr "" -#: menu.sh:1020 +#: menu.sh:1007 msgid "Switch direct boot:" msgstr "" -#: menu.sh:1022 +#: menu.sh:1009 msgid "Timeout of get ip in boot:" msgstr "" -#: menu.sh:1023 +#: menu.sh:1010 msgid "Timeout of boot wait:" msgstr "" -#: menu.sh:1024 +#: menu.sh:1011 msgid "kernel switching method:" msgstr "" -#: menu.sh:1025 +#: menu.sh:1013 msgid "Reboot on kernel panic:" msgstr "" -#: menu.sh:1028 +#: menu.sh:1015 msgid "Set static IP" msgstr "" -#: menu.sh:1029 +#: menu.sh:1016 msgid "Edit user config file manually" msgstr "" -#: menu.sh:1030 +#: menu.sh:1017 msgid "Edit grub.cfg file manually" msgstr "" -#: menu.sh:1031 +#: menu.sh:1018 msgid "Try to recovery a DSM installed system" msgstr "" -#: menu.sh:1032 +#: menu.sh:1019 msgid "Show SATA(s) # ports and drives" msgstr "" -#: menu.sh:1034 +#: menu.sh:1021 msgid "show/modify the current pat data" msgstr "" -#: menu.sh:1036 +#: menu.sh:1023 msgid "Allow downgrade installation" msgstr "" -#: menu.sh:1037 +#: menu.sh:1024 msgid "Format disk(s) # Without loader disk" msgstr "" -#: menu.sh:1038 +#: menu.sh:1025 msgid "Reset DSM system password" msgstr "" -#: menu.sh:1039 +#: menu.sh:1026 msgid "Save modifications of '/opt/rr'" msgstr "" -#: menu.sh:1041 +#: menu.sh:1028 msgid "Custom dts file # Need rebuild" msgstr "" -#: menu.sh:1044 +#: menu.sh:1031 msgid "Backup bootloader disk # test" msgstr "" -#: menu.sh:1045 +#: menu.sh:1032 msgid "Restore bootloader disk # test" msgstr "" -#: menu.sh:1047 +#: menu.sh:1034 msgid "Install development tools" msgstr "" -#: menu.sh:1048 -msgid "Show dsm logo:" +#: menu.sh:1035 +msgid "Show QR logo:" msgstr "" -#: menu.sh:1051 menu.sh:1069 menu.sh:1081 menu.sh:1101 menu.sh:1124 -#: menu.sh:1148 menu.sh:1212 menu.sh:1219 menu.sh:1237 menu.sh:1250 -#: menu.sh:1253 menu.sh:1263 menu.sh:1264 menu.sh:1269 menu.sh:1273 -#: menu.sh:1284 menu.sh:1286 menu.sh:1303 menu.sh:1308 menu.sh:1316 -#: menu.sh:1322 menu.sh:1335 menu.sh:1338 menu.sh:1344 menu.sh:1347 -#: menu.sh:1362 menu.sh:1367 menu.sh:1371 menu.sh:1386 menu.sh:1391 -#: menu.sh:1398 menu.sh:1402 menu.sh:1405 menu.sh:1410 menu.sh:1420 -#: menu.sh:1425 menu.sh:1431 menu.sh:1435 menu.sh:1452 menu.sh:1455 -#: menu.sh:1461 menu.sh:1469 menu.sh:1477 menu.sh:1486 menu.sh:1488 +#: menu.sh:1038 menu.sh:1056 menu.sh:1068 menu.sh:1088 menu.sh:1111 +#: menu.sh:1135 menu.sh:1199 menu.sh:1206 menu.sh:1224 menu.sh:1237 +#: menu.sh:1240 menu.sh:1250 menu.sh:1251 menu.sh:1256 menu.sh:1260 +#: menu.sh:1271 menu.sh:1273 menu.sh:1290 menu.sh:1295 menu.sh:1303 +#: menu.sh:1309 menu.sh:1322 menu.sh:1325 menu.sh:1331 menu.sh:1334 +#: menu.sh:1349 menu.sh:1354 menu.sh:1358 menu.sh:1373 menu.sh:1378 +#: menu.sh:1385 menu.sh:1389 menu.sh:1392 menu.sh:1397 menu.sh:1407 +#: menu.sh:1412 menu.sh:1418 menu.sh:1422 menu.sh:1439 menu.sh:1442 +#: menu.sh:1448 menu.sh:1456 menu.sh:1464 menu.sh:1471 menu.sh:1473 msgid "Advanced" msgstr "" -#: menu.sh:1052 +#: menu.sh:1039 msgid "Advanced option" msgstr "" -#: menu.sh:1070 menu.sh:1082 menu.sh:1102 +#: menu.sh:1057 menu.sh:1069 menu.sh:1089 msgid "Choose a time(seconds)" msgstr "" -#: menu.sh:1112 +#: menu.sh:1099 msgid "Temporary IP: (UI will not refresh)" msgstr "" -#: menu.sh:1149 +#: menu.sh:1136 msgid "Setting IP ..." msgstr "" -#: menu.sh:1210 +#: menu.sh:1197 msgid "\\nTotal of ports: %s\\n" msgstr "" -#: menu.sh:1211 +#: menu.sh:1198 msgid "" "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " "connected." msgstr "" -#: menu.sh:1218 +#: menu.sh:1205 msgid "pat: (editable)" msgstr "" -#: menu.sh:1234 +#: menu.sh:1221 msgid "" "This feature will allow you to downgrade the installation by removing the " "VERSION file from the first partition of all disks.\\n" msgstr "" -#: menu.sh:1235 +#: menu.sh:1222 msgid "Therefore, please insert all disks before continuing.\\n" msgstr "" -#: menu.sh:1236 menu.sh:1270 +#: menu.sh:1223 menu.sh:1257 msgid "" "Warning:\\nThis operation is irreversible. Please backup important data. Do " "you want to continue?" msgstr "" -#: menu.sh:1251 +#: menu.sh:1238 msgid "Removing ..." msgstr "" -#: menu.sh:1252 +#: menu.sh:1239 msgid "Remove VERSION file for all disks completed." msgstr "" -#: menu.sh:1274 +#: menu.sh:1261 msgid "" "Warning:\\nThe current hds is in raid, do you still want to format them?" msgstr "" -#: menu.sh:1285 +#: menu.sh:1272 msgid "Formatting ..." msgstr "" -#: menu.sh:1287 +#: menu.sh:1274 msgid "Formatting is complete." msgstr "" -#: menu.sh:1304 +#: menu.sh:1291 msgid "The installed Syno system not found in the currently inserted disks!" msgstr "" -#: menu.sh:1309 +#: menu.sh:1296 msgid "Choose a user name" msgstr "" -#: menu.sh:1317 +#: menu.sh:1304 msgid "Type a new password for user '%s'" msgstr "" -#: menu.sh:1323 +#: menu.sh:1310 msgid "Invalid password" msgstr "" -#: menu.sh:1336 +#: menu.sh:1323 msgid "Resetting ..." msgstr "" -#: menu.sh:1339 +#: menu.sh:1326 msgid "Password reset completed." msgstr "" -#: menu.sh:1345 menu.sh:1403 menu.sh:1456 +#: menu.sh:1332 menu.sh:1390 menu.sh:1443 msgid "" -"Warning:\\nDo not terminate midway, otherwise it may cause damage to the " -"RR. Do you want to continue?" +"Warning:\\nDo not terminate midway, otherwise it may cause damage to the RR. " +"Do you want to continue?" msgstr "" -#: menu.sh:1348 +#: menu.sh:1335 msgid "Saving ..." msgstr "" -#: menu.sh:1363 +#: menu.sh:1350 msgid "Save is complete." msgstr "" -#: menu.sh:1372 +#: menu.sh:1359 msgid "" "Currently, only dts format files are supported. Please prepare and click to " "confirm uploading.\\n(saved in /mnt/p3/users/)" msgstr "" -#: menu.sh:1387 +#: menu.sh:1374 msgid "Not a valid dts file, please try again!" msgstr "" -#: menu.sh:1392 +#: menu.sh:1379 msgid "A valid dts file, Automatically import at compile time." msgstr "" -#: menu.sh:1406 +#: menu.sh:1393 msgid "Backuping..." msgstr "" -#: menu.sh:1411 +#: menu.sh:1398 msgid "" "Failed to generate backup. There may be insufficient memory. Please clear " "the cache and try again!" msgstr "" -#: menu.sh:1418 +#: menu.sh:1405 msgid "Click on the address above to download." msgstr "" -#: menu.sh:1419 +#: menu.sh:1406 msgid "" "Please confirm the completion of the download before closing this window." msgstr "" -#: menu.sh:1426 +#: menu.sh:1413 msgid "backup is complete." msgstr "" -#: menu.sh:1436 +#: menu.sh:1423 msgid "" "Please upload the backup file.\\nCurrently, zip(github) and img.gz(backup) " "compressed file formats are supported." msgstr "" -#: menu.sh:1453 +#: menu.sh:1440 msgid "Not a valid .zip/.img.gz file, please try again!" msgstr "" -#: menu.sh:1462 +#: menu.sh:1449 msgid "Writing..." msgstr "" -#: menu.sh:1470 +#: menu.sh:1457 msgid "Restore bootloader disk with success to %s!\\nReboot?" msgstr "" -#: menu.sh:1478 +#: menu.sh:1465 msgid "" "This option only installs opkg package management, allowing you to install " "more tools for use and debugging. Do you want to continue?" msgstr "" -#: menu.sh:1487 +#: menu.sh:1472 msgid "opkg installing ..." msgstr "" -#: menu.sh:1489 +#: menu.sh:1474 msgid "" "opkg install is complete. Please reconnect to SSH/web, or execute 'source ~/." "bashrc'" msgstr "" -#: menu.sh:1504 menu.sh:1541 menu.sh:1548 +#: menu.sh:1489 menu.sh:1526 menu.sh:1533 msgid "Try recovery DSM" msgstr "" -#: menu.sh:1505 +#: menu.sh:1490 msgid "Trying to recovery a DSM installed system" msgstr "" -#: menu.sh:1531 +#: menu.sh:1516 msgid "Found a installation:\\nModel: %s\\nProductversion: %s" msgstr "" -#: menu.sh:1535 +#: menu.sh:1520 msgid "\\nSerial: %s" msgstr "" -#: menu.sh:1549 +#: menu.sh:1534 msgid "Unfortunately I couldn't mount the DSM partition!" msgstr "" -#: menu.sh:1557 menu.sh:1563 menu.sh:1586 +#: menu.sh:1542 menu.sh:1548 menu.sh:1571 msgid "Edit with caution" msgstr "" -#: menu.sh:1597 +#: menu.sh:1582 msgid "Alert" msgstr "" -#: menu.sh:1598 +#: menu.sh:1583 msgid "Config changed, would you like to rebuild the loader?" msgstr "" -#: menu.sh:1610 menu.sh:1994 +#: menu.sh:1585 menu.sh:1991 menu.sh:2024 +msgid "Main menu" +msgstr "" + +#: menu.sh:1586 menu.sh:2025 +msgid "Making ..." +msgstr "" + +#: menu.sh:1596 menu.sh:1981 msgid "Choose a language" msgstr "" -#: menu.sh:1624 +#: menu.sh:1610 msgid "Choose a layout" msgstr "" -#: menu.sh:1636 +#: menu.sh:1622 msgid "Choice a keymap" msgstr "" -#: menu.sh:1655 menu.sh:1708 menu.sh:1759 menu.sh:1831 menu.sh:1834 -#: menu.sh:1837 menu.sh:1840 menu.sh:1847 menu.sh:1854 menu.sh:1861 -#: menu.sh:1868 +#: menu.sh:1641 menu.sh:1695 menu.sh:1746 menu.sh:1818 menu.sh:1821 +#: menu.sh:1824 menu.sh:1827 menu.sh:1834 menu.sh:1841 menu.sh:1848 +#: menu.sh:1855 msgid "Update %s" msgstr "" -#: menu.sh:1658 +#: menu.sh:1644 msgid "Checking last version" msgstr "" -#: menu.sh:1671 menu.sh:1674 +#: menu.sh:1657 menu.sh:1660 msgid "Error checking new version" msgstr "" -#: menu.sh:1681 +#: menu.sh:1667 msgid "No new version." msgstr "" -#: menu.sh:1685 +#: menu.sh:1671 msgid "No new version. Actual version is %s\\nForce update?" msgstr "" -#: menu.sh:1690 -msgid "Downloading last version" +#: menu.sh:1679 +msgid "Downloading ..." msgstr "" -#: menu.sh:1696 menu.sh:1699 +#: menu.sh:1683 menu.sh:1686 msgid "Error downloading new version" msgstr "" -#: menu.sh:1710 menu.sh:1761 +#: menu.sh:1697 menu.sh:1748 msgid "Extracting last version" msgstr "" -#: menu.sh:1714 +#: menu.sh:1701 msgid "Error extracting update file" msgstr "" -#: menu.sh:1721 +#: menu.sh:1708 msgid "Checksum do not match!" msgstr "" -#: menu.sh:1730 +#: menu.sh:1717 msgid "" "The current version does not support upgrading to the latest update.zip. " "Please remake the bootloader disk!" msgstr "" -#: menu.sh:1735 +#: menu.sh:1722 msgid "Installing new files" msgstr "" -#: menu.sh:1752 +#: menu.sh:1739 msgid "RR updated with success to %s!\\nReboot?" msgstr "" -#: menu.sh:1767 +#: menu.sh:1754 msgid "Installing new %s" msgstr "" -#: menu.sh:1796 menu.sh:1799 +#: menu.sh:1783 menu.sh:1786 msgid "%s updated with success!" msgstr "" -#: menu.sh:1813 +#: menu.sh:1800 msgid "Update all" msgstr "" -#: menu.sh:1814 +#: menu.sh:1801 msgid "Update RR" msgstr "" -#: menu.sh:1815 +#: menu.sh:1802 msgid "Update addons" msgstr "" -#: menu.sh:1816 +#: menu.sh:1803 msgid "Update modules" msgstr "" -#: menu.sh:1817 +#: menu.sh:1804 msgid "Update LKMs" msgstr "" -#: menu.sh:1819 +#: menu.sh:1806 msgid "Set proxy server" msgstr "" -#: menu.sh:1821 +#: menu.sh:1808 msgid "Local upload" msgstr "" -#: menu.sh:1822 +#: menu.sh:1809 msgid "Pre Release:" msgstr "" -#: menu.sh:1831 menu.sh:1854 +#: menu.sh:1818 menu.sh:1841 msgid "addons" msgstr "" -#: menu.sh:1834 menu.sh:1861 +#: menu.sh:1821 menu.sh:1848 msgid "modules" msgstr "" -#: menu.sh:1837 menu.sh:1868 +#: menu.sh:1824 menu.sh:1855 msgid "LKMs" msgstr "" -#: menu.sh:1840 menu.sh:1847 +#: menu.sh:1827 menu.sh:1834 msgid "RR" msgstr "" -#: menu.sh:1877 menu.sh:1888 menu.sh:1899 menu.sh:1909 menu.sh:1926 -#: menu.sh:1940 +#: menu.sh:1864 menu.sh:1875 menu.sh:1886 menu.sh:1896 menu.sh:1913 +#: menu.sh:1927 msgid "Update" msgstr "" -#: menu.sh:1878 +#: menu.sh:1865 msgid "Please enter a proxy server url" msgstr "" -#: menu.sh:1889 +#: menu.sh:1876 msgid "Invalid proxy server url, continue?" msgstr "" -#: menu.sh:1904 +#: menu.sh:1891 msgid "" "Please keep the attachment name consistent with the attachment name on " "Github.\\n" msgstr "" -#: menu.sh:1905 +#: menu.sh:1892 msgid "Upload update.zip will update RR.\\n" msgstr "" -#: menu.sh:1906 +#: menu.sh:1893 msgid "Upload addons.zip will update Addons.\\n" msgstr "" -#: menu.sh:1907 +#: menu.sh:1894 msgid "Upload modules.zip will update Modules.\\n" msgstr "" -#: menu.sh:1908 +#: menu.sh:1895 msgid "Upload rp-lkms.zip will update LKMs.\\n" msgstr "" -#: menu.sh:1957 +#: menu.sh:1944 msgid "This person is very lazy and hasn't written anything." msgstr "" -#: menu.sh:1958 +#: menu.sh:1945 msgid "Edit" msgstr "" -#: menu.sh:1975 +#: menu.sh:1962 msgid "Choose a model" msgstr "" -#: menu.sh:1977 +#: menu.sh:1964 msgid "Choose a version" msgstr "" -#: menu.sh:1979 +#: menu.sh:1966 msgid "Addons menu" msgstr "" -#: menu.sh:1980 +#: menu.sh:1967 msgid "Modules menu" msgstr "" -#: menu.sh:1981 +#: menu.sh:1968 msgid "Cmdline menu" msgstr "" -#: menu.sh:1982 +#: menu.sh:1969 msgid "Synoinfo menu" msgstr "" -#: menu.sh:1985 +#: menu.sh:1972 msgid "Advanced menu" msgstr "" -#: menu.sh:1988 +#: menu.sh:1975 msgid "Build the loader" msgstr "" -#: menu.sh:1992 +#: menu.sh:1979 msgid "Boot the loader" msgstr "" -#: menu.sh:1995 +#: menu.sh:1982 msgid "Choose a keymap" msgstr "" -#: menu.sh:1997 +#: menu.sh:1984 msgid "Clean disk cache" msgstr "" -#: menu.sh:1999 +#: menu.sh:1986 msgid "Update menu" msgstr "" -#: menu.sh:2000 +#: menu.sh:1987 msgid "Notepad" msgstr "" -#: menu.sh:2004 -msgid "Main menu" -msgstr "" - -#: menu.sh:2068 +#: menu.sh:2056 msgid "Choose a action" msgstr "" -#: menu.sh:2069 +#: menu.sh:2057 msgid "Poweroff" msgstr "" -#: menu.sh:2070 +#: menu.sh:2058 msgid "Reboot" msgstr "" -#: menu.sh:2071 +#: menu.sh:2059 msgid "Reboot to RR" msgstr "" -#: menu.sh:2072 +#: menu.sh:2060 msgid "Back to shell" msgstr "" -#: menu.sh:2098 +#: menu.sh:2086 msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" msgstr "" diff --git a/files/initrd/opt/rr/lang/zh_CN.po b/files/initrd/opt/rr/lang/zh_CN.po index 31e5051e..3e14e3b8 100644 --- a/files/initrd/opt/rr/lang/zh_CN.po +++ b/files/initrd/opt/rr/lang/zh_CN.po @@ -1,14 +1,14 @@ -# Chinese translations for rr package. -# Copyright (C) 2023 THE rr'S COPYRIGHT HOLDER -# This file is distributed under the same license as the rr package. +# Chinese translations for RR package. +# Copyright (C) 2023 THE RR'S COPYRIGHT HOLDER +# This file is distributed under the same license as the RR package. # ing , 2023. # msgid "" msgstr "" -"Project-Id-Version: rr\n" +"Project-Id-Version: RR\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-10-09 17:39+0800\n" -"PO-Revision-Date: 2023-10-09 17:39+0800\n" +"POT-Creation-Date: 2023-10-25 17:37+0800\n" +"PO-Revision-Date: 2023-10-25 17:38+0800\n" "Last-Translator: ing \n" "Language-Team: Chinese (simplified) \n" "Language: zh_CN\n" @@ -16,205 +16,188 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: boot.sh:8 init.sh:160 +#: boot.sh:8 init.sh:8 menu.sh:9 +msgid "Loader is not init!" +msgstr "引导未初始化!" + +#: boot.sh:10 init.sh:101 msgid "Loader is not configured!" msgstr "引导未配置!" -#: boot.sh:20 init.sh:41 +#: boot.sh:20 init.sh:13 msgid "Welcome to %s" msgstr "Welcome to %s" -#: boot.sh:38 +#: boot.sh:33 msgid "DSM zImage changed" msgstr "DSM zImage 已更改" -#: boot.sh:41 boot.sh:54 menu.sh:817 menu.sh:825 menu.sh:851 menu.sh:880 -#: menu.sh:892 menu.sh:916 menu.sh:924 menu.sh:975 menu.sh:988 menu.sh:995 +#: boot.sh:36 boot.sh:49 menu.sh:819 menu.sh:827 menu.sh:853 menu.sh:882 +#: menu.sh:894 menu.sh:918 menu.sh:926 menu.sh:958 menu.sh:975 menu.sh:982 msgid "Error" msgstr "错误" -#: boot.sh:42 menu.sh:989 +#: boot.sh:37 menu.sh:976 msgid "" "zImage not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" -msgstr "zImage打补丁失败,\\n请升级引导版本并重试.\\nPatch 错误:\\n" +msgstr "zImage 打补丁失败,\\n请升级引导版本并重试.\\nPatch 错误:\\n" -#: boot.sh:51 +#: boot.sh:46 msgid "DSM Ramdisk changed" msgstr "DSM Ramdisk 已更改" -#: boot.sh:55 menu.sh:996 +#: boot.sh:50 menu.sh:983 msgid "" "Ramdisk not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" -msgstr "Ramdisk打补丁失败,\\n请升级引导版本并重试.\\nPatch 错误:\\n" +msgstr "Ramdisk 打补丁失败,\\n请升级引导版本并重试.\\nPatch 错误:\\n" -#: boot.sh:73 +#: boot.sh:68 msgid "Model:" msgstr "型号: " -#: boot.sh:74 +#: boot.sh:69 msgid "Build:" msgstr "版本: " -#: boot.sh:75 +#: boot.sh:70 msgid "LKM: " msgstr "LKM: " -#: boot.sh:76 +#: boot.sh:71 msgid "DMI: " msgstr "DMI: " -#: boot.sh:77 +#: boot.sh:72 msgid "CPU: " msgstr "CPU: " -#: boot.sh:78 +#: boot.sh:73 msgid "MEM: " msgstr "MEM: " -#: boot.sh:81 +#: boot.sh:76 msgid "" "The current version of bootloader does not support booting %s-%s, please " "upgrade and rebuild." msgstr "当前版本的引导盘不支持引导 %s-%s, 请升级并重新编译." -#: boot.sh:93 +#: boot.sh:88 msgid "" -"Please insert at least one sata disk for system installation, except for the " -"bootloader disk." -msgstr "除引导盘外, 请至少插入一块 sata 磁盘进行系统安装." +"Please insert at least one sata/scsi disk for system installation, except " +"for the bootloader disk." +msgstr "除引导盘外, 请至少插入一块 sata/scsi 磁盘进行系统安装." -#: boot.sh:142 +#: boot.sh:149 msgid "Cmdline:\\n" msgstr "Cmdline:\\n" -#: boot.sh:148 +#: boot.sh:155 msgid "Reboot to boot directly in DSM" -msgstr "重启并直接进入DSM引导" +msgstr "重启并直接进入 DSM 引导" -#: boot.sh:154 init.sh:173 +#: boot.sh:161 init.sh:114 msgid "Detected %s network cards." msgstr "检测到 %s 个网卡." -#: boot.sh:155 init.sh:174 +#: boot.sh:162 init.sh:115 msgid "Checking Connect." msgstr "检查连接." -#: boot.sh:175 +#: boot.sh:182 msgid "Waiting IP.(For reference only)" msgstr "获取 IP.(仅供参考)" -#: boot.sh:182 init.sh:199 +#: boot.sh:189 init.sh:140 msgid "DOWN" msgstr "关闭" -#: boot.sh:186 init.sh:203 +#: boot.sh:193 init.sh:144 msgid "NOT CONNECTED" msgstr "未连接" -#: boot.sh:190 init.sh:207 +#: boot.sh:197 init.sh:148 msgid "TIMEOUT (Please check the IP on the router.)" msgstr "超时 (请检查路由器上的IP.)" -#: boot.sh:196 +#: boot.sh:203 msgid "Access \\033[1;34mhttp://%s:5000\\033[0m to connect the DSM via web." msgstr "在浏览器中访问 \\033[1;34mhttp://%s:5000\\033[0m 链接 DSM." -#: boot.sh:208 +#: boot.sh:215 msgid "%2ds (Changing access(ssh/web) status will interrupt boot)" msgstr "%2ds ((ssh/web)连接状态改变将中断启动)" -#: boot.sh:212 +#: boot.sh:219 msgid "access(ssh/web) status has changed and booting is interrupted." msgstr "(ssh/web)连接状态已改变, 启动被中断." -#: boot.sh:222 +#: boot.sh:229 msgid "Loading DSM kernel..." msgstr "加载 DSM 内核..." -#: boot.sh:226 +#: boot.sh:242 msgid "Warning, running kexec with --noefi param, strange things will happen!!" msgstr "警告, 使用'--noefi'参数运行'kexec', 可能有不好的事情发生!!" -#: boot.sh:231 +#: boot.sh:247 msgid "Booting..." msgstr "引导中..." -#: boot.sh:233 +#: boot.sh:249 msgid "" -"[This interface will not be operational.\\nPlease wait for a few minutes " -"before using the http://find.synology.com/ or Synology Assistant find DSM " -"and connect.]" -msgstr "[该界面已不可操作.\\n请在数分钟后通过 http://find.synology.com/ 或者 Synology Assistant 查找DSM并访问.]" +"[This interface will not be operational. Please wait a few minutes.\\nFind " +"DSM via http://find.synology.com/ or Synology Assistant and connect.]" +msgstr "[该界面已不可操作. 请在数分钟后\\n通过 http://find.synology.com/ 或者 Synology Assistant 查找 DSM 并访问.]" -#: init.sh:17 -msgid "Loader disk not found!" -msgstr "未找到引导磁盘!" - -#: init.sh:19 -msgid "Loader disk seems to be damaged!" -msgstr "引导磁盘似乎已损坏!" - -#: init.sh:20 -msgid "There are multiple loader disks, please insert only one loader disk!" -msgstr "存在多个引导磁盘,请仅插入一个引导磁盘!" - -#: init.sh:32 init.sh:33 init.sh:34 -msgid "Can't mount %s" -msgstr "挂载 %s 失败" - -#: init.sh:72 +#: init.sh:22 msgid "Network devices not found!" msgstr "未找到网卡!" -#: init.sh:127 -msgid "Loader disk neither USB or DoM" -msgstr "引导磁盘仅支持 USB 或者 DoM" +#: init.sh:78 +msgid "Loader disk neither USB or SATA/SCSI/NVME DoM" +msgstr "引导磁盘仅支持 USB 或者 SATA/SCSI/NVME DoM" -#: init.sh:135 +#: init.sh:86 msgid "Loader disk:" msgstr "引导盘:" -#: init.sh:142 -msgid "Resizing %s" -msgstr "重置 %s 大小" - -#: init.sh:153 +#: init.sh:94 msgid "Loading keymap" msgstr "加载键盘映射" -#: init.sh:163 +#: init.sh:104 msgid "User requested edit settings." msgstr "用户触发编辑设置." -#: init.sh:192 +#: init.sh:133 msgid "Waiting IP." msgstr "获取 IP." -#: init.sh:213 +#: init.sh:154 msgid "" "Access \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via web " "terminal." -msgstr "在浏览器中访问 \\033[1;34mhttp://%s:7681\\033[0m 进入WEB终端进行配置." +msgstr "在浏览器中访问 \\033[1;34mhttp://%s:7681\\033[0m 进入 WEB 终端进行配置." -#: init.sh:223 +#: init.sh:164 msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" msgstr "执行 \\033[1;32mmenu.sh\\033[0m 进入设置菜单" -#: init.sh:225 +#: init.sh:166 msgid "User config is on" msgstr "用户配置文件位于" -#: init.sh:226 +#: init.sh:167 msgid "Default SSH Root password is" -msgstr "默认SSH的root密码为" +msgstr "默认 SSH 的 root 密码为" -#: init.sh:232 +#: init.sh:181 msgid "" "You have less than 4GB of RAM, if errors occur in loader creation, please " "increase the amount of memory." -msgstr "您的RAM不足4GB, 如果在创建引导时出现错误,请增加内存." +msgstr "您的 RAM 不足 4GB, 如果在创建引导时出现错误, 请增加内存." #: menu.sh:89 msgid "Model" @@ -224,18 +207,18 @@ msgstr "型号" msgid "Reading models" msgstr "读取型号" -#: menu.sh:120 +#: menu.sh:100 +msgid "Compatibility judgment" +msgstr "兼容性判断" + +#: menu.sh:121 msgid "Disable flags restriction" msgstr "禁用标志限制" -#: menu.sh:121 +#: menu.sh:122 msgid "Show all models" msgstr "显示所有型号" -#: menu.sh:122 -msgid "Compatibility judgment" -msgstr "兼容性判断" - #: menu.sh:124 msgid "Choose the model" msgstr "选择型号" @@ -251,13 +234,13 @@ msgstr "版本" #: menu.sh:223 msgid "" "The current version has been set to %s. Do you want to reset the version?" -msgstr "当前版本已设置为%s. 是否要重置版本?" +msgstr "当前版本已设置为 %s. 是否要重置版本?" #: menu.sh:229 msgid "" "This version does not support UEFI startup, Please select another version or " "switch the startup mode." -msgstr "该版本不支持UEFI启动, 请选择其他版本或者切换启动模式." +msgstr "该版本不支持 UEFI 启动, 请选择其他版本或者切换启动模式." #: menu.sh:234 msgid "" @@ -266,18 +249,18 @@ msgid "" msgstr "该版本仅支持 usb 启动, 请选择其他版本或者切换启动模式." #: menu.sh:240 -msgid "Get pat data .." -msgstr "获取pat数据 .." +msgid "Get pat data ..." +msgstr "获取 pat 数据 ..." #: menu.sh:259 msgid "" "Failed to get pat data,\\nPlease manually fill in the URL and md5sum of the " "corresponding version of pat." -msgstr "获取pat数据失败,\\n请手动填写相应版本pat的URL和MD5." +msgstr "获取 pat 数据失败,\\n请手动填写相应版本 pat 的 URL 和 MD5." #: menu.sh:263 msgid "Successfully to get pat data,\\nPlease confirm or modify as needed." -msgstr "获取pat数据成功,\\n请确认或者按需修改." +msgstr "获取 pat 数据成功,\\n请确认或者按需修改." #: menu.sh:266 msgid "Retry" @@ -285,9 +268,9 @@ msgstr "重试" #: menu.sh:286 msgid "Reconfiguring Synoinfo, Addons and Modules" -msgstr "重新配置概要, 插件和模块" +msgstr "重新配置 Syninfo, 插件和模块" -#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1826 +#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1813 msgid "Choose a option" msgstr "选择一个选项" @@ -311,8 +294,8 @@ msgstr "显示所有可用插件" msgid "Upload a external addon" msgstr "上传外部插件" -#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1049 menu.sh:1823 -#: menu.sh:2001 menu.sh:2073 +#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1036 menu.sh:1810 +#: menu.sh:1988 menu.sh:2061 msgid "Exit" msgstr "退出" @@ -342,15 +325,15 @@ msgstr "没有要删除的用户插件" msgid "Select addon to remove" msgstr "选择要删除的插件" -#: menu.sh:416 menu.sh:1368 menu.sh:1399 menu.sh:1432 menu.sh:1900 +#: menu.sh:416 menu.sh:1355 menu.sh:1386 menu.sh:1419 menu.sh:1887 msgid "This feature is only available when accessed via web/ssh." -msgstr "此功能仅在通过web/ssh访问时可用." +msgstr "此功能仅在通过 web/ssh 访问时可用." #: menu.sh:420 msgid "Please upload the *.addons file." msgstr "请上传 *.addons 文件." -#: menu.sh:434 menu.sh:572 menu.sh:1927 menu.sh:1941 +#: menu.sh:434 menu.sh:572 menu.sh:1914 menu.sh:1928 msgid "Not a valid file, please try again!" msgstr "不是有效的文件, 请重试!" @@ -450,11 +433,11 @@ msgstr "模块 '%s' 已添加到 %s-%s" #: menu.sh:593 msgid "Add/edit a cmdline item" -msgstr "添加/编辑cmdline参数" +msgstr "添加/编辑 cmdline 参数" #: menu.sh:594 msgid "Delete cmdline item(s)" -msgstr "删除cmdline参数(s)" +msgstr "删除 cmdline 参数(s)" #: menu.sh:596 msgid "Define SN/MAC" @@ -462,11 +445,11 @@ msgstr "自定义 SN/MAC" #: menu.sh:598 msgid "Show user added cmdline" -msgstr "显示用户添加的cmdline参数" +msgstr "显示用户添加的 cmdline 参数" #: menu.sh:599 msgid "Show model inherent cmdline" -msgstr "显示型号默认的cmdline参数" +msgstr "显示型号默认的 cmdline 参数" #: menu.sh:609 menu.sh:615 menu.sh:625 menu.sh:633 menu.sh:649 menu.sh:659 #: menu.sh:688 menu.sh:696 @@ -503,15 +486,15 @@ msgstr "无效 SN/MAC, 重试?" #: menu.sh:713 msgid "Add/edit a synoinfo item" -msgstr "添加/编辑Synoinfo参数" +msgstr "添加/编辑 Synoinfo 参数" #: menu.sh:714 msgid "Delete synoinfo item(s)" -msgstr "删除Synoinfo参数(s)" +msgstr "删除 Synoinfo 参数(s)" #: menu.sh:715 msgid "Show synoinfo entries" -msgstr "显示Synoinfo参数" +msgstr "显示 Synoinfo 参数" #: menu.sh:726 menu.sh:732 menu.sh:743 menu.sh:751 menu.sh:768 msgid "Synoinfo" @@ -527,652 +510,658 @@ msgstr "输入 '%s' 参数的值" #: menu.sh:744 msgid "No synoinfo entries to remove" -msgstr "没有Synoinfo参数被删除" +msgstr "没有 Synoinfo 参数被删除" #: menu.sh:752 msgid "Select synoinfo entry to remove" msgstr "选择要删除的参数" -#: menu.sh:791 +#: menu.sh:792 msgid "%s cached." msgstr "%s 已缓存." -#: menu.sh:795 +#: menu.sh:796 msgid "Cleaning cache" msgstr "清除缓存" -#: menu.sh:802 +#: menu.sh:804 msgid "" "Based on the current network situation, switch to %s mirror to downloading." msgstr "根据当前的网络状况, 已切换到 %s 镜像服务器进行下载." -#: menu.sh:806 +#: menu.sh:808 msgid "Downloading %s" msgstr "下载 %s 中" -#: menu.sh:816 menu.sh:879 +#: menu.sh:818 menu.sh:881 msgid "Check internet or cache disk space.\\nError: %d" msgstr "请检查网络连接或磁盘空间.\\nError: %d" -#: menu.sh:823 +#: menu.sh:825 msgid "Checking hash of %s: " msgstr "检查 %s 的 hash: " -#: menu.sh:826 -msgid "md5 hash of pat not match, Please reget pat data from the version menu and try again!" -msgstr "pat 的 md5 Hash值 不匹配, 请在版本菜单中重新获取pat数据后重试!" +#: menu.sh:828 +msgid "" +"md5 hash of pat not match, Please reget pat data from the version menu and " +"try again!" +msgstr "pat 的 md5 Hash 不匹配, 请在版本菜单中重新获取 pat 数据后重试!" -#: menu.sh:830 menu.sh:933 menu.sh:943 +#: menu.sh:832 menu.sh:935 menu.sh:945 msgid "OK" msgstr "OK" -#: menu.sh:834 +#: menu.sh:836 msgid "Disassembling %s: " -msgstr "解压 %s: " +msgstr "解压缩 %s: " -#: menu.sh:839 +#: menu.sh:841 msgid "Uncompressed tar" -msgstr "未压缩tar" +msgstr "未压缩 tar" -#: menu.sh:843 +#: menu.sh:845 msgid "Compressed tar" -msgstr "压缩tar" +msgstr "已压缩 tar" -#: menu.sh:847 +#: menu.sh:849 msgid "Encrypted" msgstr "已加密" -#: menu.sh:852 +#: menu.sh:854 msgid "" "Could not determine if pat file is encrypted or not, maybe corrupted, try " "again!" -msgstr "无法确定pat文件是否加密, 可能已损坏, 请重试!" +msgstr "无法确定 pat 文件是否加密, 可能已损坏, 请重试!" -#: menu.sh:862 +#: menu.sh:864 msgid "Extractor cached." msgstr "已存在解密程序." -#: menu.sh:869 +#: menu.sh:871 msgid "Downloading old pat to extract synology .pat extractor..." msgstr "下载旧 pat, 提取 .pat 解密程序中..." -#: menu.sh:910 menu.sh:913 +#: menu.sh:912 menu.sh:915 msgid "Extracting..." msgstr "解压中..." -#: menu.sh:925 +#: menu.sh:927 msgid "pat Invalid, try again!" msgstr "无效的 pat, 请重试!" -#: menu.sh:928 +#: menu.sh:930 msgid "Setting hash: " msgstr "设置 hash: " -#: menu.sh:935 +#: menu.sh:937 msgid "Copying files: " msgstr "拷贝文件: " -#: menu.sh:976 +#: menu.sh:959 msgid "Addon %s not found!" msgstr "插件 %s 未找到!" -#: menu.sh:1002 menu.sh:2052 +#: menu.sh:989 menu.sh:2040 msgid "Cleaning" msgstr "清除中" -#: menu.sh:1004 +#: menu.sh:991 msgid "Ready!" msgstr "已就绪!" -#: menu.sh:1017 +#: menu.sh:1004 msgid "Switch LKM version:" -msgstr "选择LKM版本:" +msgstr "选择 LKM 版本:" -#: menu.sh:1020 +#: menu.sh:1007 msgid "Switch direct boot:" msgstr "切换直接启动:" -#: menu.sh:1022 +#: menu.sh:1009 msgid "Timeout of get ip in boot:" -msgstr "启动时获取IP的超时时间:" +msgstr "启动时获取 IP 的超时时间:" -#: menu.sh:1023 +#: menu.sh:1010 msgid "Timeout of boot wait:" msgstr "启动超时时间:" -#: menu.sh:1024 +#: menu.sh:1011 msgid "kernel switching method:" msgstr "内核切换的方式:" -#: menu.sh:1025 +#: menu.sh:1013 msgid "Reboot on kernel panic:" msgstr "内核恐慌时重新启动:" -#: menu.sh:1028 +#: menu.sh:1015 msgid "Set static IP" msgstr "设置静态 IP" -#: menu.sh:1029 +#: menu.sh:1016 msgid "Edit user config file manually" msgstr "手动编辑用户配置文件" -#: menu.sh:1030 +#: menu.sh:1017 msgid "Edit grub.cfg file manually" msgstr "手动编辑 grub.cfg 文件" -#: menu.sh:1031 +#: menu.sh:1018 msgid "Try to recovery a DSM installed system" -msgstr "尝试恢复已安装DSM的系统" +msgstr "尝试恢复已安装 DSM 的系统" -#: menu.sh:1032 +#: menu.sh:1019 msgid "Show SATA(s) # ports and drives" -msgstr "显示SATA(s) # 端口和驱动器" +msgstr "显示 SATA(s) # 端口和驱动器" -#: menu.sh:1034 +#: menu.sh:1021 msgid "show/modify the current pat data" -msgstr "显示/修改当前pat下载链接" +msgstr "显示/修改当前 pat 下载链接" -#: menu.sh:1036 +#: menu.sh:1023 msgid "Allow downgrade installation" msgstr "允许降级安装" -#: menu.sh:1037 +#: menu.sh:1024 msgid "Format disk(s) # Without loader disk" msgstr "格式化磁盘(s) # 不含启动盘" -#: menu.sh:1038 +#: menu.sh:1025 msgid "Reset DSM system password" msgstr "重置 DSM 系统密码" -#: menu.sh:1039 +#: menu.sh:1026 msgid "Save modifications of '/opt/rr'" msgstr "保存'/opt/rr'的修改" -#: menu.sh:1041 +#: menu.sh:1028 msgid "Custom dts file # Need rebuild" msgstr "自定义 dts 文件 # 需要重新编译" -#: menu.sh:1044 +#: menu.sh:1031 msgid "Backup bootloader disk # test" msgstr "备份启动盘 # 测试" -#: menu.sh:1045 +#: menu.sh:1032 msgid "Restore bootloader disk # test" msgstr "恢复启动盘 # 测试" -#: menu.sh:1047 +#: menu.sh:1034 msgid "Install development tools" msgstr "安装开发者工具" -#: menu.sh:1048 -msgid "Show dsm logo:" -msgstr "显示 dsm logo:" +#: menu.sh:1035 +msgid "Show QR logo:" +msgstr "显示 QR logo:" -#: menu.sh:1051 menu.sh:1069 menu.sh:1081 menu.sh:1101 menu.sh:1124 -#: menu.sh:1148 menu.sh:1212 menu.sh:1219 menu.sh:1237 menu.sh:1250 -#: menu.sh:1253 menu.sh:1263 menu.sh:1264 menu.sh:1269 menu.sh:1273 -#: menu.sh:1284 menu.sh:1286 menu.sh:1303 menu.sh:1308 menu.sh:1316 -#: menu.sh:1322 menu.sh:1335 menu.sh:1338 menu.sh:1344 menu.sh:1347 -#: menu.sh:1362 menu.sh:1367 menu.sh:1371 menu.sh:1386 menu.sh:1391 -#: menu.sh:1398 menu.sh:1402 menu.sh:1405 menu.sh:1410 menu.sh:1420 -#: menu.sh:1425 menu.sh:1431 menu.sh:1435 menu.sh:1452 menu.sh:1455 -#: menu.sh:1461 menu.sh:1469 menu.sh:1477 menu.sh:1486 menu.sh:1488 +#: menu.sh:1038 menu.sh:1056 menu.sh:1068 menu.sh:1088 menu.sh:1111 +#: menu.sh:1135 menu.sh:1199 menu.sh:1206 menu.sh:1224 menu.sh:1237 +#: menu.sh:1240 menu.sh:1250 menu.sh:1251 menu.sh:1256 menu.sh:1260 +#: menu.sh:1271 menu.sh:1273 menu.sh:1290 menu.sh:1295 menu.sh:1303 +#: menu.sh:1309 menu.sh:1322 menu.sh:1325 menu.sh:1331 menu.sh:1334 +#: menu.sh:1349 menu.sh:1354 menu.sh:1358 menu.sh:1373 menu.sh:1378 +#: menu.sh:1385 menu.sh:1389 menu.sh:1392 menu.sh:1397 menu.sh:1407 +#: menu.sh:1412 menu.sh:1418 menu.sh:1422 menu.sh:1439 menu.sh:1442 +#: menu.sh:1448 menu.sh:1456 menu.sh:1464 menu.sh:1471 menu.sh:1473 msgid "Advanced" msgstr "高级" -#: menu.sh:1052 +#: menu.sh:1039 msgid "Advanced option" msgstr "高级设置" -#: menu.sh:1070 menu.sh:1082 menu.sh:1102 +#: menu.sh:1057 menu.sh:1069 menu.sh:1089 msgid "Choose a time(seconds)" msgstr "选择一个时间(秒)" -#: menu.sh:1112 +#: menu.sh:1099 msgid "Temporary IP: (UI will not refresh)" msgstr "临时 IP: (UI 不会刷新)" -#: menu.sh:1149 +#: menu.sh:1136 msgid "Setting IP ..." msgstr "设置 IP.." -#: menu.sh:1210 +#: menu.sh:1197 msgid "\\nTotal of ports: %s\\n" msgstr "\\n端口总数: %s\\n" -#: menu.sh:1211 +#: menu.sh:1198 msgid "" "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " "connected." msgstr "\\n\\Z1红色\\Zn 为模拟端口, \\Z2\\Zb绿色\\Zn 为已驱动的物理端口." -#: menu.sh:1218 +#: menu.sh:1205 msgid "pat: (editable)" msgstr "pat: (可编辑)" -#: menu.sh:1234 +#: menu.sh:1221 msgid "" "This feature will allow you to downgrade the installation by removing the " "VERSION file from the first partition of all disks.\\n" -msgstr "此功能通过删除所有磁盘的第一个分区的VERSION文件来允许你降级安装.\\n" +msgstr "此功能通过删除所有磁盘的第一个分区的 VERSION 文件来允许你降级安装.\\n" -#: menu.sh:1235 +#: menu.sh:1222 msgid "Therefore, please insert all disks before continuing.\\n" msgstr "因此, 请插入所有磁盘后再进行操作.\\n" -#: menu.sh:1236 menu.sh:1270 +#: menu.sh:1223 menu.sh:1257 msgid "" "Warning:\\nThis operation is irreversible. Please backup important data. Do " "you want to continue?" msgstr "警告:\\n该操作不可逆, 请提前备份重要数据. 是否继续?" -#: menu.sh:1251 +#: menu.sh:1238 msgid "Removing ..." msgstr "删除中..." -#: menu.sh:1252 +#: menu.sh:1239 msgid "Remove VERSION file for all disks completed." msgstr "已移除所有磁盘的 VERSION 文件." -#: menu.sh:1274 +#: menu.sh:1261 msgid "" "Warning:\\nThe current hds is in raid, do you still want to format them?" -msgstr "警告:\\n当前的硬盘处于raid中,是否仍要格式化?" +msgstr "警告:\\n当前的硬盘处于 raid 中,是否仍要格式化?" -#: menu.sh:1285 +#: menu.sh:1272 msgid "Formatting ..." msgstr "格式化中..." -#: menu.sh:1287 +#: menu.sh:1274 msgid "Formatting is complete." msgstr "格式化完成." -#: menu.sh:1304 +#: menu.sh:1291 msgid "The installed Syno system not found in the currently inserted disks!" -msgstr "未在当前插入的硬盘中找到已安装的syno系统!" +msgstr "未在当前插入的硬盘中找到已安装的 syno 系统!" -#: menu.sh:1309 +#: menu.sh:1296 msgid "Choose a user name" msgstr "选择一个用户" -#: menu.sh:1317 +#: menu.sh:1304 msgid "Type a new password for user '%s'" msgstr "输入用户 '%s' 的新密码" -#: menu.sh:1323 +#: menu.sh:1310 msgid "Invalid password" msgstr "无效密码" -#: menu.sh:1336 +#: menu.sh:1323 msgid "Resetting ..." msgstr "重置中 ..." -#: menu.sh:1339 +#: menu.sh:1326 msgid "Password reset completed." msgstr "重置密码完成." -#: menu.sh:1345 menu.sh:1403 menu.sh:1456 +#: menu.sh:1332 menu.sh:1390 menu.sh:1443 msgid "" -"Warning:\\nDo not terminate midway, otherwise it may cause damage to the " -"RR. Do you want to continue?" -msgstr "警告:\\n请不要中途停止, 否则将导致RR引导损毁, 是否继续?" +"Warning:\\nDo not terminate midway, otherwise it may cause damage to the RR. " +"Do you want to continue?" +msgstr "警告:\\n请不要中途停止, 否则将导致 RR 引导损毁, 是否继续?" -#: menu.sh:1348 +#: menu.sh:1335 msgid "Saving ..." msgstr "保存中..." -#: menu.sh:1363 +#: menu.sh:1350 msgid "Save is complete." msgstr "保存完成." -#: menu.sh:1372 +#: menu.sh:1359 msgid "" "Currently, only dts format files are supported. Please prepare and click to " "confirm uploading.\\n(saved in /mnt/p3/users/)" msgstr "" -"目前, 只支持dts格式的文件, 请准备并点击确认上传.\\n(保存于 /mnt/p3/users/ 中)" +"目前, 只支持 dts 格式的文件, 请准备并点击确认上传.\\n(保存于 /mnt/p3/users/ 中)" -#: menu.sh:1387 +#: menu.sh:1374 msgid "Not a valid dts file, please try again!" msgstr "dts 文件无效, 请重试!" -#: menu.sh:1392 +#: menu.sh:1379 msgid "A valid dts file, Automatically import at compile time." msgstr "dts 文件有效, 将在编译时自动导入." -#: menu.sh:1406 +#: menu.sh:1393 msgid "Backuping..." msgstr "备份中..." -#: menu.sh:1411 +#: menu.sh:1398 msgid "" "Failed to generate backup. There may be insufficient memory. Please clear " "the cache and try again!" msgstr "生成备份失败, 可能内存不足, 请清除缓存重试!" -#: menu.sh:1418 +#: menu.sh:1405 msgid "Click on the address above to download." msgstr "点击上面的地址下载." -#: menu.sh:1419 +#: menu.sh:1406 msgid "" "Please confirm the completion of the download before closing this window." msgstr "请确认下载完成再关闭此窗口." -#: menu.sh:1426 +#: menu.sh:1413 msgid "backup is complete." msgstr "备份完成." -#: menu.sh:1436 +#: menu.sh:1423 msgid "" "Please upload the backup file.\\nCurrently, zip(github) and img.gz(backup) " "compressed file formats are supported." msgstr "请上传备份的文件\\n当前支持 zip(github) 和 img.gz(backup) 格式." -#: menu.sh:1453 +#: menu.sh:1440 msgid "Not a valid .zip/.img.gz file, please try again!" -msgstr "不是有效的.zip/.img.gz文件, 请重试!" +msgstr "不是有效的 .zip/.img.gz 文件, 请重试!" -#: menu.sh:1462 +#: menu.sh:1449 msgid "Writing..." msgstr "写入中..." -#: menu.sh:1470 +#: menu.sh:1457 msgid "Restore bootloader disk with success to %s!\\nReboot?" msgstr "成功恢复启动盘到 %s!\\n重启?" -#: menu.sh:1478 +#: menu.sh:1465 msgid "" "This option only installs opkg package management, allowing you to install " "more tools for use and debugging. Do you want to continue?" msgstr "" "该选项仅安装 opkg 包管理工具, 使你能够安装更多的工具以供使用和调试, 是否继续?" -#: menu.sh:1487 +#: menu.sh:1472 msgid "opkg installing ..." msgstr "opkg 安装中 ..." -#: menu.sh:1489 +#: menu.sh:1474 msgid "" "opkg install is complete. Please reconnect to SSH/web, or execute 'source ~/." "bashrc'" msgstr "opkg 安装完成. 请重新链接 SSH/web, 或者执行 'source ~/.bashrc'" -#: menu.sh:1504 menu.sh:1541 menu.sh:1548 +#: menu.sh:1489 menu.sh:1526 menu.sh:1533 msgid "Try recovery DSM" -msgstr "尝试恢复DSM系统" +msgstr "尝试恢复 DSM 系统" -#: menu.sh:1505 +#: menu.sh:1490 msgid "Trying to recovery a DSM installed system" -msgstr "尝试恢复已安装的DSM系统中" +msgstr "尝试恢复已安装的 DSM 系统中" -#: menu.sh:1531 +#: menu.sh:1516 msgid "Found a installation:\\nModel: %s\\nProductversion: %s" msgstr "找到已安装:\\n型号: %s\\n版本: %s" -#: menu.sh:1535 +#: menu.sh:1520 msgid "\\nSerial: %s" msgstr "\\nSN: %s" -#: menu.sh:1549 +#: menu.sh:1534 msgid "Unfortunately I couldn't mount the DSM partition!" -msgstr "很遗憾, 我无法挂载DSM分区!" +msgstr "很遗憾, 我无法挂载 DSM 分区!" -#: menu.sh:1557 menu.sh:1563 menu.sh:1586 +#: menu.sh:1542 menu.sh:1548 menu.sh:1571 msgid "Edit with caution" msgstr "请谨慎编辑" -#: menu.sh:1597 +#: menu.sh:1582 msgid "Alert" msgstr "警告" -#: menu.sh:1598 +#: menu.sh:1583 msgid "Config changed, would you like to rebuild the loader?" msgstr "配置已更改, 是否重新编译引导?" -#: menu.sh:1610 menu.sh:1994 +#: menu.sh:1585 menu.sh:1991 menu.sh:2024 +msgid "Main menu" +msgstr "主菜单" + +#: menu.sh:1586 menu.sh:2025 +msgid "Making ..." +msgstr "编译中 ..." + +#: menu.sh:1596 menu.sh:1981 msgid "Choose a language" msgstr "选择语言" -#: menu.sh:1624 +#: menu.sh:1610 msgid "Choose a layout" msgstr "选择布局" -#: menu.sh:1636 +#: menu.sh:1622 msgid "Choice a keymap" msgstr "选择键盘映射" -#: menu.sh:1655 menu.sh:1708 menu.sh:1759 menu.sh:1831 menu.sh:1834 -#: menu.sh:1837 menu.sh:1840 menu.sh:1847 menu.sh:1854 menu.sh:1861 -#: menu.sh:1868 +#: menu.sh:1641 menu.sh:1695 menu.sh:1746 menu.sh:1818 menu.sh:1821 +#: menu.sh:1824 menu.sh:1827 menu.sh:1834 menu.sh:1841 menu.sh:1848 +#: menu.sh:1855 msgid "Update %s" msgstr "更新 %s" -#: menu.sh:1658 +#: menu.sh:1644 msgid "Checking last version" msgstr "检测新版本中" -#: menu.sh:1671 menu.sh:1674 +#: menu.sh:1657 menu.sh:1660 msgid "Error checking new version" msgstr "检测新版本错误" -#: menu.sh:1681 +#: menu.sh:1667 msgid "No new version." msgstr "没有新版本." -#: menu.sh:1685 +#: menu.sh:1671 msgid "No new version. Actual version is %s\\nForce update?" msgstr "没有新版本. 实际版本为 %s\\n强制更新?" -#: menu.sh:1690 -msgid "Downloading last version" -msgstr "下载新版本中" +#: menu.sh:1679 +msgid "Downloading ..." +msgstr "下载中 ..." -#: menu.sh:1696 menu.sh:1699 +#: menu.sh:1683 menu.sh:1686 msgid "Error downloading new version" msgstr "下载新版本错误" -#: menu.sh:1710 menu.sh:1761 +#: menu.sh:1697 menu.sh:1748 msgid "Extracting last version" msgstr "解压新版本" -#: menu.sh:1714 +#: menu.sh:1701 msgid "Error extracting update file" msgstr "更新文件解压错误" -#: menu.sh:1721 +#: menu.sh:1708 msgid "Checksum do not match!" -msgstr "Checksum不匹配!" +msgstr "Checksum 不匹配!" -#: menu.sh:1730 +#: menu.sh:1717 msgid "" "The current version does not support upgrading to the latest update.zip. " "Please remake the bootloader disk!" -msgstr "当前版本不支持最新的update.zip升级, 请重新制作引导盘!" +msgstr "当前版本不支持最新的 update.zip 升级, 请重新制作引导盘!" -#: menu.sh:1735 +#: menu.sh:1722 msgid "Installing new files" msgstr "安装更新中" -#: menu.sh:1752 +#: menu.sh:1739 msgid "RR updated with success to %s!\\nReboot?" -msgstr "RR更新成功 %s!\\n重启?" +msgstr "RR 更新成功 %s!\\n重启?" -#: menu.sh:1767 +#: menu.sh:1754 msgid "Installing new %s" msgstr "安装新 %s 中" -#: menu.sh:1796 menu.sh:1799 +#: menu.sh:1783 menu.sh:1786 msgid "%s updated with success!" msgstr "%s 更新成功!" -#: menu.sh:1813 +#: menu.sh:1800 msgid "Update all" -msgstr "更新所有" +msgstr "更新全部" -#: menu.sh:1814 +#: menu.sh:1801 msgid "Update RR" -msgstr "更新RR" +msgstr "更新 RR " -#: menu.sh:1815 +#: menu.sh:1802 msgid "Update addons" msgstr "更新插件" -#: menu.sh:1816 +#: menu.sh:1803 msgid "Update modules" msgstr "更新模块" -#: menu.sh:1817 +#: menu.sh:1804 msgid "Update LKMs" msgstr "更新LKMs" -#: menu.sh:1819 +#: menu.sh:1806 msgid "Set proxy server" msgstr "设置代理" -#: menu.sh:1821 +#: menu.sh:1808 msgid "Local upload" msgstr "本地上传" -#: menu.sh:1822 +#: menu.sh:1809 msgid "Pre Release:" msgstr "预发布: " -#: menu.sh:1831 menu.sh:1854 +#: menu.sh:1818 menu.sh:1841 msgid "addons" msgstr "插件" -#: menu.sh:1834 menu.sh:1861 +#: menu.sh:1821 menu.sh:1848 msgid "modules" msgstr "模块" -#: menu.sh:1837 menu.sh:1868 +#: menu.sh:1824 menu.sh:1855 msgid "LKMs" msgstr "LKMs" -#: menu.sh:1840 menu.sh:1847 +#: menu.sh:1827 menu.sh:1834 msgid "RR" msgstr "RR" -#: menu.sh:1877 menu.sh:1888 menu.sh:1899 menu.sh:1909 menu.sh:1926 -#: menu.sh:1940 +#: menu.sh:1864 menu.sh:1875 menu.sh:1886 menu.sh:1896 menu.sh:1913 +#: menu.sh:1927 msgid "Update" msgstr "更新" -#: menu.sh:1878 +#: menu.sh:1865 msgid "Please enter a proxy server url" -msgstr "请输入代理服务器url" +msgstr "请输入代理服务器 url" -#: menu.sh:1889 +#: menu.sh:1876 msgid "Invalid proxy server url, continue?" -msgstr "无效的代理服务器url, 是否继续?" +msgstr "无效的代理服务器 url, 是否继续?" -#: menu.sh:1904 +#: menu.sh:1891 msgid "" "Please keep the attachment name consistent with the attachment name on " "Github.\\n" msgstr "请保持附件名称与 github 上附件名称一致.\\n" -#: menu.sh:1905 +#: menu.sh:1892 msgid "Upload update.zip will update RR.\\n" msgstr "上传 update.zip 将更新 RR.\\n" -#: menu.sh:1906 +#: menu.sh:1893 msgid "Upload addons.zip will update Addons.\\n" msgstr "上传 addons.zip 将更新 插件.\\n" -#: menu.sh:1907 +#: menu.sh:1894 msgid "Upload modules.zip will update Modules.\\n" msgstr "上传 modules.zip 将更新 模块.\\n" -#: menu.sh:1908 +#: menu.sh:1895 msgid "Upload rp-lkms.zip will update LKMs.\\n" msgstr "上传 rp-lkms.zip 将更新 LKMs.\\n" -#: menu.sh:1957 +#: menu.sh:1944 msgid "This person is very lazy and hasn't written anything." msgstr "这个人很懒, 什么也没有写." -#: menu.sh:1958 +#: menu.sh:1945 msgid "Edit" msgstr "编辑" -#: menu.sh:1975 +#: menu.sh:1962 msgid "Choose a model" msgstr "选择型号" -#: menu.sh:1977 +#: menu.sh:1964 msgid "Choose a version" msgstr "选择版本" -#: menu.sh:1979 +#: menu.sh:1966 msgid "Addons menu" msgstr "插件" -#: menu.sh:1980 +#: menu.sh:1967 msgid "Modules menu" msgstr "模块" -#: menu.sh:1981 +#: menu.sh:1968 msgid "Cmdline menu" -msgstr "设置Cmdline" +msgstr "设置 Cmdline" -#: menu.sh:1982 +#: menu.sh:1969 msgid "Synoinfo menu" -msgstr "设置Synoinfo" +msgstr "设置 Synoinfo" -#: menu.sh:1985 +#: menu.sh:1972 msgid "Advanced menu" msgstr "高级设置" -#: menu.sh:1988 +#: menu.sh:1975 msgid "Build the loader" msgstr "编译引导" -#: menu.sh:1992 +#: menu.sh:1979 msgid "Boot the loader" msgstr "启动" -#: menu.sh:1995 +#: menu.sh:1982 msgid "Choose a keymap" msgstr "选择键盘" -#: menu.sh:1997 +#: menu.sh:1984 msgid "Clean disk cache" msgstr "清除磁盘缓存" -#: menu.sh:1999 +#: menu.sh:1986 msgid "Update menu" msgstr "更新" -#: menu.sh:2000 +#: menu.sh:1987 msgid "Notepad" msgstr "备注" -#: menu.sh:2004 -msgid "Main menu" -msgstr "主菜单" - -#: menu.sh:2068 +#: menu.sh:2056 msgid "Choose a action" msgstr "选择动作" -#: menu.sh:2069 +#: menu.sh:2057 msgid "Poweroff" msgstr "关机" -#: menu.sh:2070 +#: menu.sh:2058 msgid "Reboot" msgstr "重启" -#: menu.sh:2071 +#: menu.sh:2059 msgid "Reboot to RR" -msgstr "重启到RR" +msgstr "重启到 RR" -#: menu.sh:2072 +#: menu.sh:2060 msgid "Back to shell" -msgstr "退出到shell" +msgstr "退出到 shell" -#: menu.sh:2098 +#: menu.sh:2086 msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" msgstr "执行 \\033[1;32mmenu.sh\\033[0m 重新进入设置菜单" diff --git a/files/initrd/opt/rr/lang/zh_HK.po b/files/initrd/opt/rr/lang/zh_HK.po index 80ddb45c..f1f9e613 100644 --- a/files/initrd/opt/rr/lang/zh_HK.po +++ b/files/initrd/opt/rr/lang/zh_HK.po @@ -1,14 +1,14 @@ -# Chinese translations for rr package. -# Copyright (C) 2023 THE rr'S COPYRIGHT HOLDER -# This file is distributed under the same license as the rr package. +# Chinese translations for RR package. +# Copyright (C) 2023 THE RR'S COPYRIGHT HOLDER +# This file is distributed under the same license as the RR package. # ing , 2023. # msgid "" msgstr "" -"Project-Id-Version: rr\n" +"Project-Id-Version: RR\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2023-10-09 17:39+0800\n" -"PO-Revision-Date: 2023-10-09 17:39+0800\n" +"POT-Creation-Date: 2023-10-25 17:37+0800\n" +"PO-Revision-Date: 2023-10-25 17:38+0800\n" "Last-Translator: ing \n" "Language-Team: Chinese (HongKong) \n" "Language: zh_HK\n" @@ -16,205 +16,188 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -#: boot.sh:8 init.sh:160 +#: boot.sh:8 init.sh:8 menu.sh:9 +msgid "Loader is not init!" +msgstr "引導未初始化!" + +#: boot.sh:10 init.sh:101 msgid "Loader is not configured!" msgstr "引導未設置!" -#: boot.sh:20 init.sh:41 +#: boot.sh:20 init.sh:13 msgid "Welcome to %s" msgstr "Welcome to %s" -#: boot.sh:38 +#: boot.sh:33 msgid "DSM zImage changed" msgstr "DSM zImage 已變更" -#: boot.sh:41 boot.sh:54 menu.sh:817 menu.sh:825 menu.sh:851 menu.sh:880 -#: menu.sh:892 menu.sh:916 menu.sh:924 menu.sh:975 menu.sh:988 menu.sh:995 +#: boot.sh:36 boot.sh:49 menu.sh:819 menu.sh:827 menu.sh:853 menu.sh:882 +#: menu.sh:894 menu.sh:918 menu.sh:926 menu.sh:958 menu.sh:975 menu.sh:982 msgid "Error" msgstr "錯誤" -#: boot.sh:42 menu.sh:989 +#: boot.sh:37 menu.sh:976 msgid "" "zImage not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" msgstr "zImage patch 失敗,\\n請升級引導版本並重試.\\nPatch 錯誤:\\n" -#: boot.sh:51 +#: boot.sh:46 msgid "DSM Ramdisk changed" msgstr "DSM Ramdisk 已變更" -#: boot.sh:55 menu.sh:996 +#: boot.sh:50 menu.sh:983 msgid "" "Ramdisk not patched,\\nPlease upgrade the bootloader version and try again." "\\nPatch error:\\n" msgstr "Ramdisk patch 失敗,\\n請升級引導版本並重試.\\nPatch 錯誤:\\n" -#: boot.sh:73 +#: boot.sh:68 msgid "Model:" msgstr "型號: " -#: boot.sh:74 +#: boot.sh:69 msgid "Build:" msgstr "版本: " -#: boot.sh:75 +#: boot.sh:70 msgid "LKM: " msgstr "LKM: " -#: boot.sh:76 +#: boot.sh:71 msgid "DMI: " msgstr "DMI: " -#: boot.sh:77 +#: boot.sh:72 msgid "CPU: " msgstr "CPU: " -#: boot.sh:78 +#: boot.sh:73 msgid "MEM: " msgstr "MEM: " -#: boot.sh:81 +#: boot.sh:76 msgid "" "The current version of bootloader does not support booting %s-%s, please " "upgrade and rebuild." msgstr "當前版本的開機磁碟不支持引導 %s-%s, 請升級並重新編譯." -#: boot.sh:93 +#: boot.sh:88 msgid "" -"Please insert at least one sata disk for system installation, except for the " -"bootloader disk." -msgstr "除引導盤外, 請至少插入一塊 sata 磁片進行系統安裝." +"Please insert at least one sata/scsi disk for system installation, except " +"for the bootloader disk." +msgstr "除引導盤外, 請至少插入一塊 sata/scsi 磁片進行系統安裝." -#: boot.sh:142 +#: boot.sh:149 msgid "Cmdline:\\n" msgstr "Cmdline:\\n" -#: boot.sh:148 +#: boot.sh:155 msgid "Reboot to boot directly in DSM" -msgstr "重啓並直接進入DSM引導" +msgstr "重啓並直接進入 DSM 引導" -#: boot.sh:154 init.sh:173 +#: boot.sh:161 init.sh:114 msgid "Detected %s network cards." msgstr "檢測到 %s 個網卡." -#: boot.sh:155 init.sh:174 +#: boot.sh:162 init.sh:115 msgid "Checking Connect." msgstr "檢查連接." -#: boot.sh:175 +#: boot.sh:182 msgid "Waiting IP.(For reference only)" msgstr "獲取 IP.(僅供參考)" -#: boot.sh:182 init.sh:199 +#: boot.sh:189 init.sh:140 msgid "DOWN" msgstr "關閉" -#: boot.sh:186 init.sh:203 +#: boot.sh:193 init.sh:144 msgid "NOT CONNECTED" msgstr "未連接" -#: boot.sh:190 init.sh:207 +#: boot.sh:197 init.sh:148 msgid "TIMEOUT (Please check the IP on the router.)" -msgstr "超時 (請檢查路由器上的IP.)" +msgstr "超時 (請檢查路由器上的 IP.)" -#: boot.sh:196 +#: boot.sh:203 msgid "Access \\033[1;34mhttp://%s:5000\\033[0m to connect the DSM via web." msgstr "在瀏覽器中訪問 \\033[1;34mhttp://%s:5000\\033[0m 連結 DSM." -#: boot.sh:208 +#: boot.sh:215 msgid "%2ds (Changing access(ssh/web) status will interrupt boot)" msgstr "%2ds ((ssh/web)链接状态改變將中斷啟動)" -#: boot.sh:212 +#: boot.sh:219 msgid "access(ssh/web) status has changed and booting is interrupted." msgstr "(ssh/web)链接狀態已改變, 啟動被中斷." -#: boot.sh:222 +#: boot.sh:229 msgid "Loading DSM kernel..." msgstr "加載 DSM kernel..." -#: boot.sh:226 +#: boot.sh:242 msgid "Warning, running kexec with --noefi param, strange things will happen!!" msgstr "警告, 使用'--noefi'參數運行'kexec', 可能有不好的事情發生!!" -#: boot.sh:231 +#: boot.sh:247 msgid "Booting..." msgstr "引導中..." -#: boot.sh:233 +#: boot.sh:249 msgid "" -"[This interface will not be operational.\\nPlease wait for a few minutes " -"before using the http://find.synology.com/ or Synology Assistant find DSM " -"and connect.]" -msgstr "[該介面已不可操作.\\n請在數分鐘後通過 http://find.synology.com/ 或者 Synology Assistant 查找DSM並連結.]" +"[This interface will not be operational. Please wait a few minutes.\\nFind " +"DSM via http://find.synology.com/ or Synology Assistant and connect.]" +msgstr "[該介面已不可操作. 請在數分鐘後\\n通過 http://find.synology.com/ 或者 Synology Assistant 查找 DSM 並連結.]" -#: init.sh:17 -msgid "Loader disk not found!" -msgstr "引導磁碟未找到!" - -#: init.sh:19 -msgid "Loader disk seems to be damaged!" -msgstr "引導磁碟似乎已損壞!" - -#: init.sh:20 -msgid "There are multiple loader disks, please insert only one loader disk!" -msgstr "存在多個引導磁碟, 請僅插入一個引導磁碟!" - -#: init.sh:32 init.sh:33 init.sh:34 -msgid "Can't mount %s" -msgstr "掛載 %s 失敗" - -#: init.sh:72 +#: init.sh:22 msgid "Network devices not found!" msgstr "網卡未找到!" -#: init.sh:127 -msgid "Loader disk neither USB or DoM" -msgstr "引導磁碟僅支持 USB 或者 DoM" +#: init.sh:78 +msgid "Loader disk neither USB or SATA/SCSI/NVME DoM" +msgstr "引導磁碟僅支持 USB 或者 SATA/SCSI/NVME DoM" -#: init.sh:135 +#: init.sh:86 msgid "Loader disk:" msgstr "引導盤:" -#: init.sh:142 -msgid "Resizing %s" -msgstr "重置 %s 大小" - -#: init.sh:153 +#: init.sh:94 msgid "Loading keymap" -msgstr "加載keymap" +msgstr "加載 keymap" -#: init.sh:163 +#: init.sh:104 msgid "User requested edit settings." msgstr "用戶觸發編輯設定." -#: init.sh:192 +#: init.sh:133 msgid "Waiting IP." msgstr "獲取 IP." -#: init.sh:213 +#: init.sh:154 msgid "" "Access \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via web " "terminal." -msgstr "在瀏覽器中訪問 \\033[1;34mhttp://%s:7681\\033[0m 進入WEB終端進行配寘." +msgstr "在瀏覽器中訪問 \\033[1;34mhttp://%s:7681\\033[0m 進入 WEB 終端進行配寘." -#: init.sh:223 +#: init.sh:164 msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" msgstr "執行 \\033[1;32mmenu.sh\\033[0m 進入設定選單" -#: init.sh:225 +#: init.sh:166 msgid "User config is on" msgstr "用戶設定檔位於" -#: init.sh:226 +#: init.sh:167 msgid "Default SSH Root password is" -msgstr "默認SSH的root密碼為" +msgstr "默認 SSH 的 root 密碼為" -#: init.sh:232 +#: init.sh:181 msgid "" "You have less than 4GB of RAM, if errors occur in loader creation, please " "increase the amount of memory." -msgstr "您的RAM不足4GB, 如果在創建引導時出現錯誤, 請新增記憶體." +msgstr "您的 RAM 不足 4GB, 如果在創建引導時出現錯誤, 請新增記憶體." #: menu.sh:89 msgid "Model" @@ -224,18 +207,18 @@ msgstr "型號" msgid "Reading models" msgstr "讀取型號" -#: menu.sh:120 +#: menu.sh:100 +msgid "Compatibility judgment" +msgstr "相容性判斷" + +#: menu.sh:121 msgid "Disable flags restriction" msgstr "禁用標誌限制" -#: menu.sh:121 +#: menu.sh:122 msgid "Show all models" msgstr "顯示所有型號" -#: menu.sh:122 -msgid "Compatibility judgment" -msgstr "相容性判斷" - #: menu.sh:124 msgid "Choose the model" msgstr "選擇型號" @@ -251,33 +234,33 @@ msgstr "版本" #: menu.sh:223 msgid "" "The current version has been set to %s. Do you want to reset the version?" -msgstr "當前版本已設定為%s. 是否要重置版本?" +msgstr "當前版本已設定為 %s. 是否要重置版本?" #: menu.sh:229 msgid "" "This version does not support UEFI startup, Please select another version or " "switch the startup mode." -msgstr "該版本不支持UEFI啟動, 請選擇其他版本或者切換啟動模式." +msgstr "該版本不支持 UEFI 啟動, 請選擇其他版本或者切換啟動模式." #: menu.sh:234 msgid "" "This version only support usb startup, Please select another version or " "switch the startup mode." -msgstr "該版本僅支持 usb 啟動, 請選擇其他版本或者切換啟動模式." +msgstr "該版本僅支持 USB 啟動, 請選擇其他版本或者切換啟動模式." #: menu.sh:240 -msgid "Get pat data .." -msgstr "獲取pat數據 .." +msgid "Get pat data ..." +msgstr "獲取 pat 數據 ..." #: menu.sh:259 msgid "" "Failed to get pat data,\\nPlease manually fill in the URL and md5sum of the " "corresponding version of pat." -msgstr "獲取pat數據失敗,\\n請手動填寫相應版本pat的URL和MD5." +msgstr "獲取 pat 數據失敗,\\n請手動填寫相應版本 pat 的 URL 和 MD5." #: menu.sh:263 msgid "Successfully to get pat data,\\nPlease confirm or modify as needed." -msgstr "獲取pat數據成功,\\n請確認或者按需修改." +msgstr "獲取 pat 數據成功,\\n請確認或者按需修改." #: menu.sh:266 msgid "Retry" @@ -287,7 +270,7 @@ msgstr "重試" msgid "Reconfiguring Synoinfo, Addons and Modules" msgstr "重新配寘 Syninfo, 挿件和模塊" -#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1826 +#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1813 msgid "Choose a option" msgstr "設定" @@ -311,8 +294,8 @@ msgstr "顯示所有可用挿件" msgid "Upload a external addon" msgstr "上傳外部挿件" -#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1049 menu.sh:1823 -#: menu.sh:2001 menu.sh:2073 +#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1036 menu.sh:1810 +#: menu.sh:1988 menu.sh:2061 msgid "Exit" msgstr "退出" @@ -342,15 +325,15 @@ msgstr "沒有要删除的用戶挿件" msgid "Select addon to remove" msgstr "選擇要删除的挿件" -#: menu.sh:416 menu.sh:1368 menu.sh:1399 menu.sh:1432 menu.sh:1900 +#: menu.sh:416 menu.sh:1355 menu.sh:1386 menu.sh:1419 menu.sh:1887 msgid "This feature is only available when accessed via web/ssh." -msgstr "此功能僅通過web/ssh訪問時可用." +msgstr "此功能僅通過 web/ssh 訪問時可用." #: menu.sh:420 msgid "Please upload the *.addons file." msgstr "請上傳 *.addons 檔案." -#: menu.sh:434 menu.sh:572 menu.sh:1927 menu.sh:1941 +#: menu.sh:434 menu.sh:572 menu.sh:1914 menu.sh:1928 msgid "Not a valid file, please try again!" msgstr "不是有效的檔案, 請重試!" @@ -450,11 +433,11 @@ msgstr "模塊 '%s' 已添加到 %s-%s" #: menu.sh:593 msgid "Add/edit a cmdline item" -msgstr "添加/編輯cmdline參數" +msgstr "添加/編輯 cmdline 參數" #: menu.sh:594 msgid "Delete cmdline item(s)" -msgstr "删除cmdline參數(s)" +msgstr "删除 cmdline 參數(s)" #: menu.sh:596 msgid "Define SN/MAC" @@ -462,11 +445,11 @@ msgstr "自定義 SN/MAC" #: menu.sh:598 msgid "Show user added cmdline" -msgstr "顯示用戶添加的cmdline參數" +msgstr "顯示用戶添加的 cmdline 參數" #: menu.sh:599 msgid "Show model inherent cmdline" -msgstr "顯示型號默認的cmdline參數" +msgstr "顯示型號默認的 cmdline 參數" #: menu.sh:609 menu.sh:615 menu.sh:625 menu.sh:633 menu.sh:649 menu.sh:659 #: menu.sh:688 menu.sh:696 @@ -483,7 +466,7 @@ msgstr "輸入 '%s' 參數的值" #: menu.sh:626 msgid "No user cmdline to remove" -msgstr "沒有用戶參數被删除" +msgstr "沒有 cmdline 參數被删除" #: menu.sh:634 msgid "Select cmdline to remove" @@ -499,15 +482,15 @@ msgstr "隨機" #: menu.sh:660 msgid "Invalid SN/MAC, retry?" -msgstr "無效 SN/MAC, 重試?" +msgstr "無效的 SN/MAC, 重試?" #: menu.sh:713 msgid "Add/edit a synoinfo item" -msgstr "添加/編輯Synoinfo參數" +msgstr "添加/編輯 Synoinfo 參數" #: menu.sh:714 msgid "Delete synoinfo item(s)" -msgstr "删除Synoinfo參數(s)" +msgstr "删除 Synoinfo 參數(s)" #: menu.sh:715 msgid "Show synoinfo entries" @@ -533,646 +516,652 @@ msgstr "沒有 Synoinfo 參數被删除" msgid "Select synoinfo entry to remove" msgstr "選擇要删除的參數" -#: menu.sh:791 +#: menu.sh:792 msgid "%s cached." msgstr "%s 已緩存." -#: menu.sh:795 +#: menu.sh:796 msgid "Cleaning cache" msgstr "清除緩存" -#: menu.sh:802 +#: menu.sh:804 msgid "" "Based on the current network situation, switch to %s mirror to downloading." msgstr "根據當前的網絡狀況, 已切換到 %s 鏡像伺服器進行下載." -#: menu.sh:806 +#: menu.sh:808 msgid "Downloading %s" msgstr "下載 %s 中" -#: menu.sh:816 menu.sh:879 +#: menu.sh:818 menu.sh:881 msgid "Check internet or cache disk space.\\nError: %d" -msgstr "請檢查internet或磁碟空間.\\nError: %d" +msgstr "請檢查網際網路或磁碟空間.\\n錯誤: %d" -#: menu.sh:823 +#: menu.sh:825 msgid "Checking hash of %s: " msgstr "檢查 %s 的 hash: " -#: menu.sh:826 -msgid "md5 hash of pat not match, Please reget pat data from the version menu and try again!" -msgstr "pat 的 md5 Hash 不匹配, 請在版本選單中重新獲取pat數據後重試!" +#: menu.sh:828 +msgid "" +"md5 hash of pat not match, Please reget pat data from the version menu and " +"try again!" +msgstr "pat 的 md5 Hash 不匹配, 請在版本選單中重新獲取 pat 數據後重試!" -#: menu.sh:830 menu.sh:933 menu.sh:943 +#: menu.sh:832 menu.sh:935 menu.sh:945 msgid "OK" msgstr "OK" -#: menu.sh:834 +#: menu.sh:836 msgid "Disassembling %s: " -msgstr "解壓 %s: " +msgstr "解壓縮 %s: " -#: menu.sh:839 +#: menu.sh:841 msgid "Uncompressed tar" msgstr "未壓縮 tar" -#: menu.sh:843 +#: menu.sh:845 msgid "Compressed tar" -msgstr "壓縮 tar" +msgstr "已壓縮 tar" -#: menu.sh:847 +#: menu.sh:849 msgid "Encrypted" msgstr "已加密" -#: menu.sh:852 +#: menu.sh:854 msgid "" "Could not determine if pat file is encrypted or not, maybe corrupted, try " "again!" -msgstr "無法確定pat檔案是否加密, 可能已損壞, 請重試!" +msgstr "無法確定 pat 檔案是否加密, 可能已損壞, 請重試!" -#: menu.sh:862 +#: menu.sh:864 msgid "Extractor cached." msgstr "已存在解密程式." -#: menu.sh:869 +#: menu.sh:871 msgid "Downloading old pat to extract synology .pat extractor..." msgstr "下載舊 pat, 選取 .pat 解密程式中..." -#: menu.sh:910 menu.sh:913 +#: menu.sh:912 menu.sh:915 msgid "Extracting..." msgstr "解壓中..." -#: menu.sh:925 +#: menu.sh:927 msgid "pat Invalid, try again!" msgstr "無效的 pat, 請重試!" -#: menu.sh:928 +#: menu.sh:930 msgid "Setting hash: " msgstr "設定 hash: " -#: menu.sh:935 +#: menu.sh:937 msgid "Copying files: " msgstr "拷貝檔案: " -#: menu.sh:976 +#: menu.sh:959 msgid "Addon %s not found!" msgstr "挿件 %s 未找到!" -#: menu.sh:1002 menu.sh:2052 +#: menu.sh:989 menu.sh:2040 msgid "Cleaning" msgstr "清除中" -#: menu.sh:1004 +#: menu.sh:991 msgid "Ready!" msgstr "已就绪!" -#: menu.sh:1017 +#: menu.sh:1004 msgid "Switch LKM version:" -msgstr "選擇LKM版本:" +msgstr "選擇 LKM 版本:" -#: menu.sh:1020 +#: menu.sh:1007 msgid "Switch direct boot:" msgstr "切換直接啟動:" -#: menu.sh:1022 +#: menu.sh:1009 msgid "Timeout of get ip in boot:" msgstr "啟動時取得 IP 的超時時間:" -#: menu.sh:1023 +#: menu.sh:1010 msgid "Timeout of boot wait:" msgstr "啟動超時時間:" -#: menu.sh:1024 +#: menu.sh:1011 msgid "kernel switching method:" msgstr "內核切換的管道:" -#: menu.sh:1025 +#: menu.sh:1013 msgid "Reboot on kernel panic:" msgstr "內核恐慌時重新啟動:" -#: menu.sh:1028 +#: menu.sh:1015 msgid "Set static IP" msgstr "設定靜態 IP" -#: menu.sh:1029 +#: menu.sh:1016 msgid "Edit user config file manually" msgstr "編輯用戶設定檔" -#: menu.sh:1030 +#: menu.sh:1017 msgid "Edit grub.cfg file manually" msgstr "編輯 grub.cfg" -#: menu.sh:1031 +#: menu.sh:1018 msgid "Try to recovery a DSM installed system" -msgstr "嘗試恢復已安裝DSM的系統" +msgstr "嘗試恢復已安裝 DSM 的系統" -#: menu.sh:1032 +#: menu.sh:1019 msgid "Show SATA(s) # ports and drives" -msgstr "顯示SATA(s) # 埠和驅動器" +msgstr "顯示 SATA(s) # 埠和驅動器" -#: menu.sh:1034 +#: menu.sh:1021 msgid "show/modify the current pat data" -msgstr "顯示/修改當前pat下載連結" +msgstr "顯示/修改當前 pat 下載連結" -#: menu.sh:1036 +#: menu.sh:1023 msgid "Allow downgrade installation" msgstr "允許降級安裝" -#: menu.sh:1037 +#: menu.sh:1024 msgid "Format disk(s) # Without loader disk" msgstr "格式化磁碟(s) # 不含開機磁碟" -#: menu.sh:1038 +#: menu.sh:1025 msgid "Reset DSM system password" msgstr "重置 DSM 系統密碼" -#: menu.sh:1039 +#: menu.sh:1026 msgid "Save modifications of '/opt/rr'" msgstr "保存'/opt/rr'的修改" -#: menu.sh:1041 +#: menu.sh:1028 msgid "Custom dts file # Need rebuild" msgstr "自定義dts檔案 # 需要重新編譯" -#: menu.sh:1044 +#: menu.sh:1031 msgid "Backup bootloader disk # test" msgstr "備份開機磁碟 # 測試" -#: menu.sh:1045 +#: menu.sh:1032 msgid "Restore bootloader disk # test" msgstr "恢復開機磁碟 # 測試" -#: menu.sh:1047 +#: menu.sh:1034 msgid "Install development tools" msgstr "安裝開發者工具" -#: menu.sh:1048 -msgid "Show dsm logo:" -msgstr "顯示 dsm logo:" +#: menu.sh:1035 +msgid "Show QR logo:" +msgstr "顯示 QR logo:" -#: menu.sh:1051 menu.sh:1069 menu.sh:1081 menu.sh:1101 menu.sh:1124 -#: menu.sh:1148 menu.sh:1212 menu.sh:1219 menu.sh:1237 menu.sh:1250 -#: menu.sh:1253 menu.sh:1263 menu.sh:1264 menu.sh:1269 menu.sh:1273 -#: menu.sh:1284 menu.sh:1286 menu.sh:1303 menu.sh:1308 menu.sh:1316 -#: menu.sh:1322 menu.sh:1335 menu.sh:1338 menu.sh:1344 menu.sh:1347 -#: menu.sh:1362 menu.sh:1367 menu.sh:1371 menu.sh:1386 menu.sh:1391 -#: menu.sh:1398 menu.sh:1402 menu.sh:1405 menu.sh:1410 menu.sh:1420 -#: menu.sh:1425 menu.sh:1431 menu.sh:1435 menu.sh:1452 menu.sh:1455 -#: menu.sh:1461 menu.sh:1469 menu.sh:1477 menu.sh:1486 menu.sh:1488 +#: menu.sh:1038 menu.sh:1056 menu.sh:1068 menu.sh:1088 menu.sh:1111 +#: menu.sh:1135 menu.sh:1199 menu.sh:1206 menu.sh:1224 menu.sh:1237 +#: menu.sh:1240 menu.sh:1250 menu.sh:1251 menu.sh:1256 menu.sh:1260 +#: menu.sh:1271 menu.sh:1273 menu.sh:1290 menu.sh:1295 menu.sh:1303 +#: menu.sh:1309 menu.sh:1322 menu.sh:1325 menu.sh:1331 menu.sh:1334 +#: menu.sh:1349 menu.sh:1354 menu.sh:1358 menu.sh:1373 menu.sh:1378 +#: menu.sh:1385 menu.sh:1389 menu.sh:1392 menu.sh:1397 menu.sh:1407 +#: menu.sh:1412 menu.sh:1418 menu.sh:1422 menu.sh:1439 menu.sh:1442 +#: menu.sh:1448 menu.sh:1456 menu.sh:1464 menu.sh:1471 menu.sh:1473 msgid "Advanced" msgstr "高級" -#: menu.sh:1052 +#: menu.sh:1039 msgid "Advanced option" msgstr "高級設定" -#: menu.sh:1070 menu.sh:1082 menu.sh:1102 +#: menu.sh:1057 menu.sh:1069 menu.sh:1089 msgid "Choose a time(seconds)" msgstr "選擇一個時間(秒)" -#: menu.sh:1112 +#: menu.sh:1099 msgid "Temporary IP: (UI will not refresh)" msgstr "臨時 IP: (UI 不會重繪)" -#: menu.sh:1149 +#: menu.sh:1136 msgid "Setting IP ..." -msgstr "設定 IP.." +msgstr "設定 IP..." -#: menu.sh:1210 +#: menu.sh:1197 msgid "\\nTotal of ports: %s\\n" msgstr "\\n埠總數: %s\\n" -#: menu.sh:1211 +#: menu.sh:1198 msgid "" "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " "connected." msgstr "\\n\\Z1红色\\Zn 為類比埠, \\Z2\\Zb绿色\\Zn 為已驅動的物理埠." -#: menu.sh:1218 +#: menu.sh:1205 msgid "pat: (editable)" msgstr "pat: (可編輯)" -#: menu.sh:1234 +#: menu.sh:1221 msgid "" "This feature will allow you to downgrade the installation by removing the " "VERSION file from the first partition of all disks.\\n" -msgstr "此功能通過删除所有磁碟的第一個分區的VERSION檔案來允許你降級安裝.\\n" +msgstr "此功能通過删除所有磁碟的第一個分區的 VERSION 檔案來允許你降級安裝.\\n" -#: menu.sh:1235 +#: menu.sh:1222 msgid "Therefore, please insert all disks before continuing.\\n" msgstr "囙此, 請插入所有磁碟後再進行操作.\\n" -#: menu.sh:1236 menu.sh:1270 +#: menu.sh:1223 menu.sh:1257 msgid "" "Warning:\\nThis operation is irreversible. Please backup important data. Do " "you want to continue?" msgstr "警告:\\n該操作不可逆, 請提前備份重要數據. 是否繼續?" -#: menu.sh:1251 +#: menu.sh:1238 msgid "Removing ..." msgstr "删除中..." -#: menu.sh:1252 +#: menu.sh:1239 msgid "Remove VERSION file for all disks completed." msgstr "已移除所有磁碟的 VERSION 檔案." -#: menu.sh:1274 +#: menu.sh:1261 msgid "" "Warning:\\nThe current hds is in raid, do you still want to format them?" -msgstr "警告:\\n當前的硬碟處於raid中, 是否仍要格式化?" +msgstr "警告:\\n當前的硬碟處於 raid 中, 是否仍要格式化?" -#: menu.sh:1285 +#: menu.sh:1272 msgid "Formatting ..." msgstr "格式化中..." -#: menu.sh:1287 +#: menu.sh:1274 msgid "Formatting is complete." msgstr "格式化完成." -#: menu.sh:1304 +#: menu.sh:1291 msgid "The installed Syno system not found in the currently inserted disks!" -msgstr "未在當前插入的硬碟中找到已安裝的syno系統!" +msgstr "未在當前插入的硬碟中找到已安裝的 syno 系統!" -#: menu.sh:1309 +#: menu.sh:1296 msgid "Choose a user name" msgstr "選擇一個用戶" -#: menu.sh:1317 +#: menu.sh:1304 msgid "Type a new password for user '%s'" msgstr "輸入用戶 '%s' 的新密碼" -#: menu.sh:1323 +#: menu.sh:1310 msgid "Invalid password" msgstr "無效密碼" -#: menu.sh:1336 +#: menu.sh:1323 msgid "Resetting ..." msgstr "重置中 ..." -#: menu.sh:1339 +#: menu.sh:1326 msgid "Password reset completed." msgstr "重置密碼完成." -#: menu.sh:1345 menu.sh:1403 menu.sh:1456 +#: menu.sh:1332 menu.sh:1390 menu.sh:1443 msgid "" -"Warning:\\nDo not terminate midway, otherwise it may cause damage to the " -"RR. Do you want to continue?" -msgstr "警告:\\n請不要中途停止, 否則將導致RR引導損毀, 是否繼續?" +"Warning:\\nDo not terminate midway, otherwise it may cause damage to the RR. " +"Do you want to continue?" +msgstr "警告:\\n請不要中途停止, 否則將導致 RR 引導損毀, 是否繼續?" -#: menu.sh:1348 +#: menu.sh:1335 msgid "Saving ..." msgstr "保存中..." -#: menu.sh:1363 +#: menu.sh:1350 msgid "Save is complete." msgstr "保存完成." -#: menu.sh:1372 +#: menu.sh:1359 msgid "" "Currently, only dts format files are supported. Please prepare and click to " "confirm uploading.\\n(saved in /mnt/p3/users/)" msgstr "" -"現時, 只支持dts格式的檔案, 請準備並點擊確認上傳.\\n(保存於 /mnt/p3/users/ 中)" +"現時, 只支持 dts 格式的檔案, 請準備並點擊確認上傳.\\n(保存於 /mnt/p3/users/ 中)" -#: menu.sh:1387 +#: menu.sh:1374 msgid "Not a valid dts file, please try again!" msgstr "dts 檔案無效, 請重試!" -#: menu.sh:1392 +#: menu.sh:1379 msgid "A valid dts file, Automatically import at compile time." msgstr "dts 檔案有效, 將在編譯時自動導入." -#: menu.sh:1406 +#: menu.sh:1393 msgid "Backuping..." msgstr "備份中..." -#: menu.sh:1411 +#: menu.sh:1398 msgid "" "Failed to generate backup. There may be insufficient memory. Please clear " "the cache and try again!" msgstr "生成備份失敗, 可能記憶體不足, 請清除緩存重試!" -#: menu.sh:1418 +#: menu.sh:1405 msgid "Click on the address above to download." msgstr "點擊上面的地址下載." -#: menu.sh:1419 +#: menu.sh:1406 msgid "" "Please confirm the completion of the download before closing this window." msgstr "請確認下載完成再關閉此視窗." -#: menu.sh:1426 +#: menu.sh:1413 msgid "backup is complete." msgstr "備份完成." -#: menu.sh:1436 +#: menu.sh:1423 msgid "" "Please upload the backup file.\\nCurrently, zip(github) and img.gz(backup) " "compressed file formats are supported." msgstr "請上傳備份的檔案\\n當前支持 zip(github) 和 img.gz(backup) 格式." -#: menu.sh:1453 +#: menu.sh:1440 msgid "Not a valid .zip/.img.gz file, please try again!" -msgstr "不是有效的.zip/.img.gz檔案, 請重試!" +msgstr "不是有效的 .zip/.img.gz 檔案, 請重試!" -#: menu.sh:1462 +#: menu.sh:1449 msgid "Writing..." msgstr "寫入中..." -#: menu.sh:1470 +#: menu.sh:1457 msgid "Restore bootloader disk with success to %s!\\nReboot?" msgstr "成功恢復開機磁碟到 %s!\\n重啓?" -#: menu.sh:1478 +#: menu.sh:1465 msgid "" "This option only installs opkg package management, allowing you to install " "more tools for use and debugging. Do you want to continue?" msgstr "" "該選項僅安裝 opkg 包管理工具, 使你能够安裝更多的工具以供使用和調試, 是否繼續?" -#: menu.sh:1487 +#: menu.sh:1472 msgid "opkg installing ..." msgstr "opkg 安裝中 ..." -#: menu.sh:1489 +#: menu.sh:1474 msgid "" "opkg install is complete. Please reconnect to SSH/web, or execute 'source ~/." "bashrc'" msgstr "opkg 安裝完成. 請重新連結 SSH/web, 或者執行 'source ~/.bashrc'" -#: menu.sh:1504 menu.sh:1541 menu.sh:1548 +#: menu.sh:1489 menu.sh:1526 menu.sh:1533 msgid "Try recovery DSM" -msgstr "嘗試恢復DSM系統" +msgstr "嘗試恢復 DSM 系統" -#: menu.sh:1505 +#: menu.sh:1490 msgid "Trying to recovery a DSM installed system" -msgstr "嘗試恢復已安裝的DSM系統中" +msgstr "嘗試恢復已安裝的 DSM 系統中" -#: menu.sh:1531 +#: menu.sh:1516 msgid "Found a installation:\\nModel: %s\\nProductversion: %s" msgstr "找到已安裝:\\n型號: %s\\n版本: %s" -#: menu.sh:1535 +#: menu.sh:1520 msgid "\\nSerial: %s" msgstr "\\nSN: %s" -#: menu.sh:1549 +#: menu.sh:1534 msgid "Unfortunately I couldn't mount the DSM partition!" -msgstr "很遺憾, 我無法掛載DSM分區!" +msgstr "很遺憾, 我無法掛載 DSM 分區!" -#: menu.sh:1557 menu.sh:1563 menu.sh:1586 +#: menu.sh:1542 menu.sh:1548 menu.sh:1571 msgid "Edit with caution" msgstr "請謹慎編輯" -#: menu.sh:1597 +#: menu.sh:1582 msgid "Alert" msgstr "警告" -#: menu.sh:1598 +#: menu.sh:1583 msgid "Config changed, would you like to rebuild the loader?" msgstr "配寘已更改, 是否重新編譯引導?" -#: menu.sh:1610 menu.sh:1994 -msgid "Choose a language" -msgstr "選擇語言" - -#: menu.sh:1624 -msgid "Choose a layout" -msgstr "選擇佈局" - -#: menu.sh:1636 -msgid "Choice a keymap" -msgstr "選擇鍵盤" - -#: menu.sh:1655 menu.sh:1708 menu.sh:1759 menu.sh:1831 menu.sh:1834 -#: menu.sh:1837 menu.sh:1840 menu.sh:1847 menu.sh:1854 menu.sh:1861 -#: menu.sh:1868 -msgid "Update %s" -msgstr "更新 %s" - -#: menu.sh:1658 -msgid "Checking last version" -msgstr "檢測新版本中" - -#: menu.sh:1671 menu.sh:1674 -msgid "Error checking new version" -msgstr "檢測新版本錯誤" - -#: menu.sh:1681 -msgid "No new version." -msgstr "沒有新版本." - -#: menu.sh:1685 -msgid "No new version. Actual version is %s\\nForce update?" -msgstr "沒有新版本. 實際版本為 %s\\n強制更新?" - -#: menu.sh:1690 -msgid "Downloading last version" -msgstr "下載新版本中" - -#: menu.sh:1696 menu.sh:1699 -msgid "Error downloading new version" -msgstr "下載新版本錯誤" - -#: menu.sh:1710 menu.sh:1761 -msgid "Extracting last version" -msgstr "解壓新版本" - -#: menu.sh:1714 -msgid "Error extracting update file" -msgstr "更新檔案解壓錯誤" - -#: menu.sh:1721 -msgid "Checksum do not match!" -msgstr "Checksum不匹配!" - -#: menu.sh:1730 -msgid "" -"The current version does not support upgrading to the latest update.zip. " -"Please remake the bootloader disk!" -msgstr "當前版本不支持最新的update.zip陞級, 請重新製作引導盤!" - -#: menu.sh:1735 -msgid "Installing new files" -msgstr "安裝更新中" - -#: menu.sh:1752 -msgid "RR updated with success to %s!\\nReboot?" -msgstr "RR更新成功 %s!\\n重啓?" - -#: menu.sh:1767 -msgid "Installing new %s" -msgstr "安裝新 %s 中" - -#: menu.sh:1796 menu.sh:1799 -msgid "%s updated with success!" -msgstr "%s 更新成功!" - -#: menu.sh:1813 -msgid "Update all" -msgstr "更新所有" - -#: menu.sh:1814 -msgid "Update RR" -msgstr "更新RR" - -#: menu.sh:1815 -msgid "Update addons" -msgstr "更新挿件" - -#: menu.sh:1816 -msgid "Update modules" -msgstr "更新模塊" - -#: menu.sh:1817 -msgid "Update LKMs" -msgstr "更新LKMs" - -#: menu.sh:1819 -msgid "Set proxy server" -msgstr "設定代理" - -#: menu.sh:1821 -msgid "Local upload" -msgstr "本地上傳" - -#: menu.sh:1822 -msgid "Pre Release:" -msgstr "預發佈: " - -#: menu.sh:1831 menu.sh:1854 -msgid "addons" -msgstr "挿件" - -#: menu.sh:1834 menu.sh:1861 -msgid "modules" -msgstr "模塊" - -#: menu.sh:1837 menu.sh:1868 -msgid "LKMs" -msgstr "LKMs" - -#: menu.sh:1840 menu.sh:1847 -msgid "RR" -msgstr "RR" - -#: menu.sh:1877 menu.sh:1888 menu.sh:1899 menu.sh:1909 menu.sh:1926 -#: menu.sh:1940 -msgid "Update" -msgstr "更新" - -#: menu.sh:1878 -msgid "Please enter a proxy server url" -msgstr "請輸入代理伺服器url" - -#: menu.sh:1889 -msgid "Invalid proxy server url, continue?" -msgstr "無效的代理伺服器url, 是否繼續?" - -#: menu.sh:1904 -msgid "" -"Please keep the attachment name consistent with the attachment name on " -"Github.\\n" -msgstr "請保持附件名稱與github上附件名稱一致.\\n" - -#: menu.sh:1905 -msgid "Upload update.zip will update RR.\\n" -msgstr "上傳 update.zip 将更新 RR.\\n" - -#: menu.sh:1906 -msgid "Upload addons.zip will update Addons.\\n" -msgstr "上傳 addons.zip 将更新 挿件.\\n" - -#: menu.sh:1907 -msgid "Upload modules.zip will update Modules.\\n" -msgstr "上傳 modules.zip 将更新 模塊.\\n" - -#: menu.sh:1908 -msgid "Upload rp-lkms.zip will update LKMs.\\n" -msgstr "上傳 rp-lkms.zip 将更新 LKMs.\\n" - -#: menu.sh:1957 -msgid "This person is very lazy and hasn't written anything." -msgstr "這個人很懶, 什麼也沒有寫." - -#: menu.sh:1958 -msgid "Edit" -msgstr "編輯" - -#: menu.sh:1975 -msgid "Choose a model" -msgstr "選擇型號" - -#: menu.sh:1977 -msgid "Choose a version" -msgstr "選擇版本" - -#: menu.sh:1979 -msgid "Addons menu" -msgstr "挿件" - -#: menu.sh:1980 -msgid "Modules menu" -msgstr "模塊" - -#: menu.sh:1981 -msgid "Cmdline menu" -msgstr "設定 Cmdline" - -#: menu.sh:1982 -msgid "Synoinfo menu" -msgstr "設定 Synoinfo" - -#: menu.sh:1985 -msgid "Advanced menu" -msgstr "高級設定" - -#: menu.sh:1988 -msgid "Build the loader" -msgstr "編譯引導" - -#: menu.sh:1992 -msgid "Boot the loader" -msgstr "啟動" - -#: menu.sh:1995 -msgid "Choose a keymap" -msgstr "選擇鍵盤" - -#: menu.sh:1997 -msgid "Clean disk cache" -msgstr "清除磁碟緩存" - -#: menu.sh:1999 -msgid "Update menu" -msgstr "更新" - -#: menu.sh:2000 -msgid "Notepad" -msgstr "備註" - -#: menu.sh:2004 +#: menu.sh:1585 menu.sh:1991 menu.sh:2024 msgid "Main menu" msgstr "主選單" -#: menu.sh:2068 +#: menu.sh:1586 menu.sh:2025 +msgid "Making ..." +msgstr "編譯中 ..." + +#: menu.sh:1596 menu.sh:1981 +msgid "Choose a language" +msgstr "選擇語言" + +#: menu.sh:1610 +msgid "Choose a layout" +msgstr "選擇佈局" + +#: menu.sh:1622 +msgid "Choice a keymap" +msgstr "選擇鍵盤" + +#: menu.sh:1641 menu.sh:1695 menu.sh:1746 menu.sh:1818 menu.sh:1821 +#: menu.sh:1824 menu.sh:1827 menu.sh:1834 menu.sh:1841 menu.sh:1848 +#: menu.sh:1855 +msgid "Update %s" +msgstr "更新 %s" + +#: menu.sh:1644 +msgid "Checking last version" +msgstr "檢測新版本中" + +#: menu.sh:1657 menu.sh:1660 +msgid "Error checking new version" +msgstr "檢測新版本錯誤" + +#: menu.sh:1667 +msgid "No new version." +msgstr "沒有新版本." + +#: menu.sh:1671 +msgid "No new version. Actual version is %s\\nForce update?" +msgstr "沒有新版本. 實際版本為 %s\\n強制更新?" + +#: menu.sh:1679 +msgid "Downloading ..." +msgstr "下載中 ..." + +#: menu.sh:1683 menu.sh:1686 +msgid "Error downloading new version" +msgstr "下載新版本錯誤" + +#: menu.sh:1697 menu.sh:1748 +msgid "Extracting last version" +msgstr "解壓新版本" + +#: menu.sh:1701 +msgid "Error extracting update file" +msgstr "更新檔案解壓錯誤" + +#: menu.sh:1708 +msgid "Checksum do not match!" +msgstr "Checksum 不匹配!" + +#: menu.sh:1717 +msgid "" +"The current version does not support upgrading to the latest update.zip. " +"Please remake the bootloader disk!" +msgstr "當前版本不支持最新的 update.zip 陞級, 請重新製作引導盤!" + +#: menu.sh:1722 +msgid "Installing new files" +msgstr "安裝更新中" + +#: menu.sh:1739 +msgid "RR updated with success to %s!\\nReboot?" +msgstr "RR 更新成功 %s!\\n重啓?" + +#: menu.sh:1754 +msgid "Installing new %s" +msgstr "安裝新 %s 中" + +#: menu.sh:1783 menu.sh:1786 +msgid "%s updated with success!" +msgstr "%s 更新成功!" + +#: menu.sh:1800 +msgid "Update all" +msgstr "更新全部" + +#: menu.sh:1801 +msgid "Update RR" +msgstr "更新 RR " + +#: menu.sh:1802 +msgid "Update addons" +msgstr "更新挿件" + +#: menu.sh:1803 +msgid "Update modules" +msgstr "更新模塊" + +#: menu.sh:1804 +msgid "Update LKMs" +msgstr "更新LKMs" + +#: menu.sh:1806 +msgid "Set proxy server" +msgstr "設定代理" + +#: menu.sh:1808 +msgid "Local upload" +msgstr "本地上傳" + +#: menu.sh:1809 +msgid "Pre Release:" +msgstr "預發佈:" + +#: menu.sh:1818 menu.sh:1841 +msgid "addons" +msgstr "挿件" + +#: menu.sh:1821 menu.sh:1848 +msgid "modules" +msgstr "模塊" + +#: menu.sh:1824 menu.sh:1855 +msgid "LKMs" +msgstr "LKMs" + +#: menu.sh:1827 menu.sh:1834 +msgid "RR" +msgstr "RR" + +#: menu.sh:1864 menu.sh:1875 menu.sh:1886 menu.sh:1896 menu.sh:1913 +#: menu.sh:1927 +msgid "Update" +msgstr "更新" + +#: menu.sh:1865 +msgid "Please enter a proxy server url" +msgstr "請輸入代理伺服器 url" + +#: menu.sh:1876 +msgid "Invalid proxy server url, continue?" +msgstr "無效的代理伺服器 url, 是否繼續?" + +#: menu.sh:1891 +msgid "" +"Please keep the attachment name consistent with the attachment name on " +"Github.\\n" +msgstr "請保持附件名稱與 github 上附件名稱一致.\\n" + +#: menu.sh:1892 +msgid "Upload update.zip will update RR.\\n" +msgstr "上傳 update.zip 将更新 RR.\\n" + +#: menu.sh:1893 +msgid "Upload addons.zip will update Addons.\\n" +msgstr "上傳 addons.zip 将更新 挿件.\\n" + +#: menu.sh:1894 +msgid "Upload modules.zip will update Modules.\\n" +msgstr "上傳 modules.zip 将更新 模塊.\\n" + +#: menu.sh:1895 +msgid "Upload rp-lkms.zip will update LKMs.\\n" +msgstr "上傳 rp-lkms.zip 将更新 LKMs.\\n" + +#: menu.sh:1944 +msgid "This person is very lazy and hasn't written anything." +msgstr "這個人很懶, 什麼也沒有寫." + +#: menu.sh:1945 +msgid "Edit" +msgstr "編輯" + +#: menu.sh:1962 +msgid "Choose a model" +msgstr "選擇型號" + +#: menu.sh:1964 +msgid "Choose a version" +msgstr "選擇版本" + +#: menu.sh:1966 +msgid "Addons menu" +msgstr "挿件" + +#: menu.sh:1967 +msgid "Modules menu" +msgstr "模塊" + +#: menu.sh:1968 +msgid "Cmdline menu" +msgstr "設定 Cmdline" + +#: menu.sh:1969 +msgid "Synoinfo menu" +msgstr "設定 Synoinfo" + +#: menu.sh:1972 +msgid "Advanced menu" +msgstr "高級設定" + +#: menu.sh:1975 +msgid "Build the loader" +msgstr "編譯引導" + +#: menu.sh:1979 +msgid "Boot the loader" +msgstr "啟動" + +#: menu.sh:1982 +msgid "Choose a keymap" +msgstr "選擇鍵盤" + +#: menu.sh:1984 +msgid "Clean disk cache" +msgstr "清除磁碟緩存" + +#: menu.sh:1986 +msgid "Update menu" +msgstr "更新" + +#: menu.sh:1987 +msgid "Notepad" +msgstr "備註" + +#: menu.sh:2056 msgid "Choose a action" msgstr "選擇動作" -#: menu.sh:2069 +#: menu.sh:2057 msgid "Poweroff" msgstr "關機" -#: menu.sh:2070 +#: menu.sh:2058 msgid "Reboot" msgstr "重啓" -#: menu.sh:2071 +#: menu.sh:2059 msgid "Reboot to RR" -msgstr "重啓到RR" +msgstr "重啓到 RR" -#: menu.sh:2072 +#: menu.sh:2060 msgid "Back to shell" -msgstr "退出到shell" +msgstr "退出到 shell" -#: menu.sh:2098 +#: menu.sh:2086 msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" msgstr "執行 \\033[1;32mmenu.sh\\033[0m 重新進入設定選單" diff --git a/files/initrd/opt/rr/lang/zh_TW.po b/files/initrd/opt/rr/lang/zh_TW.po index c34e2530..26eb88e5 100644 --- a/files/initrd/opt/rr/lang/zh_TW.po +++ b/files/initrd/opt/rr/lang/zh_TW.po @@ -1,14 +1,14 @@ -# Chinese translations for rr package. -# Copyright (C) 2023 THE rr'S COPYRIGHT HOLDER -# This file is distributed under the same license as the rr package. +# Chinese translations for RR package. +# Copyright (C) 2023 THE RR'S COPYRIGHT HOLDER +# This file is distributed under the same license as the RR package. # March Fun , 2023. # msgid "" msgstr "" -"Project-Id-Version: rr\n" +"Project-Id-Version: RR\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: \n" -"PO-Revision-Date: 2023-10-13 13:15+0800\n" +"POT-Creation-Date: 2023-10-25 17:37+0800\n" +"PO-Revision-Date: 2023-10-25 17:58+0800\n" "Last-Translator: March Fun \n" "Language-Team: Chinese (Taiwan) \n" "Language: zh_TW\n" @@ -17,833 +17,1156 @@ msgstr "" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 3.4\n" -msgid "%2ds (Changing access(ssh/web) status will interrupt boot)" -msgstr "%2ds (變更存取 (ssh/web) 狀態將中斷開機)" - -msgid "%s cached." -msgstr "%s 已快取。" - -msgid "%s updated with success!" -msgstr "%s 更新成功!" - -msgid "'Not set MACs' is enabled." -msgstr "'不設定 MACs' 已啟用。" - -msgid "access(ssh/web) status has changed and booting is interrupted." -msgstr "存取 (ssh/web) 狀態已變更,開機已中斷。" - -msgid "A valid dts file, Automatically import at compile time." -msgstr "dts 檔案有效,將在編譯時自動匯入。" - -msgid "Access \\033[1;34mhttp://%s:5000\\033[0m to connect the DSM via web." -msgstr "在瀏覽器中瀏覽 \\033[1;34mhttp://%s:5000\\033[0m 連線 DSM。" - -msgid "Access \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via web terminal." -msgstr "在瀏覽器中瀏覽 \\033[1;34mhttp://%s:7681\\033[0m 進入 WEB 終端進行設置。" - -msgid "Add an addon" -msgstr "加入增益集" - -msgid "Add/edit a cmdline item" -msgstr "加入/編輯 cmdline 參數" - -msgid "Add/edit a synoinfo item" -msgstr "加入/編輯 Synoinfo 參數" - -msgid "Addon %s not found!" -msgstr "增益集 %s 未找到!" - -msgid "Addon '%s' added to loader, Please enable it in 'Add an addon' menu." -msgstr "增益集 '%s' 已加入到開機中,請在「加入增益集」選單中開啟。" - -msgid "Addons" -msgstr "增益集" - -msgid "Addons menu" -msgstr "增益集功能表" - -msgid "Advanced" -msgstr "進階" - -msgid "Advanced menu" -msgstr "進階功能表" - -msgid "Alert" -msgstr "警告" - -msgid "Allow downgrade installation" -msgstr "允許降級安裝" - -msgid "RR updated with success to %s!\\nReboot?" -msgstr "RR 更新成功 %s!\\n重新開機?" - -msgid "Back to shell" -msgstr "退回到 shell" - -msgid "Backup bootloader disk # test" -msgstr "備份開機碟 # 測試" - -msgid "Backuping..." -msgstr "備份中..." - -msgid "Based on the current network situation, switch to %s mirror to downloading." -msgstr "根據目前的網路狀況,已切換到 %s 鏡像伺服器進行下載。" - -msgid "Boot the loader" -msgstr "開機" - -msgid "Booting..." -msgstr "開機中..." - -msgid "Build the loader" -msgstr "編譯開機檔" - -msgid "Build:" -msgstr "版本:" - -msgid "CPU: " -msgstr "CPU: " - -msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" -msgstr "執行 \\033[1;32mmenu.sh\\033[0m 進入設定選單" - -msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" -msgstr "執行 \\033[1;32mmenu.sh\\033[0m 重新進入設定選單" - -msgid "Can't mount %s" -msgstr "掛載 %s 失敗" - -msgid "Changing MAC" -msgstr "修改 MAC" - -msgid "Check internet or cache disk space.\\nError: %d" -msgstr "請檢查網際網路或快取磁碟空間。\\n錯誤: %d" - -msgid "Checking Connect." -msgstr "檢查連線。" - -msgid "Checking hash of %s: " -msgstr "檢查 %s 的雜湊值: " - -msgid "Checking last version" -msgstr "檢測新版本中" - -msgid "Checksum do not match!" -msgstr "總和檢查碼不相符!" - -msgid "Choice a keymap" -msgstr "選擇鍵盤" - -msgid "Choose a action" -msgstr "選擇動作" - -msgid "Choose a keymap" -msgstr "選擇鍵盤" - -msgid "Choose a language" -msgstr "選擇語言" - -msgid "Choose a layout" -msgstr "選擇佈局" - -msgid "Choose a model" -msgstr "選擇型號" - -msgid "Choose a option" -msgstr "選擇選項" - -msgid "Choose a product version" -msgstr "選擇產品版本" - -msgid "Choose a user name" -msgstr "選擇使用者" - -msgid "Choose a version" -msgstr "選擇版本" - -msgid "Choose a time(seconds)" -msgstr "選擇一個時間 (秒)" - -msgid "Choose modules to include" -msgstr "選擇要載入的模組" - -msgid "Choose the model" -msgstr "選擇型號" - -msgid "Advanced option" -msgstr "進階選項" - -msgid "Clean disk cache" -msgstr "清除磁碟快取" - -msgid "Cleaning" -msgstr "清除中" - -msgid "Cleaning cache" -msgstr "清除快取" - -msgid "Click on the address above to download." -msgstr "點選上面的位址下載。" - -msgid "Cmdline" -msgstr "Cmdline" - -msgid "Cmdline menu" -msgstr "設定 Cmdline" - -msgid "Cmdline:\\n" -msgstr "Cmdline:\\n" - -msgid "Compatibility judgment" -msgstr "相容性判斷" - -msgid "Compressed tar" -msgstr "壓縮 tar" - -msgid "Config changed, would you like to rebuild the loader?" -msgstr "設置已變更,是否重新編譯開機檔?" - -msgid "Continue to custom MAC?" -msgstr "繼續自訂 MAC?" - -msgid "Copying files: " -msgstr "複製檔案: " - -msgid "Could not determine if pat file is encrypted or not, maybe corrupted, try again!" -msgstr "無法確定 pat 檔案是否加密,可能已損壞,請重試!" - -msgid "Currently, only dts format files are supported. Please prepare and click to confirm uploading.\\n(saved in /mnt/p3/users/)" -msgstr "目前只支援 dts 格式的檔案,請準備並點選確認上傳。\\n(儲存於 /mnt/p3/users/ 中)" - -msgid "Custom dts file # Need rebuild" -msgstr "自訂 dts 檔案 # 需要重新編譯" - -msgid "DMI: " -msgstr "DMI: " - -msgid "DOWN" -msgstr "關機" - -msgid "DSM Ramdisk changed" -msgstr "DSM Ramdisk 已變更" - -msgid "DSM zImage changed" -msgstr "DSM zImage 已變更" - -msgid "Default SSH Root password is" -msgstr "預設 SSH 的 root 密碼為" - -msgid "Define a custom MAC" -msgstr "自訂 MAC" - -msgid "Define a serial number" -msgstr "自訂 SN" - -msgid "Delete addon(s)" -msgstr "删除增益集" - -msgid "Delete cmdline item(s)" -msgstr "删除 cmdline 參數" - -msgid "Delete synoinfo item(s)" -msgstr "删除 Synoinfo 參數" - -msgid "Deselect all" -msgstr "全部不選" - -msgid "Detected %s network cards, %s MACs were customized, the rest will use the original MACs." -msgstr "檢測到 %s 個網路卡, 自訂了 %s 個 MAC,其他網路卡將使用本身 MAC。" - -msgid "Detected %s network cards." -msgstr "檢測到 %s 個網路卡。" - -msgid "Disable flags restriction" -msgstr "停用標誌限制" - -msgid "Disassembling %s: " -msgstr "解壓縮 %s: " - -msgid "Do you want to continue?" -msgstr "是否繼續?" - -msgid "Downloading %s" -msgstr "下載 %s 中" - -msgid "Downloading last version" -msgstr "下載新版本中" - -msgid "Downloading old pat to extract synology .pat extractor..." -msgstr "下載舊 pat,選取 .pat 解密程式中..." - -msgid "Edit" -msgstr "編輯" - -msgid "Edit grub.cfg file manually" -msgstr "手動編輯 grub.cfg" - -msgid "Edit user config file manually" -msgstr "手動編輯使用者設定檔" - -msgid "Edit with caution" -msgstr "請謹慎編輯" - -msgid "Encrypted" -msgstr "已加密" - -msgid "Error" -msgstr "錯誤" - -msgid "Error checking new version" -msgstr "檢測新版本錯誤" - -msgid "Error downloading new version" -msgstr "下載新版本錯誤" - -msgid "Error extracting update file" -msgstr "更新檔案解壓錯誤" - -msgid "Exit" -msgstr "退出" - -msgid "Extracting last version" -msgstr "解壓新版本" - -msgid "Extracting..." -msgstr "解壓中..." - -msgid "Extractor cached." -msgstr "已存在解密程式。" - -msgid "Failed to generate backup. There may be insufficient memory. Please clear the cache and try again!" -msgstr "產生備份失敗,可能記憶體不足,請清除快取後重試!" - -msgid "Failed to get pat data,\\nPlease manually fill in the URL and md5sum of the corresponding version of pat." -msgstr "取得 pat 資料失敗,\\n請手動填寫相對版本 pat 的 URL 和 MD5。" - -msgid "File format not recognized!" -msgstr "檔案格式無法識別!" - -msgid "Format disk(s) # Without loader disk" -msgstr "格式化磁碟(s) # 不含開機碟" - -msgid "Formatting ..." -msgstr "格式化中..." - -msgid "Formatting is complete." -msgstr "格式化完成。" - -msgid "Found a installation:\\nModel: %s\\nProductversion: %s" -msgstr "找到已安裝:\\n型號: %s\\n版本: %s" - -msgid "Get pat data .." -msgstr "取得 pat 資料 .." - -msgid "If you want to remove it, please go to the \"Update Menu\" -> \"Update modules\" to forcibly update the modules. All imports will be reset.\\n" -msgstr "如果您想删除它,請前往「更新 -> 更新模組」強制更新模組。所有匯入都將被重設。\\n" - -msgid "Install development tools" -msgstr "安裝開發者工具" - -msgid "Installing new %s" -msgstr "安裝新 %s 中" - -msgid "Installing new files" -msgstr "安裝更新中" - -msgid "Invalid MAC" -msgstr "無效的 MAC" - -msgid "Invalid password" -msgstr "無效的密碼" - -msgid "Invalid proxy server url, continue?" -msgstr "無效的代理伺服器網址,是否繼續?" - -msgid "Invalid serial, continue?" -msgstr "SN 無效,是否繼續?" - -msgid "LKM: " -msgstr "LKM: " - -msgid "LKMs" -msgstr "LKMs" - -msgid "Loader disk neither USB or DoM" -msgstr "開機碟僅支援 USB 或者 DoM" - -msgid "Loader disk not found!" -msgstr "未找到開機碟!" - -msgid "Loader disk seems to be damaged!" -msgstr "開機碟似乎已損壞!" - -msgid "Loader disk:" -msgstr "開機碟:" +#: boot.sh:8 init.sh:8 menu.sh:9 +msgid "Loader is not init!" +msgstr "開機碟未初始化!" +#: boot.sh:10 init.sh:101 msgid "Loader is not configured!" msgstr "開機檔未設置!" -msgid "Loading DSM kernel..." -msgstr "載入 DSM 核心..." - -msgid "Loading keymap" -msgstr "載入 keymap" - -msgid "Local upload" -msgstr "本地上傳" - -msgid "Main menu" -msgstr "主功能表" - -msgid "MEM: " -msgstr "MEM: " - -msgid "Model" -msgstr "型號" - -msgid "Model:" -msgstr "型號:" - -msgid "Module '%s' added to %s-%s" -msgstr "模組 '%s' 已加入到 %s-%s" - -msgid "Modules" -msgstr "模組" - -msgid "Modules menu" -msgstr "模組功能表" - -msgid "NOT CONNECTED" -msgstr "未連線" - -msgid "Network devices not found!" -msgstr "未找到網路卡!" - -msgid "No available addons to add" -msgstr "沒有可用的增益集可加入" - -msgid "No new version." -msgstr "沒有新版本。" - -msgid "No new version. Actual version is %s\\nForce update?" -msgstr "沒有新版本。實際版本為 %s\\n強制更新?" - -msgid "No synoinfo entries to remove" -msgstr "沒有 Synoinfo 參數被删除" - -msgid "No user addons to remove" -msgstr "沒有要删除的使用者增益集" - -msgid "No user cmdline to remove" -msgstr "沒有使用者 cmdline 被删除" - -msgid "Not a valid .zip/.img.gz file, please try again!" -msgstr "不是有效的.zip/.img.gz 檔案,請重試!" - -msgid "Not a valid dts file, please try again!" -msgstr "dts 檔案無效,請重試!" - -msgid "Not a valid file, please try again!" -msgstr "不是有效的檔案,請重試!" - -msgid "Notepad" -msgstr "記事本" - -msgid "OK" -msgstr "OK" - -msgid "Password reset completed." -msgstr "重設密碼完成。" - -msgid "Please confirm the completion of the download before closing this window." -msgstr "請確認下載完成再關閉此視窗。" - -msgid "Please enter a proxy server url" -msgstr "請輸入代理伺服器網址" - -msgid "Please enter a serial number " -msgstr "請輸入 SN " - -msgid "Please insert at least one sata disk for system installation, except for the bootloader disk." -msgstr "除了開機碟之外,請至少插入一個 sata 磁碟以進行系統安裝。" - -msgid "Please keep the attachment name consistent with the attachment name on Github.\\n" -msgstr "請保持附件名稱與 github 上附件名稱一致。\\n" - -msgid "Please upload the *.addons file." -msgstr "請上傳 *.addons 檔案。" - -msgid "Please upload the *.ko file." -msgstr "請上傳 *.ko 檔案。" - -msgid "Please upload the backup file.\\nCurrently, zip(github) and img.gz(backup) compressed file formats are supported." -msgstr "請上傳備份的檔案\\n目前支援 zip(github) 和 img.gz(backup) 格式。" - -msgid "Poweroff" -msgstr "關機" - -msgid "Pre Release:" -msgstr "預發佈:" - -msgid "Priority use of official drivers:" -msgstr "優先使用官方驅動程式:" - -msgid "Product Version" -msgstr "產品版本" - -msgid "Ramdisk not patched,\\nPlease upgrade the bootloader version and try again.\\nPatch error:\\n" -msgstr "Ramdisk 未修補,\\n請升級開機載入程式版本然後重試。\\n修補錯誤:\\n" - -msgid "Reading models" -msgstr "讀取型號" - -msgid "Reading modules" -msgstr "讀取模組中" - -msgid "Ready!" -msgstr "已就绪!" - -msgid "Reboot" -msgstr "重新開機" - -msgid "Reboot on kernel panic:" -msgstr "核心崩潰時重新啟動:" - -msgid "Reboot to RR" -msgstr "重新開機並進入RR" - -msgid "Reboot to boot directly in DSM" -msgstr "重新開機以直接啟動 DSM" - -msgid "Reconfiguring Synoinfo, Addons and Modules" -msgstr "重新設置 Syninfo、增益集和模組" - -msgid "Remove VERSION file for all disks completed." -msgstr "已移除所有磁碟的 VERSION 檔案。" - -msgid "Removing ..." -msgstr "移除中..." - -msgid "Renewing IP" -msgstr "更新 IP" - -msgid "Reset DSM system password" -msgstr "重設 DSM 系統密碼" - -msgid "Resetting ..." -msgstr "重設中 ..." - -msgid "Resizing %s" -msgstr "重設 %s 大小" - -msgid "Restore bootloader disk # test" -msgstr "回復開機碟 # 測試" - -msgid "Restore bootloader disk with success to %s!\\nReboot?" -msgstr "成功回復開機碟到 %s!\\n重新開機?" - -msgid "Retry" -msgstr "重試" - -msgid "Save is complete." -msgstr "儲存完成。" - -msgid "Save modifications of '/opt/rr'" -msgstr "儲存「/opt/rr」的修改" - -msgid "Saving ..." -msgstr "儲存中..." - -msgid "Select addon to remove" -msgstr "選擇要删除的增益集" - -msgid "Select all" -msgstr "全選" - -msgid "Select an addon" -msgstr "選擇增益集" - -msgid "Select cmdline to remove" -msgstr "選擇要删除的參數" - -msgid "Select loaded modules" -msgstr "選擇已識別的模組" - -msgid "Select modules to include" -msgstr "選擇要載入的增益集" - -msgid "Select synoinfo entry to remove" -msgstr "選擇要删除的參數" - -msgid "Selecting loaded modules" -msgstr "選擇已識別的模組" - -msgid "Set proxy server" -msgstr "設定代理" - -msgid "Setting %s MAC to %s" -msgstr "設定 %s 的 MAC 為 %s" - -msgid "Setting IP ..." -msgstr "設定 IP..." - -msgid "Setting hash: " -msgstr "設定雜湊值: " - -msgid "Show SATA(s) # ports and drives" -msgstr "顯示 SATA # 埠和磁碟機" - -msgid "Show all available addons" -msgstr "顯示所有可用增益集" - -msgid "Show all models" -msgstr "顯示全部模組" - -msgid "Show dsm logo:" -msgstr "顯示 DSM 商標:" - -msgid "Show model inherent cmdline" -msgstr "顯示型號預設的 cmdline 參數" - -msgid "Show/Select modules" -msgstr "顯示/選擇模組" - -msgid "Show synoinfo entries" -msgstr "顯示 Synoinfo 參數" - -msgid "Show user added cmdline" -msgstr "顯示使用者加入的 cmdline 參數" - -msgid "Show user addons" -msgstr "顯示使用者增益集" - -msgid "Successfully to get pat data,\\nPlease confirm or modify as needed." -msgstr "取得 pat 資料成功,\\n請確認或者依需要修改。" - -msgid "Switch 'Do not set MACs':" -msgstr "切換「不設定 MAC」:" - -msgid "Switch LKM version:" -msgstr "切換 LKM 版本:" - -msgid "Switch direct boot:" -msgstr "切換直接開機:" - -msgid "Synoinfo" -msgstr "Synoinfo" - -msgid "Synoinfo menu" -msgstr "Synoinfo 功能表" - -msgid "TIMEOUT (Please check the IP on the router.)" -msgstr "逾時 (請檢查路由器上的IP.)" - -msgid "The addon already exists. Do you want to overwrite it?" -msgstr "該增益集已存在,是否覆寫?" - -msgid "The current version does not support upgrading to the latest update.zip. Please remake the bootloader disk!" -msgstr "目前版本不支援升級到最新的 update.zip,請重新製作開機碟!" - -msgid "The current version of bootloader does not support booting %s-%s, please upgrade and rebuild." -msgstr "目前版本的開機載入程式不支援啟動 %s-%s,請升級並重建。" - -msgid "The imported .ko of this function will be implanted into the corresponding arch's modules package, which will affect all models of the arch.\\n" -msgstr "該功能匯入 .ko 將植入相對架構的模組套件。這將影響該架構的所有型號。\\n" - -msgid "The installed Syno system not found in the currently inserted disks!" -msgstr "未在目前插入的硬碟中找到已安裝的 syno 系統!" - -msgid "There are multiple loader disks, please insert only one loader disk!" -msgstr "存在多個開機碟,請僅插入一個開機碟!" - -msgid "Therefore, please insert all disks before continuing.\\n" -msgstr "因此,請插入所有磁碟後再進行操作。\\n" - -msgid "This feature is only available when accessed via web/ssh." -msgstr "此功能僅在透過 web/ssh 存取時可用。" - -msgid "This feature will allow you to downgrade the installation by removing the VERSION file from the first partition of all disks.\\n" -msgstr "此功能透過删除所有磁碟第一個分區的 VERSION 檔案以允許你降級安裝。\\n" - -msgid "This function is experimental and dangerous. If you don't know much, please exit.\\n" -msgstr "該功能是實驗性質且具有風險,如果你不瞭解,請退出。\\n" - -msgid "This option only installs opkg package management, allowing you to install more tools for use and debugging. Do you want to continue?" -msgstr "該選項僅安裝 opkg 套件管理工具,讓你能够安裝更多的工具以供使用和除錯,是否繼續?" - -msgid "This person is very lazy and hasn't written anything." -msgstr "這個人很懶,什麼也沒有寫。" - -msgid "This program will not determine the availability of imported modules or even make type judgments, as please double check if it is correct.\\n" -msgstr "該程式不會判斷匯入的驅動模組的可用性,甚至不會做類型判斷,因此請再三確認是否正確。\\n" - -msgid "This version does not support UEFI startup, Please select another version or switch the startup mode." -msgstr "該版本不支援 UEFI 開機,請選擇其他版本或者切換開機模式。" - -msgid "This version only support usb startup, Please select another version or switch the startup mode." -msgstr "該版本僅支援 USB 開機,請選擇其他版本或者切換開機模式。" - -msgid "Timeout of boot wait:" -msgstr "開機逾時時間:" - -msgid "Timeout of get ip in boot:" -msgstr "開機時取得 IP 的逾時時間:" - -msgid "Try recovery DSM" -msgstr "嘗試回復 DSM 系統" - -msgid "Try to recovery a DSM installed system" -msgstr "嘗試回復已安裝 DSM 的系統" - -msgid "Trying to recovery a DSM installed system" -msgstr "嘗試回復已安裝的 DSM 系統中" - -msgid "Type a custom MAC address of %s" -msgstr "輸入 %s 的自訂 MAC 位址" - -msgid "Type a name of cmdline" -msgstr "輸入參數的名稱" - -msgid "Type a name of synoinfo entry" -msgstr "輸入參數的名稱" - -msgid "Type a new password for user '%s'" -msgstr "輸入使用者 '%s' 的新密碼" - -msgid "Type a optional params to addon" -msgstr "輸入增益集的選用參數" - -msgid "Type a value of '%s' cmdline" -msgstr "輸入 '%s' 參數的值" - -msgid "Type a value of '%s' synoinfo entry" -msgstr "輸入 '%s' 參數的值”" - -msgid "Uncompressed tar" -msgstr "未壓縮 tar" - -msgid "Unfortunately I couldn't mount the DSM partition!" -msgstr "很遺憾,無法掛載 DSM 分割區!" - -msgid "Update" -msgstr "更新" - -msgid "Update %s" -msgstr "更新 %s" - -msgid "Update LKMs" -msgstr "更新 LKM" - -msgid "Update addons" -msgstr "更新增益集" - -msgid "Update all" -msgstr "更新全部" - -msgid "Update RR" -msgstr "更新 RR" - -msgid "Update menu" -msgstr "更新功能表" - -msgid "Update modules" -msgstr "更新模組" - -msgid "Upload a external addon" -msgstr "上傳外部增益集" - -msgid "Upload a external module" -msgstr "上傳一個外部模組" - -msgid "Upload addons.zip will update Addons.\\n" -msgstr "上傳 addons.zip 將更新增益集。\\n" - -msgid "Upload modules.zip will update Modules.\\n" -msgstr "上傳 modules.zip 將更新模組。\\n" - -msgid "Upload rp-lkms.zip will update LKMs.\\n" -msgstr "上傳 rp-lkms.zip 將更新 LKM。\\n" - -msgid "Upload update.zip will update RR.\\n" -msgstr "上傳 update.zip 將更新 RR。\\n" - -msgid "User config is on" -msgstr "使用者設定已開啟" - -msgid "User requested edit settings." -msgstr "使用者要求編輯設定。" - -msgid "Waiting IP." -msgstr "正在取得 IP。" - -msgid "Waiting IP.(For reference only)" -msgstr "正在取得 IP (僅供參考)" - -msgid "Warning, running kexec with --noefi param, strange things will happen!!" -msgstr "警告,使用'--noefi'參數執行'kexec',可能有意外事情發生!" - -msgid "Warning:\\nDo not terminate midway, otherwise it may cause damage to the RR. Do you want to continue?" -msgstr "警告:\\n請不要中途停止,否則將導致 RR 開機損毀,是否繼續?" - -msgid "Warning:\\nThe current hds is in raid, do you still want to format them?" -msgstr "警告:\\n目前的硬碟使用 raid 中,是否仍要格式化?" - -msgid "Warning:\\nThis operation is irreversible. Please backup important data. Do you want to continue?" -msgstr "警告:\\n該作業不可逆,請提前備份重要資料。是否繼續?" - +#: boot.sh:20 init.sh:13 msgid "Welcome to %s" msgstr "歡迎使用 %s" -msgid "Writing..." -msgstr "寫入中..." +#: boot.sh:33 +msgid "DSM zImage changed" +msgstr "DSM zImage 已變更" -msgid "You have less than 4GB of RAM, if errors occur in loader creation, please increase the amount of memory." +#: boot.sh:36 boot.sh:49 menu.sh:819 menu.sh:827 menu.sh:853 menu.sh:882 +#: menu.sh:894 menu.sh:918 menu.sh:926 menu.sh:958 menu.sh:975 menu.sh:982 +msgid "Error" +msgstr "錯誤" + +#: boot.sh:37 menu.sh:976 +msgid "" +"zImage not patched,\\nPlease upgrade the bootloader version and try again." +"\\nPatch error:\\n" +msgstr "zImage 未修補,\\n請升級開機載入程式版本然後重試。\\n修補錯誤:\\n" + +#: boot.sh:46 +msgid "DSM Ramdisk changed" +msgstr "DSM Ramdisk 已變更" + +#: boot.sh:50 menu.sh:983 +msgid "" +"Ramdisk not patched,\\nPlease upgrade the bootloader version and try again." +"\\nPatch error:\\n" +msgstr "Ramdisk 未修補,\\n請升級開機載入程式版本然後重試。\\n修補錯誤:\\n" + +#: boot.sh:68 +msgid "Model:" +msgstr "型號: " + +#: boot.sh:69 +msgid "Build:" +msgstr "版本: " + +#: boot.sh:70 +msgid "LKM: " +msgstr "LKM: " + +#: boot.sh:71 +msgid "DMI: " +msgstr "DMI: " + +#: boot.sh:72 +msgid "CPU: " +msgstr "CPU: " + +#: boot.sh:73 +msgid "MEM: " +msgstr "MEM: " + +#: boot.sh:76 +msgid "" +"The current version of bootloader does not support booting %s-%s, please " +"upgrade and rebuild." +msgstr "目前版本的開機載入程式不支援啟動 %s-%s,請升級並重建。" + +#: boot.sh:88 +msgid "" +"Please insert at least one sata/scsi disk for system installation, except " +"for the bootloader disk." +msgstr "除了開機碟之外,請至少插入一個 sata/scsi 磁碟以進行系統安裝。" + +#: boot.sh:149 +msgid "Cmdline:\\n" +msgstr "Cmdline:\\n" + +#: boot.sh:155 +msgid "Reboot to boot directly in DSM" +msgstr "重新開機以直接啟動 DSM" + +#: boot.sh:161 init.sh:114 +msgid "Detected %s network cards." +msgstr "檢測到 %s 個網路卡。" + +#: boot.sh:162 init.sh:115 +msgid "Checking Connect." +msgstr "檢查連線。" + +#: boot.sh:182 +msgid "Waiting IP.(For reference only)" +msgstr "正在取得 IP (僅供參考)" + +#: boot.sh:189 init.sh:140 +msgid "DOWN" +msgstr "關機" + +#: boot.sh:193 init.sh:144 +msgid "NOT CONNECTED" +msgstr "未連線" + +#: boot.sh:197 init.sh:148 +msgid "TIMEOUT (Please check the IP on the router.)" +msgstr "逾時 (請檢查路由器上的IP.)" + +#: boot.sh:203 +msgid "Access \\033[1;34mhttp://%s:5000\\033[0m to connect the DSM via web." +msgstr "在瀏覽器中瀏覽 \\033[1;34mhttp://%s:5000\\033[0m 連線 DSM。" + +#: boot.sh:215 +msgid "%2ds (Changing access(ssh/web) status will interrupt boot)" +msgstr "%2ds (變更存取 (ssh/web) 狀態將中斷開機)" + +#: boot.sh:219 +msgid "access(ssh/web) status has changed and booting is interrupted." +msgstr "存取 (ssh/web) 狀態已變更,開機已中斷。" + +#: boot.sh:229 +msgid "Loading DSM kernel..." +msgstr "載入 DSM 核心..." + +#: boot.sh:242 +msgid "Warning, running kexec with --noefi param, strange things will happen!!" +msgstr "警告,使用'--noefi'參數執行'kexec',可能有意外事情發生!" + +#: boot.sh:247 +msgid "Booting..." +msgstr "開機中..." + +#: boot.sh:249 +msgid "" +"[This interface will not be operational. Please wait a few minutes.\\nFind " +"DSM via http://find.synology.com/ or Synology Assistant and connect.]" +msgstr "" +"[該介面已無法操作。請在數分鐘後\\n透過 http://find.synology.com/ 或者 " +"Synology Assistant 搜尋 DSM 並連線。]" + +#: init.sh:22 +msgid "Network devices not found!" +msgstr "未找到網路卡!" + +#: init.sh:78 +msgid "Loader disk neither USB or SATA/SCSI/NVME DoM" +msgstr "開機碟僅支援 USB 或者 SATA/SCSI/NVME DoM" + +#: init.sh:86 +msgid "Loader disk:" +msgstr "開機碟:" + +#: init.sh:94 +msgid "Loading keymap" +msgstr "載入 keymap" + +#: init.sh:104 +msgid "User requested edit settings." +msgstr "使用者要求編輯設定。" + +#: init.sh:133 +msgid "Waiting IP." +msgstr "正在取得 IP。" + +#: init.sh:154 +msgid "" +"Access \\033[1;34mhttp://%s:7681\\033[0m to configure the loader via web " +"terminal." +msgstr "" +"在瀏覽器中瀏覽 \\033[1;34mhttp://%s:7681\\033[0m 進入 WEB 終端進行設置。" + +#: init.sh:164 +msgid "Call \\033[1;32mmenu.sh\\033[0m to configure loader" +msgstr "執行 \\033[1;32mmenu.sh\\033[0m 進入設定選單" + +#: init.sh:166 +msgid "User config is on" +msgstr "使用者設定已開啟" + +#: init.sh:167 +msgid "Default SSH Root password is" +msgstr "預設 SSH 的 root 密碼為" + +#: init.sh:181 +msgid "" +"You have less than 4GB of RAM, if errors occur in loader creation, please " +"increase the amount of memory." msgstr "您的記憶體不足 4GB,如果在建立開機檔時出現錯誤,請增加記憶體。" -msgid "[This interface will not be operational.\\nPlease wait for a few minutes before using the http://find.synology.com/ or Synology Assistant find DSM and connect.]" -msgstr "[該介面已無法操作。\\n請在數分鐘後透過 http://find.synology.com/ 或者 Synology Assistant 搜尋 DSM 並連線。]" +#: menu.sh:89 +msgid "Model" +msgstr "型號" -msgid "\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive connected." -msgstr "\\n\\Z1紅色\\Zn 為類比埠,\\Z2\\Zb綠色\\Zn 為已驅動的物理埠。" +#: menu.sh:90 +msgid "Reading models" +msgstr "讀取型號" -msgid "\\nSerial: %s" -msgstr "\\nSN: %s" +#: menu.sh:100 +msgid "Compatibility judgment" +msgstr "相容性判斷" -msgid "\\nTotal of ports: %s\\n" -msgstr "\\n埠總數: %s\\n" +#: menu.sh:121 +msgid "Disable flags restriction" +msgstr "停用標誌限制" -msgid "addons" +#: menu.sh:122 +msgid "Show all models" +msgstr "顯示全部模組" + +#: menu.sh:124 +msgid "Choose the model" +msgstr "選擇型號" + +#: menu.sh:212 +msgid "Choose a product version" +msgstr "選擇產品版本" + +#: menu.sh:222 menu.sh:228 menu.sh:233 menu.sh:239 menu.sh:265 menu.sh:285 +msgid "Product Version" +msgstr "產品版本" + +#: menu.sh:223 +msgid "" +"The current version has been set to %s. Do you want to reset the version?" +msgstr "" + +#: menu.sh:229 +msgid "" +"This version does not support UEFI startup, Please select another version or " +"switch the startup mode." +msgstr "該版本不支援 UEFI 開機,請選擇其他版本或者切換開機模式。" + +#: menu.sh:234 +msgid "" +"This version only support usb startup, Please select another version or " +"switch the startup mode." +msgstr "該版本僅支援 USB 開機,請選擇其他版本或者切換開機模式。" + +#: menu.sh:240 +msgid "Get pat data ..." +msgstr "取得 pat 資料 ..." + +#: menu.sh:259 +msgid "" +"Failed to get pat data,\\nPlease manually fill in the URL and md5sum of the " +"corresponding version of pat." +msgstr "取得 pat 資料失敗,\\n請手動填寫相對版本 pat 的 URL 和 MD5。" + +#: menu.sh:263 +msgid "Successfully to get pat data,\\nPlease confirm or modify as needed." +msgstr "取得 pat 資料成功,\\n請確認或者依需要修改。" + +#: menu.sh:266 +msgid "Retry" +msgstr "重試" + +#: menu.sh:286 +msgid "Reconfiguring Synoinfo, Addons and Modules" +msgstr "重新設置 Syninfo、增益集和模組" + +#: menu.sh:329 menu.sh:467 menu.sh:604 menu.sh:721 menu.sh:1813 +msgid "Choose a option" +msgstr "選擇選項" + +#: menu.sh:330 +msgid "Add an addon" +msgstr "加入增益集" + +#: menu.sh:331 +msgid "Delete addon(s)" +msgstr "删除增益集" + +#: menu.sh:332 +msgid "Show user addons" +msgstr "顯示使用者增益集" + +#: menu.sh:333 +msgid "Show all available addons" +msgstr "顯示所有可用增益集" + +#: menu.sh:334 +msgid "Upload a external addon" +msgstr "上傳外部增益集" + +#: menu.sh:335 menu.sh:472 menu.sh:600 menu.sh:716 menu.sh:1036 menu.sh:1810 +#: menu.sh:1988 menu.sh:2061 +msgid "Exit" +msgstr "退出" + +#: menu.sh:347 menu.sh:352 menu.sh:358 menu.sh:370 menu.sh:378 menu.sh:396 +#: menu.sh:410 menu.sh:415 menu.sh:419 menu.sh:433 menu.sh:437 menu.sh:445 +#: menu.sh:448 +msgid "Addons" msgstr "增益集" -msgid "RR" -msgstr "RR" +#: menu.sh:348 +msgid "No available addons to add" +msgstr "沒有可用的增益集可加入" -msgid "backup is complete." -msgstr "備份完成。" +#: menu.sh:353 +msgid "Select an addon" +msgstr "選擇增益集" -msgid "kernel switching method:" -msgstr "核心切換方式:" +#: menu.sh:359 +msgid "Type a optional params to addon" +msgstr "輸入增益集的選用參數" -msgid "md5 hash of pat not match, Please reget pat data from the version menu and try again!" -msgstr "pat 的 md5 雜湊值不相符,請自版本功能表中重新取得 pat 資料並再試一次!" +#: menu.sh:371 +msgid "No user addons to remove" +msgstr "沒有要删除的使用者增益集" -msgid "modules" +#: menu.sh:379 +msgid "Select addon to remove" +msgstr "選擇要删除的增益集" + +#: menu.sh:416 menu.sh:1355 menu.sh:1386 menu.sh:1419 menu.sh:1887 +msgid "This feature is only available when accessed via web/ssh." +msgstr "此功能僅在透過 web/ssh 存取時可用。" + +#: menu.sh:420 +msgid "Please upload the *.addons file." +msgstr "請上傳 *.addons 檔案。" + +#: menu.sh:434 menu.sh:572 menu.sh:1914 menu.sh:1928 +msgid "Not a valid file, please try again!" +msgstr "不是有效的檔案,請重試!" + +#: menu.sh:438 +msgid "The addon already exists. Do you want to overwrite it?" +msgstr "該增益集已存在,是否覆寫?" + +#: menu.sh:446 +msgid "Addon '%s' added to loader, Please enable it in 'Add an addon' menu." +msgstr "增益集 '%s' 已加入到開機中,請在「加入增益集」選單中開啟。" + +#: menu.sh:449 +msgid "File format not recognized!" +msgstr "檔案格式無法識別!" + +#: menu.sh:468 +msgid "Show/Select modules" +msgstr "顯示/選擇模組" + +#: menu.sh:469 +msgid "Select loaded modules" +msgstr "選擇已識別的模組" + +#: menu.sh:470 +msgid "Upload a external module" +msgstr "上傳一個外部模組" + +#: menu.sh:471 +msgid "Priority use of official drivers:" +msgstr "優先使用官方驅動程式:" + +#: menu.sh:478 menu.sh:491 menu.sh:528 menu.sh:548 menu.sh:551 menu.sh:567 +#: menu.sh:571 +msgid "Modules" msgstr "模組" -msgid "opkg install is complete. Please reconnect to SSH/web, or execute 'source ~/.bashrc'" -msgstr "opkg 安裝完成。請重新連線 SSH/web,或者執行「source ~/.bashrc」" +#: menu.sh:479 +msgid "Reading modules" +msgstr "讀取模組中" -msgid "opkg installing ..." -msgstr "opkg 安裝中 ..." +#: menu.sh:492 +msgid "Select all" +msgstr "全選" +#: menu.sh:493 +msgid "Deselect all" +msgstr "全部不選" + +#: menu.sh:494 +msgid "Select modules to include" +msgstr "選擇要載入的增益集" + +#: menu.sh:529 +msgid "Selecting loaded modules" +msgstr "選擇已識別的模組" + +#: menu.sh:543 +msgid "" +"This function is experimental and dangerous. If you don't know much, please " +"exit.\\n" +msgstr "該功能是實驗性質且具有風險,如果你不瞭解,請退出。\\n" + +#: menu.sh:544 +msgid "" +"The imported .ko of this function will be implanted into the corresponding " +"arch's modules package, which will affect all models of the arch.\\n" +msgstr "該功能匯入 .ko 將植入相對架構的模組套件。這將影響該架構的所有型號。\\n" + +#: menu.sh:545 +msgid "" +"This program will not determine the availability of imported modules or even " +"make type judgments, as please double check if it is correct.\\n" +msgstr "" +"該程式不會判斷匯入的驅動模組的可用性,甚至不會做類型判斷,因此請再三確認是否" +"正確。\\n" + +#: menu.sh:546 +msgid "" +"If you want to remove it, please go to the \"Update Menu\" -> \"Update " +"modules\" to forcibly update the modules. All imports will be reset.\\n" +msgstr "" +"如果您想删除它,請前往「更新 -> 更新模組」強制更新模組。所有匯入都將被重" +"設。\\n" + +#: menu.sh:547 +msgid "Do you want to continue?" +msgstr "是否繼續?" + +#: menu.sh:552 +msgid "Please upload the *.ko file." +msgstr "請上傳 *.ko 檔案。" + +#: menu.sh:568 +msgid "Module '%s' added to %s-%s" +msgstr "模組 '%s' 已加入到 %s-%s" + +#: menu.sh:593 +msgid "Add/edit a cmdline item" +msgstr "加入/編輯 cmdline 參數" + +#: menu.sh:594 +msgid "Delete cmdline item(s)" +msgstr "删除 cmdline 參數" + +#: menu.sh:596 +msgid "Define SN/MAC" +msgstr "自訂 SN/MAC" + +#: menu.sh:598 +msgid "Show user added cmdline" +msgstr "顯示使用者加入的 cmdline 參數" + +#: menu.sh:599 +msgid "Show model inherent cmdline" +msgstr "顯示型號預設的 cmdline 參數" + +#: menu.sh:609 menu.sh:615 menu.sh:625 menu.sh:633 menu.sh:649 menu.sh:659 +#: menu.sh:688 menu.sh:696 +msgid "Cmdline" +msgstr "Cmdline" + +#: menu.sh:610 +msgid "Type a name of cmdline" +msgstr "輸入參數的名稱" + +#: menu.sh:616 +msgid "Type a value of '%s' cmdline" +msgstr "輸入 '%s' 參數的值" + +#: menu.sh:626 +msgid "No user cmdline to remove" +msgstr "沒有使用者 cmdline 被删除" + +#: menu.sh:634 +msgid "Select cmdline to remove" +msgstr "選擇要删除的參數" + +#: menu.sh:645 +msgid "Note: (MAC will not be set to NIC)" +msgstr "注意: (MAC 不會設定到 NIC)" + +#: menu.sh:650 +msgid "Random" +msgstr "隨機" + +#: menu.sh:660 +msgid "Invalid SN/MAC, retry?" +msgstr "無效的 SN/MAC, 重試?" + +#: menu.sh:713 +msgid "Add/edit a synoinfo item" +msgstr "加入/編輯 Synoinfo 參數" + +#: menu.sh:714 +msgid "Delete synoinfo item(s)" +msgstr "删除 Synoinfo 參數" + +#: menu.sh:715 +msgid "Show synoinfo entries" +msgstr "顯示 Synoinfo 參數" + +#: menu.sh:726 menu.sh:732 menu.sh:743 menu.sh:751 menu.sh:768 +msgid "Synoinfo" +msgstr "Synoinfo" + +#: menu.sh:727 +msgid "Type a name of synoinfo entry" +msgstr "輸入參數的名稱" + +#: menu.sh:733 +msgid "Type a value of '%s' synoinfo entry" +msgstr "輸入 '%s' 參數的值”" + +#: menu.sh:744 +msgid "No synoinfo entries to remove" +msgstr "沒有 Synoinfo 參數被删除" + +#: menu.sh:752 +msgid "Select synoinfo entry to remove" +msgstr "選擇要删除的參數" + +#: menu.sh:792 +msgid "%s cached." +msgstr "%s 已快取。" + +#: menu.sh:796 +msgid "Cleaning cache" +msgstr "清除快取" + +#: menu.sh:804 +msgid "" +"Based on the current network situation, switch to %s mirror to downloading." +msgstr "根據目前的網路狀況,已切換到 %s 鏡像伺服器進行下載。" + +#: menu.sh:808 +msgid "Downloading %s" +msgstr "下載 %s 中" + +#: menu.sh:818 menu.sh:881 +msgid "Check internet or cache disk space.\\nError: %d" +msgstr "請檢查網際網路或快取磁碟空間。\\n錯誤: %d" + +#: menu.sh:825 +msgid "Checking hash of %s: " +msgstr "檢查 %s 的雜湊值: " + +#: menu.sh:828 +msgid "" +"md5 hash of pat not match, Please reget pat data from the version menu and " +"try again!" +msgstr "pat 的 md5 雜湊值不相符,請自版本功能表中重新取得 pat 資料並再試一次!" + +#: menu.sh:832 menu.sh:935 menu.sh:945 +msgid "OK" +msgstr "OK" + +#: menu.sh:836 +msgid "Disassembling %s: " +msgstr "解壓縮 %s: " + +#: menu.sh:841 +msgid "Uncompressed tar" +msgstr "未壓縮 tar" + +#: menu.sh:845 +msgid "Compressed tar" +msgstr "已壓縮 tar" + +#: menu.sh:849 +msgid "Encrypted" +msgstr "已加密" + +#: menu.sh:854 +msgid "" +"Could not determine if pat file is encrypted or not, maybe corrupted, try " +"again!" +msgstr "無法確定 pat 檔案是否加密,可能已損壞,請重試!" + +#: menu.sh:864 +msgid "Extractor cached." +msgstr "已存在解密程式。" + +#: menu.sh:871 +msgid "Downloading old pat to extract synology .pat extractor..." +msgstr "下載舊 pat,選取 .pat 解密程式中..." + +#: menu.sh:912 menu.sh:915 +msgid "Extracting..." +msgstr "解壓中..." + +#: menu.sh:927 msgid "pat Invalid, try again!" msgstr "無效的 pat, 請重試!" -msgid "pat: (editable)" -msgstr "pat: (可編輯)" +#: menu.sh:930 +msgid "Setting hash: " +msgstr "設定雜湊值: " +#: menu.sh:937 +msgid "Copying files: " +msgstr "複製檔案: " + +#: menu.sh:959 +msgid "Addon %s not found!" +msgstr "增益集 %s 未找到!" + +#: menu.sh:989 menu.sh:2040 +msgid "Cleaning" +msgstr "清除中" + +#: menu.sh:991 +msgid "Ready!" +msgstr "已就绪!" + +#: menu.sh:1004 +msgid "Switch LKM version:" +msgstr "切換 LKM 版本:" + +#: menu.sh:1007 +msgid "Switch direct boot:" +msgstr "切換直接開機:" + +#: menu.sh:1009 +msgid "Timeout of get ip in boot:" +msgstr "開機時取得 IP 的逾時時間:" + +#: menu.sh:1010 +msgid "Timeout of boot wait:" +msgstr "開機逾時時間:" + +#: menu.sh:1011 +msgid "kernel switching method:" +msgstr "核心切換方式:" + +#: menu.sh:1013 +msgid "Reboot on kernel panic:" +msgstr "核心崩潰時重新啟動:" + +#: menu.sh:1015 +msgid "Set static IP" +msgstr "" + +#: menu.sh:1016 +msgid "Edit user config file manually" +msgstr "手動編輯使用者設定檔" + +#: menu.sh:1017 +msgid "Edit grub.cfg file manually" +msgstr "手動編輯 grub.cfg" + +#: menu.sh:1018 +msgid "Try to recovery a DSM installed system" +msgstr "嘗試回復已安裝 DSM 的系統" + +#: menu.sh:1019 +msgid "Show SATA(s) # ports and drives" +msgstr "顯示 SATA # 埠和磁碟機" + +#: menu.sh:1021 msgid "show/modify the current pat data" msgstr "顯示/修改目前 pat 資料" -msgid "zImage not patched,\\nPlease upgrade the bootloader version and try again.\\nPatch error:\\n" -msgstr "zImage 未修補,\\n請升級開機載入程式版本然後重試。\\n修補錯誤:\\n" +#: menu.sh:1023 +msgid "Allow downgrade installation" +msgstr "允許降級安裝" + +#: menu.sh:1024 +msgid "Format disk(s) # Without loader disk" +msgstr "格式化磁碟(s) # 不含開機碟" + +#: menu.sh:1025 +msgid "Reset DSM system password" +msgstr "重設 DSM 系統密碼" + +#: menu.sh:1026 +msgid "Save modifications of '/opt/rr'" +msgstr "儲存「/opt/rr」的修改" + +#: menu.sh:1028 +msgid "Custom dts file # Need rebuild" +msgstr "自訂 dts 檔案 # 需要重新編譯" + +#: menu.sh:1031 +msgid "Backup bootloader disk # test" +msgstr "備份開機碟 # 測試" + +#: menu.sh:1032 +msgid "Restore bootloader disk # test" +msgstr "回復開機碟 # 測試" + +#: menu.sh:1034 +msgid "Install development tools" +msgstr "安裝開發者工具" + +#: menu.sh:1035 +msgid "Show QR logo:" +msgstr "顯示 QR 商標:" + +#: menu.sh:1038 menu.sh:1056 menu.sh:1068 menu.sh:1088 menu.sh:1111 +#: menu.sh:1135 menu.sh:1199 menu.sh:1206 menu.sh:1224 menu.sh:1237 +#: menu.sh:1240 menu.sh:1250 menu.sh:1251 menu.sh:1256 menu.sh:1260 +#: menu.sh:1271 menu.sh:1273 menu.sh:1290 menu.sh:1295 menu.sh:1303 +#: menu.sh:1309 menu.sh:1322 menu.sh:1325 menu.sh:1331 menu.sh:1334 +#: menu.sh:1349 menu.sh:1354 menu.sh:1358 menu.sh:1373 menu.sh:1378 +#: menu.sh:1385 menu.sh:1389 menu.sh:1392 menu.sh:1397 menu.sh:1407 +#: menu.sh:1412 menu.sh:1418 menu.sh:1422 menu.sh:1439 menu.sh:1442 +#: menu.sh:1448 menu.sh:1456 menu.sh:1464 menu.sh:1471 menu.sh:1473 +msgid "Advanced" +msgstr "進階" + +#: menu.sh:1039 +msgid "Advanced option" +msgstr "進階選項" + +#: menu.sh:1057 menu.sh:1069 menu.sh:1089 +msgid "Choose a time(seconds)" +msgstr "選擇一個時間(秒)" + +#: menu.sh:1099 +msgid "Temporary IP: (UI will not refresh)" +msgstr "臨時 IP: (UI 不會重繪)" + +#: menu.sh:1136 +msgid "Setting IP ..." +msgstr "設定 IP..." + +#: menu.sh:1197 +msgid "\\nTotal of ports: %s\\n" +msgstr "\\n埠總數: %s\\n" + +#: menu.sh:1198 +msgid "" +"\\nPorts with color \\Z1red\\Zn as DUMMY, color \\Z2\\Zbgreen\\Zn has drive " +"connected." +msgstr "\\n\\Z1紅色\\Zn 為類比埠,\\Z2\\Zb綠色\\Zn 為已驅動的物理埠。" + +#: menu.sh:1205 +msgid "pat: (editable)" +msgstr "pat: (可編輯)" + +#: menu.sh:1221 +msgid "" +"This feature will allow you to downgrade the installation by removing the " +"VERSION file from the first partition of all disks.\\n" +msgstr "此功能透過删除所有磁碟第一個分區的 VERSION 檔案以允許你降級安裝。\\n" + +#: menu.sh:1222 +msgid "Therefore, please insert all disks before continuing.\\n" +msgstr "因此,請插入所有磁碟後再進行操作。\\n" + +#: menu.sh:1223 menu.sh:1257 +msgid "" +"Warning:\\nThis operation is irreversible. Please backup important data. Do " +"you want to continue?" +msgstr "警告:\\n該作業不可逆,請提前備份重要資料。是否繼續?" + +#: menu.sh:1238 +msgid "Removing ..." +msgstr "移除中..." + +#: menu.sh:1239 +msgid "Remove VERSION file for all disks completed." +msgstr "已移除所有磁碟的 VERSION 檔案。" + +#: menu.sh:1261 +msgid "" +"Warning:\\nThe current hds is in raid, do you still want to format them?" +msgstr "警告:\\n目前的硬碟使用 raid 中,是否仍要格式化?" + +#: menu.sh:1272 +msgid "Formatting ..." +msgstr "格式化中..." + +#: menu.sh:1274 +msgid "Formatting is complete." +msgstr "格式化完成。" + +#: menu.sh:1291 +msgid "The installed Syno system not found in the currently inserted disks!" +msgstr "未在目前插入的硬碟中找到已安裝的 syno 系統!" + +#: menu.sh:1296 +msgid "Choose a user name" +msgstr "選擇使用者" + +#: menu.sh:1304 +msgid "Type a new password for user '%s'" +msgstr "輸入使用者 '%s' 的新密碼" + +#: menu.sh:1310 +msgid "Invalid password" +msgstr "無效的密碼" + +#: menu.sh:1323 +msgid "Resetting ..." +msgstr "重設中 ..." + +#: menu.sh:1326 +msgid "Password reset completed." +msgstr "重設密碼完成。" + +#: menu.sh:1332 menu.sh:1390 menu.sh:1443 +msgid "" +"Warning:\\nDo not terminate midway, otherwise it may cause damage to the RR. " +"Do you want to continue?" +msgstr "警告:\\n請不要中途停止,否則將導致 RR 開機損毀,是否繼續?" + +#: menu.sh:1335 +msgid "Saving ..." +msgstr "儲存中..." + +#: menu.sh:1350 +msgid "Save is complete." +msgstr "儲存完成。" + +#: menu.sh:1359 +msgid "" +"Currently, only dts format files are supported. Please prepare and click to " +"confirm uploading.\\n(saved in /mnt/p3/users/)" +msgstr "" +"目前只支援 dts 格式的檔案,請準備並點選確認上傳。\\n(儲存於 /mnt/p3/users/ " +"中)" + +#: menu.sh:1374 +msgid "Not a valid dts file, please try again!" +msgstr "dts 檔案無效,請重試!" + +#: menu.sh:1379 +msgid "A valid dts file, Automatically import at compile time." +msgstr "dts 檔案有效,將在編譯時自動匯入。" + +#: menu.sh:1393 +msgid "Backuping..." +msgstr "備份中..." + +#: menu.sh:1398 +msgid "" +"Failed to generate backup. There may be insufficient memory. Please clear " +"the cache and try again!" +msgstr "產生備份失敗,可能記憶體不足,請清除快取後重試!" + +#: menu.sh:1405 +msgid "Click on the address above to download." +msgstr "點選上面的位址下載。" + +#: menu.sh:1406 +msgid "" +"Please confirm the completion of the download before closing this window." +msgstr "請確認下載完成再關閉此視窗。" + +#: menu.sh:1413 +msgid "backup is complete." +msgstr "備份完成。" + +#: menu.sh:1423 +msgid "" +"Please upload the backup file.\\nCurrently, zip(github) and img.gz(backup) " +"compressed file formats are supported." +msgstr "請上傳備份的檔案\\n目前支援 zip(github) 和 img.gz(backup) 格式。" + +#: menu.sh:1440 +msgid "Not a valid .zip/.img.gz file, please try again!" +msgstr "不是有效的.zip/.img.gz 檔案,請重試!" + +#: menu.sh:1449 +msgid "Writing..." +msgstr "寫入中..." + +#: menu.sh:1457 +msgid "Restore bootloader disk with success to %s!\\nReboot?" +msgstr "成功回復開機碟到 %s!\\n重新開機?" + +#: menu.sh:1465 +msgid "" +"This option only installs opkg package management, allowing you to install " +"more tools for use and debugging. Do you want to continue?" +msgstr "" +"該選項僅安裝 opkg 套件管理工具,讓你能够安裝更多的工具以供使用和除錯,是否繼" +"續?" + +#: menu.sh:1472 +msgid "opkg installing ..." +msgstr "opkg 安裝中 ..." + +#: menu.sh:1474 +msgid "" +"opkg install is complete. Please reconnect to SSH/web, or execute 'source ~/." +"bashrc'" +msgstr "opkg 安裝完成。請重新連線 SSH/web,或者執行「source ~/.bashrc」" + +#: menu.sh:1489 menu.sh:1526 menu.sh:1533 +msgid "Try recovery DSM" +msgstr "嘗試回復 DSM 系統" + +#: menu.sh:1490 +msgid "Trying to recovery a DSM installed system" +msgstr "嘗試回復已安裝的 DSM 系統中" + +#: menu.sh:1516 +msgid "Found a installation:\\nModel: %s\\nProductversion: %s" +msgstr "找到已安裝:\\n型號: %s\\n版本: %s" + +#: menu.sh:1520 +msgid "\\nSerial: %s" +msgstr "\\nSN: %s" + +#: menu.sh:1534 +msgid "Unfortunately I couldn't mount the DSM partition!" +msgstr "很遺憾,無法掛載 DSM 分割區!" + +#: menu.sh:1542 menu.sh:1548 menu.sh:1571 +msgid "Edit with caution" +msgstr "請謹慎編輯" + +#: menu.sh:1582 +msgid "Alert" +msgstr "警告" + +#: menu.sh:1583 +msgid "Config changed, would you like to rebuild the loader?" +msgstr "設置已變更,是否重新編譯開機檔?" + +#: menu.sh:1585 menu.sh:1991 menu.sh:2024 +msgid "Main menu" +msgstr "主功能表" + +#: menu.sh:1586 menu.sh:2025 +msgid "Making ..." +msgstr "編譯中 ..." + +#: menu.sh:1596 menu.sh:1981 +msgid "Choose a language" +msgstr "選擇語言" + +#: menu.sh:1610 +msgid "Choose a layout" +msgstr "選擇佈局" + +#: menu.sh:1622 +msgid "Choice a keymap" +msgstr "選擇鍵盤" + +#: menu.sh:1641 menu.sh:1695 menu.sh:1746 menu.sh:1818 menu.sh:1821 +#: menu.sh:1824 menu.sh:1827 menu.sh:1834 menu.sh:1841 menu.sh:1848 +#: menu.sh:1855 +msgid "Update %s" +msgstr "更新 %s" + +#: menu.sh:1644 +msgid "Checking last version" +msgstr "檢測新版本中" + +#: menu.sh:1657 menu.sh:1660 +msgid "Error checking new version" +msgstr "檢測新版本錯誤" + +#: menu.sh:1667 +msgid "No new version." +msgstr "沒有新版本。" + +#: menu.sh:1671 +msgid "No new version. Actual version is %s\\nForce update?" +msgstr "沒有新版本。實際版本為 %s\\n強制更新?" + +#: menu.sh:1679 +msgid "Downloading ..." +msgstr "下載中 ..." + +#: menu.sh:1683 menu.sh:1686 +msgid "Error downloading new version" +msgstr "下載新版本錯誤" + +#: menu.sh:1697 menu.sh:1748 +msgid "Extracting last version" +msgstr "解壓新版本" + +#: menu.sh:1701 +msgid "Error extracting update file" +msgstr "更新檔案解壓錯誤" + +#: menu.sh:1708 +msgid "Checksum do not match!" +msgstr "總和檢查碼不相符!" + +#: menu.sh:1717 +msgid "" +"The current version does not support upgrading to the latest update.zip. " +"Please remake the bootloader disk!" +msgstr "目前版本不支援升級到最新的 update.zip,請重新製作開機碟!" + +#: menu.sh:1722 +msgid "Installing new files" +msgstr "安裝更新中" + +#: menu.sh:1739 +msgid "RR updated with success to %s!\\nReboot?" +msgstr "RR 更新成功 %s!\\n重新開機?" + +#: menu.sh:1754 +msgid "Installing new %s" +msgstr "安裝新 %s 中" + +#: menu.sh:1783 menu.sh:1786 +msgid "%s updated with success!" +msgstr "%s 更新成功!" + +#: menu.sh:1800 +msgid "Update all" +msgstr "更新全部" + +#: menu.sh:1801 +msgid "Update RR" +msgstr "更新 RR " + +#: menu.sh:1802 +msgid "Update addons" +msgstr "更新增益集" + +#: menu.sh:1803 +msgid "Update modules" +msgstr "更新模組" + +#: menu.sh:1804 +msgid "Update LKMs" +msgstr "更新 LKM" + +#: menu.sh:1806 +msgid "Set proxy server" +msgstr "設定代理" + +#: menu.sh:1808 +msgid "Local upload" +msgstr "本地上傳" + +#: menu.sh:1809 +msgid "Pre Release:" +msgstr "預發佈:" + +#: menu.sh:1818 menu.sh:1841 +msgid "addons" +msgstr "增益集" + +#: menu.sh:1821 menu.sh:1848 +msgid "modules" +msgstr "模組" + +#: menu.sh:1824 menu.sh:1855 +msgid "LKMs" +msgstr "LKMs" + +#: menu.sh:1827 menu.sh:1834 +msgid "RR" +msgstr "RR" + +#: menu.sh:1864 menu.sh:1875 menu.sh:1886 menu.sh:1896 menu.sh:1913 +#: menu.sh:1927 +msgid "Update" +msgstr "更新" + +#: menu.sh:1865 +msgid "Please enter a proxy server url" +msgstr "請輸入代理伺服器網址" + +#: menu.sh:1876 +msgid "Invalid proxy server url, continue?" +msgstr "無效的代理伺服器網址,是否繼續?" + +#: menu.sh:1891 +msgid "" +"Please keep the attachment name consistent with the attachment name on " +"Github.\\n" +msgstr "請保持附件名稱與 github 上附件名稱一致。\\n" + +#: menu.sh:1892 +msgid "Upload update.zip will update RR.\\n" +msgstr "上傳 update.zip 將更新 RR。\\n" + +#: menu.sh:1893 +msgid "Upload addons.zip will update Addons.\\n" +msgstr "上傳 addons.zip 將更新增益集。\\n" + +#: menu.sh:1894 +msgid "Upload modules.zip will update Modules.\\n" +msgstr "上傳 modules.zip 將更新模組。\\n" + +#: menu.sh:1895 +msgid "Upload rp-lkms.zip will update LKMs.\\n" +msgstr "上傳 rp-lkms.zip 將更新 LKM。\\n" + +#: menu.sh:1944 +msgid "This person is very lazy and hasn't written anything." +msgstr "這個人很懶,什麼也沒有寫。" + +#: menu.sh:1945 +msgid "Edit" +msgstr "編輯" + +#: menu.sh:1962 +msgid "Choose a model" +msgstr "選擇型號" + +#: menu.sh:1964 +msgid "Choose a version" +msgstr "選擇版本" + +#: menu.sh:1966 +msgid "Addons menu" +msgstr "增益集功能表" + +#: menu.sh:1967 +msgid "Modules menu" +msgstr "模組功能表" + +#: menu.sh:1968 +msgid "Cmdline menu" +msgstr "設定 Cmdline" + +#: menu.sh:1969 +msgid "Synoinfo menu" +msgstr "Synoinfo 功能表" + +#: menu.sh:1972 +msgid "Advanced menu" +msgstr "進階功能表" + +#: menu.sh:1975 +msgid "Build the loader" +msgstr "編譯開機檔" + +#: menu.sh:1979 +msgid "Boot the loader" +msgstr "開機" + +#: menu.sh:1982 +msgid "Choose a keymap" +msgstr "選擇鍵盤" + +#: menu.sh:1984 +msgid "Clean disk cache" +msgstr "清除磁碟快取" + +#: menu.sh:1986 +msgid "Update menu" +msgstr "更新功能表" + +#: menu.sh:1987 +msgid "Notepad" +msgstr "記事本" + +#: menu.sh:2056 +msgid "Choose a action" +msgstr "選擇動作" + +#: menu.sh:2057 +msgid "Poweroff" +msgstr "關機" + +#: menu.sh:2058 +msgid "Reboot" +msgstr "重新開機" + +#: menu.sh:2059 +msgid "Reboot to RR" +msgstr "重新開機並進入 RR" + +#: menu.sh:2060 +msgid "Back to shell" +msgstr "退回到 shell" + +#: menu.sh:2086 +msgid "Call \\033[1;32mmenu.sh\\033[0m to return to menu" +msgstr "執行 \\033[1;32mmenu.sh\\033[0m 重新進入設定選單" diff --git a/files/initrd/opt/rr/menu.sh b/files/initrd/opt/rr/menu.sh index 4a2ed2a8..51e2c885 100755 --- a/files/initrd/opt/rr/menu.sh +++ b/files/initrd/opt/rr/menu.sh @@ -1,22 +1,22 @@ #!/usr/bin/env bash -. /opt/rr/include/functions.sh -. /opt/rr/include/addons.sh -. /opt/rr/include/modules.sh +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" + +. ${WORK_PATH}/include/functions.sh +. ${WORK_PATH}/include/addons.sh +. ${WORK_PATH}/include/modules.sh + +[ -z "${LOADER_DISK}" ] && die "$(TEXT "Loader is not init!")" # Check partition 3 space, if < 2GiB is necessary clean cache folder CLEARCACHE=0 -LOADER_DISK="$(blkid | grep 'LABEL="RR3"' | cut -d3 -f1)" -LOADER_DEVICE_NAME=$(echo "${LOADER_DISK}" | sed 's|/dev/||') -if [ $(cat "/sys/block/${LOADER_DEVICE_NAME}/${LOADER_DEVICE_NAME}3/size") -lt 4194304 ]; then +if [ $(cat "/sys/block/${LOADER_DISK/\/dev\//}/${LOADER_DISK_PART3/\/dev\//}/size") -lt 4194304 ]; then CLEARCACHE=1 fi # Get actual IP -IP=$(ip route 2>/dev/null | sed -n 's/.* via .* dev \(.*\) src \(.*\) metric .*/\1: \2 /p' | head -1) +IP="$(getIP)" -# Dirty flag -DIRTY=0 # Debug flag # DEBUG=0 @@ -93,10 +93,11 @@ function modelMenu() { Y=$(echo ${M} | tr -cd "[0-9]") Y=${Y:0-2} echo "${M} ${Y}" >>"${TMP_PATH}/modellist" - done < <(find "${MODEL_CONFIG_PATH}" -maxdepth 1 -name \*.yml | sed 's/.*\///; s/\.yml//') + done < <(find "${WORK_PATH}/model-configs" -maxdepth 1 -name \*.yml | sed 's/.*\///; s/\.yml//') while true; do echo -n "" >"${TMP_PATH}/menu" + echo "c \"\Z1$(TEXT "Compatibility judgment")\Zn\"" >>"${TMP_PATH}/menu" FLGNEX=0 while read M Y; do PLATFORM=$(readModelKey "${M}" "platform") @@ -119,21 +120,12 @@ function modelMenu() { done < <(cat "${TMP_PATH}/modellist" | sort -r -n -k 2) [ ${FLGNEX} -eq 1 ] && echo "f \"\Z1$(TEXT "Disable flags restriction")\Zn\"" >>"${TMP_PATH}/menu" [ ${FLGBETA} -eq 0 ] && echo "b \"\Z1$(TEXT "Show all models")\Zn\"" >>"${TMP_PATH}/menu" - echo "c \"\Z1$(TEXT "Compatibility judgment")\Zn\"" >>"${TMP_PATH}/menu" dialog --backtitle "$(backtitle)" --colors \ --menu "$(TEXT "Choose the model")" 0 0 0 --file "${TMP_PATH}/menu" \ 2>${TMP_PATH}/resp [ $? -ne 0 ] && return resp=$(<${TMP_PATH}/resp) [ -z "${resp}" ] && return - if [ "${resp}" = "f" ]; then - RESTRICT=0 - continue - fi - if [ "${resp}" = "b" ]; then - FLGBETA=1 - continue - fi if [ "${resp}" = "c" ]; then models=(DS918+ RS1619xs+ DS419+ DS1019+ DS719+ DS1621xs+) [ $(lspci -d ::300 | grep 8086 | wc -l) -gt 0 ] && iGPU=1 || iGPU=0 @@ -165,7 +157,7 @@ function modelMenu() { [ "${DT}" = "true" ] && M_2="* " fi if [ "${NVME}" = "2" ]; then - if echo ${models[@]} | grep -q ${M}; then + if echo ${models[@]} | grep -q ${M}; then M_2="* " fi fi @@ -175,6 +167,14 @@ function modelMenu() { --textbox "${TMP_PATH}/opts" 0 0 continue fi + if [ "${resp}" = "f" ]; then + RESTRICT=0 + continue + fi + if [ "${resp}" = "b" ]; then + FLGBETA=1 + continue + fi break done else @@ -199,14 +199,14 @@ function modelMenu() { for I in $(seq 1 ${NETIF_NUM}); do writeConfigKey "mac${I}" "${MACS[$((${I} - 1))]}" "${USER_CONFIG_FILE}" done - DIRTY=1 + touch ${PART1_PATH}/.build fi } ############################################################################### # Shows available buildnumbers from a model to user choose one function productversMenu() { - ITEMS="$(readConfigEntriesArray "productvers" "${MODEL_CONFIG_PATH}/${MODEL}.yml" | sort -r)" + ITEMS="$(readConfigEntriesArray "productvers" "${WORK_PATH}/model-configs/${MODEL}.yml" | sort -r)" if [ -z "${1}" ]; then dialog --backtitle "$(backtitle)" --colors \ --no-items --menu "$(TEXT "Choose a product version")" 0 0 0 ${ITEMS} \ @@ -229,15 +229,15 @@ function productversMenu() { --msgbox "$(TEXT "This version does not support UEFI startup, Please select another version or switch the startup mode.")" 0 0 return fi - if [ ! "usb" = "$(udevadm info --query property --name ${LOADER_DISK} | grep ID_BUS | cut -d= -f2)" -a "${KVER:0:1}" = "5" ]; then - dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Product Version")" \ - --msgbox "$(TEXT "This version only support usb startup, Please select another version or switch the startup mode.")" 0 0 - # return - fi + # if [ ! "usb" = "$(getBus "${LOADER_DISK}")" -a "${KVER:0:1}" = "5" ]; then + # dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Product Version")" \ + # --msgbox "$(TEXT "This version only support usb startup, Please select another version or switch the startup mode.")" 0 0 + # # return + # fi while true; do # get online pat data dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Product Version")" \ - --infobox "$(TEXT "Get pat data ..")" 0 0 + --infobox "$(TEXT "Get pat data ...")" 0 0 idx=0 while [ ${idx} -le 3 ]; do # Loop 3 times, if successful, break fastest=$(_get_fastest "www.synology.com" "www.synology.cn") @@ -306,7 +306,7 @@ function productversMenu() { done < <(getAllModules "${PLATFORM}" "$([ -n "${KPRE}" ] && echo "${KPRE}-")${KVER}") # Remove old files rm -f "${ORI_ZIMAGE_FILE}" "${ORI_RDGZ_FILE}" "${MOD_ZIMAGE_FILE}" "${MOD_RDGZ_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build } ############################################################################### @@ -362,7 +362,7 @@ function addonMenu() { VALUE="$(<"${TMP_PATH}/resp")" ADDONS[${ADDON}]="${VALUE}" writeConfigKey "addons.${ADDON}" "${VALUE}" "${USER_CONFIG_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build ;; d) NEXT='d' @@ -385,7 +385,7 @@ function addonMenu() { unset ADDONS[${I}] deleteConfigKey "addons.${I}" "${USER_CONFIG_FILE}" done - DIRTY=1 + touch ${PART1_PATH}/.build ;; s) NEXT='s' @@ -441,7 +441,7 @@ function addonMenu() { fi ADDON="$(untarAddon "${TMP_UP_PATH}/${USER_FILE}")" if [ -n "${ADDON}" ]; then - [ -f "${CACHE_PATH}/addons/VERSION" ] && rm -f "${CACHE_PATH}/addons/VERSION" + [ -f "${PART3_PATH}/addons/VERSION" ] && rm -f "${PART3_PATH}/addons/VERSION" dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Addons")" \ --msgbox "$(printf "$(TEXT "Addon '%s' added to loader, Please enable it in 'Add an addon' menu.")" "${ADDON}")" 0 0 else @@ -501,7 +501,7 @@ function moduleMenu() { for ID in ${resp}; do writeConfigKey "modules.${ID}" "" "${USER_CONFIG_FILE}" done - DIRTY=1 + touch ${PART1_PATH}/.build break ;; 3) # extra-button @@ -509,11 +509,11 @@ function moduleMenu() { while read ID DESC; do writeConfigKey "modules.${ID}" "" "${USER_CONFIG_FILE}" done <<<${ALLMODULES} - DIRTY=1 + touch ${PART1_PATH}/.build ;; 2) # help-button writeConfigKey "modules" "{}" "${USER_CONFIG_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build ;; 1) # cancel-button break @@ -536,7 +536,7 @@ function moduleMenu() { for ID in ${KOLIST[@]}; do writeConfigKey "modules.${ID}" "" "${USER_CONFIG_FILE}" done - DIRTY=1 + touch ${PART1_PATH}/.build ;; o) MSG="" @@ -563,7 +563,7 @@ function moduleMenu() { popd if [ -n "${USER_FILE}" -a "${USER_FILE##*.}" = "ko" ]; then addToModules ${PLATFORM} "$([ -n "${KPRE}" ] && echo "${KPRE}-")${KVER}" "${TMP_UP_PATH}/${USER_FILE}" - [ -f "${CACHE_PATH}/modules/VERSION" ] && rm -f "${CACHE_PATH}/modules/VERSION" + [ -f "${PART3_PATH}/modules/VERSION" ] && rm -f "${PART3_PATH}/modules/VERSION" dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Modules")" \ --msgbox "$(printf "$(TEXT "Module '%s' added to %s-%s")" "${USER_FILE}" "${PLATFORM}" "$([ -n "${KPRE}" ] && echo "${KPRE}-")${KVER}")" 0 0 rm -f "${TMP_UP_PATH}/${USER_FILE}" @@ -736,7 +736,7 @@ function synoinfoMenu() { VALUE="$(<"${TMP_PATH}/resp")" SYNOINFO[${NAME}]="${VALUE}" writeConfigKey "synoinfo.${NAME}" "${VALUE}" "${USER_CONFIG_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build ;; d) if [ ${#SYNOINFO[@]} -eq 0 ]; then @@ -758,7 +758,7 @@ function synoinfoMenu() { unset SYNOINFO[${I}] deleteConfigKey "synoinfo.${I}" "${USER_CONFIG_FILE}" done - DIRTY=1 + touch ${PART1_PATH}/.build ;; s) ITEMS="" @@ -779,11 +779,12 @@ function extractDsmFiles() { PATURL="$(readConfigKey "paturl" "${USER_CONFIG_FILE}")" PATSUM="$(readConfigKey "patsum" "${USER_CONFIG_FILE}")" - SPACELEFT=$(df --block-size=1 | awk '/'${LOADER_DEVICE_NAME}'3/{print $4}') # Check disk space left + # Check disk space left + SPACELEFT=$(df --block-size=1 | grep ${LOADER_DISK_PART3} | awk '{print $4}') PAT_FILE="${MODEL}-${PRODUCTVER}.pat" - PAT_PATH="${CACHE_PATH}/dl/${PAT_FILE}" - EXTRACTOR_PATH="${CACHE_PATH}/extractor" + PAT_PATH="${PART3_PATH}/dl/${PAT_FILE}" + EXTRACTOR_PATH="${PART3_PATH}/extractor" EXTRACTOR_BIN="syno_extract_system_patch" OLDPATURL="https://global.synologydownload.com/download/DSM/release/7.0.1/42218/DSM_DS3622xs%2B_42218.pat" @@ -793,10 +794,11 @@ function extractDsmFiles() { # If we have little disk space, clean cache folder if [ ${CLEARCACHE} -eq 1 ]; then echo "$(TEXT "Cleaning cache")" - rm -rf "${CACHE_PATH}/dl" + rm -rf "${PART3_PATH}/dl" fi - mkdir -p "${CACHE_PATH}/dl" - fastest=$(_get_fastest "global.synologydownload.com" "global.download.synology.com" "cndl.synology.cn") + mkdir -p "${PART3_PATH}/dl" + mirrors=("global.synologydownload.com" "global.download.synology.com" "cndl.synology.cn") + fastest=$(_get_fastest ${mirrors[@]}) mirror="$(echo ${PATURL} | sed 's|^http[s]*://\([^/]*\).*|\1|')" if echo "${mirrors[@]}" | grep -wq "${mirror}" && [ "${mirror}" != "${fastest}" ]; then echo "$(printf "$(TEXT "Based on the current network situation, switch to %s mirror to downloading.")" "${fastest}")" @@ -810,7 +812,7 @@ function extractDsmFiles() { # No disk space to download, change it to RAMDISK PAT_PATH="${TMP_PATH}/${PAT_FILE}" fi - STATUS=$(curl -k -w "%{http_code}" -L "${PATURL}" -o "${PAT_PATH}" --progress-bar) + STATUS=$(curl -k -w "%{http_code}" -L "${PATURL}" -o "${PAT_PATH}") if [ $? -ne 0 -o ${STATUS} -ne 200 ]; then rm -f "${PAT_PATH}" MSG="$(printf "$(TEXT "Check internet or cache disk space.\nError: %d")" "${STATUS}")" @@ -854,7 +856,7 @@ function extractDsmFiles() { ;; esac - SPACELEFT=$(df --block-size=1 | awk '/'${LOADER_DEVICE_NAME}'3/{print$4}') # Check disk space left + SPACELEFT=$(df --block-size=1 | grep ${LOADER_DISK_PART3} | awk '{print $4}') # Check disk space left if [ "${isencrypted}" = "yes" ]; then # Check existance of extractor @@ -864,7 +866,7 @@ function extractDsmFiles() { # Extractor not exists, get it. mkdir -p "${EXTRACTOR_PATH}" # Check if old pat already downloaded - OLDPAT_PATH="${CACHE_PATH}/dl/DS3622xs+-42218.pat" + OLDPAT_PATH="${PART3_PATH}/dl/DS3622xs+-42218.pat" if [ ! -f "${OLDPAT_PATH}" ]; then echo "$(TEXT "Downloading old pat to extract synology .pat extractor...")" # Discover remote file size @@ -873,7 +875,7 @@ function extractDsmFiles() { # No disk space to download, change it to RAMDISK OLDPAT_PATH="${TMP_PATH}/DS3622xs+-42218.pat" fi - STATUS=$(curl -k -w "%{http_code}" -L "${OLDPATURL}" -o "${OLDPAT_PATH}" --progress-bar) + STATUS=$(curl -k -w "%{http_code}" -L "${OLDPATURL}" -o "${OLDPAT_PATH}") if [ $? -ne 0 -o ${STATUS} -ne 200 ]; then rm -f "${OLDPAT_PATH}" MSG="$(printf "$(TEXT "Check internet or cache disk space.\nError: %d")" "${STATUS}")" @@ -933,38 +935,19 @@ function extractDsmFiles() { echo "$(TEXT "OK")" echo -n "$(TEXT "Copying files: ")" - cp -f "${UNTAR_PAT_PATH}/grub_cksum.syno" "${BOOTLOADER_PATH}" - cp -f "${UNTAR_PAT_PATH}/GRUB_VER" "${BOOTLOADER_PATH}" - cp -f "${UNTAR_PAT_PATH}/grub_cksum.syno" "${SLPART_PATH}" - cp -f "${UNTAR_PAT_PATH}/GRUB_VER" "${SLPART_PATH}" + cp -f "${UNTAR_PAT_PATH}/grub_cksum.syno" "${PART1_PATH}" + cp -f "${UNTAR_PAT_PATH}/GRUB_VER" "${PART1_PATH}" + cp -f "${UNTAR_PAT_PATH}/grub_cksum.syno" "${PART2_PATH}" + cp -f "${UNTAR_PAT_PATH}/GRUB_VER" "${PART2_PATH}" cp -f "${UNTAR_PAT_PATH}/zImage" "${ORI_ZIMAGE_FILE}" cp -f "${UNTAR_PAT_PATH}/rd.gz" "${ORI_RDGZ_FILE}" rm -rf "${UNTAR_PAT_PATH}" echo "$(TEXT "OK")" } -# 1 - model -function getLogo() { - rm -f "${CACHE_PATH}/logo.png" - if [ "${DSMLOGO}" = "true" ]; then - fastest=$(_get_fastest "www.synology.com" "www.synology.cn") - STATUS=$(curl -skL -w "%{http_code}" "https://${fastest}/api/products/getPhoto?product=${MODEL/+/%2B}&type=img_s&sort=0" -o "${CACHE_PATH}/logo.png") - if [ $? -ne 0 -o ${STATUS} -ne 200 -o -f "${CACHE_PATH}/logo.png" ]; then - convert -rotate 180 "${CACHE_PATH}/logo.png" "${CACHE_PATH}/logo.png" 2>/dev/null - magick montage "${CACHE_PATH}/logo.png" -background 'none' -tile '3x3' -geometry '350x210' "${CACHE_PATH}/logo.png" 2>/dev/null - convert -rotate 180 "${CACHE_PATH}/logo.png" "${CACHE_PATH}/logo.png" 2>/dev/null - fi - fi -} - ############################################################################### # Where the magic happens! function make() { - # clear - clear - # get logo.png - getLogo "${MODEL}" - PLATFORM="$(readModelKey "${MODEL}" "platform")" KVER="$(readModelKey "${MODEL}" "productvers.[${PRODUCTVER}].kver")" KPRE="$(readModelKey "${MODEL}" "productvers.[${PRODUCTVER}].kpre")" @@ -983,19 +966,24 @@ function make() { [ $? -ne 0 ] && return 1 fi - /opt/rr/zimage-patch.sh + # Check disk space left + SPACELEFT=$(df --block-size=1 | grep ${LOADER_DISK_PART3} | awk '{print $4}') + [ ${SPACELEFT} -le 268435456 ] && rm -rf "${PART3_PATH}/dl" + + ${WORK_PATH}/zimage-patch.sh if [ $? -ne 0 ]; then dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Error")" \ --msgbox "$(TEXT "zImage not patched,\nPlease upgrade the bootloader version and try again.\nPatch error:\n")$(<"${LOG_FILE}")" 0 0 return 1 fi - /opt/rr/ramdisk-patch.sh + ${WORK_PATH}/ramdisk-patch.sh if [ $? -ne 0 ]; then dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Error")" \ --msgbox "$(TEXT "Ramdisk not patched,\nPlease upgrade the bootloader version and try again.\nPatch error:\n")$(<"${LOG_FILE}")" 0 0 return 1 fi + rm -f ${PART1_PATH}/.build PRODUCTVER="$(readConfigKey "productver" "${USER_CONFIG_FILE}")" BUILDNUM="$(readConfigKey "buildnum" "${USER_CONFIG_FILE}")" SMALLNUM="$(readConfigKey "smallnum" "${USER_CONFIG_FILE}")" @@ -1003,7 +991,6 @@ function make() { rm -rf "${UNTAR_PAT_PATH}" echo "$(TEXT "Ready!")" sleep 3 - DIRTY=0 return 0 } @@ -1045,7 +1032,7 @@ function advancedMenu() { echo "r \"$(TEXT "Restore bootloader disk # test")\"" >>"${TMP_PATH}/menu" fi echo "o \"$(TEXT "Install development tools")\"" >>"${TMP_PATH}/menu" - echo "g \"$(TEXT "Show dsm logo:") \Z4${DSMLOGO}\Zn\"" >>"${TMP_PATH}/menu" + echo "g \"$(TEXT "Show QR logo:") \Z4${DSMLOGO}\Zn\"" >>"${TMP_PATH}/menu" echo "e \"$(TEXT "Exit")\"" >>"${TMP_PATH}/menu" dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ @@ -1056,7 +1043,7 @@ function advancedMenu() { l) LKM=$([ "${LKM}" = "dev" ] && echo 'prod' || ([ "${LKM}" = "test" ] && echo 'dev' || echo 'test')) writeConfigKey "lkm" "${LKM}" "${USER_CONFIG_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build NEXT="l" ;; q) @@ -1144,7 +1131,7 @@ function advancedMenu() { IDX=$((${IDX} + 1)) done sleep 1 - IP=$(ip route 2>/dev/null | sed -n 's/.* via .* dev \(.*\) src \(.*\) metric .*/\1: \2 /p' | head -1) + IP="$(getIP)" ) 2>&1 | dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ --progressbox "$(TEXT "Setting IP ...")" 20 100 NEXT="e" @@ -1226,7 +1213,7 @@ function advancedMenu() { writeConfigKey "paturl" "${paturl}" "${USER_CONFIG_FILE}" writeConfigKey "patsum" "${patsum}" "${USER_CONFIG_FILE}" rm -f "${ORI_ZIMAGE_FILE}" "${ORI_RDGZ_FILE}" "${MOD_ZIMAGE_FILE}" "${MOD_RDGZ_FILE}" - DIRTY=1 + touch ${PART1_PATH}/.build fi ;; a) @@ -1239,7 +1226,7 @@ function advancedMenu() { [ $? -ne 0 ] && return ( mkdir -p "${TMP_PATH}/sdX1" - for I in $(ls /dev/sd*1 2>/dev/null | grep -v "${LOADER_DISK}1"); do + for I in $(ls /dev/sd.*1 2>/dev/null | grep -v "${LOADER_DISK_PART1}"); do mount "${I}" "${TMP_PATH}/sdX1" [ -f "${TMP_PATH}/sdX1/etc/VERSION" ] && rm -f "${TMP_PATH}/sdX1/etc/VERSION" [ -f "${TMP_PATH}/sdX1/etc.defaults/VERSION" ] && rm -f "${TMP_PATH}/sdX1/etc.defaults/VERSION" @@ -1257,7 +1244,7 @@ function advancedMenu() { rm -f "${TMP_PATH}/opts" while read POSITION NAME; do [ -z "${POSITION}" -o -z "${NAME}" ] && continue - echo "${POSITION}" | grep -q "${LOADER_DEVICE_NAME}" && continue + echo "${POSITION}" | grep -q "${LOADER_DISK}" && continue echo "\"${POSITION}\" \"${NAME}\" \"off\"" >>"${TMP_PATH}/opts" done < <(ls -l /dev/disk/by-id/ | sed 's|../..|/dev|g' | grep -E "/dev/sd|/dev/nvme" | awk -F' ' '{print $NF" "$(NF-2)}' | sort -uk 1,1) dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ @@ -1289,7 +1276,7 @@ function advancedMenu() { x) SHADOW_FILE="" mkdir -p "${TMP_PATH}/sdX1" - for I in $(ls /dev/sd*1 2>/dev/null | grep -v "${LOADER_DISK}1"); do + for I in $(ls /dev/sd*1 2>/dev/null | grep -v "${LOADER_DISK_PART1}"); do mount ${I} "${TMP_PATH}/sdX1" if [ -f "${TMP_PATH}/sdX1/etc/shadow" ]; then cp -f "${TMP_PATH}/sdX1/etc/shadow" "${TMP_PATH}/shadow_bak" @@ -1325,7 +1312,7 @@ function advancedMenu() { NEWPASSWD="$(python -c "import crypt,getpass;pw=\"${VALUE}\";print(crypt.crypt(pw))")" ( mkdir -p "${TMP_PATH}/sdX1" - for I in $(ls /dev/sd*1 2>/dev/null | grep -v ${LOADER_DISK}1); do + for I in $(ls /dev/sd.*1 2>/dev/null | grep -v ${LOADER_DISK_PART1}); do mount "${I}" "${TMP_PATH}/sdX1" sed -i "s|${OLDPASSWD}|${NEWPASSWD}|g" "${TMP_PATH}/sdX1/etc/shadow" sync @@ -1391,7 +1378,7 @@ function advancedMenu() { dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ --msgbox "$(TEXT "A valid dts file, Automatically import at compile time.")" 0 0 fi - DIRTY=1 + touch ${PART1_PATH}/.build ;; b) if ! tty | grep -q "/dev/pts"; then @@ -1412,7 +1399,7 @@ function advancedMenu() { return fi if [ -z "${SSH_TTY}" ]; then # web - IP_HEAD="$(ip route show 2>/dev/null | sed -n 's/.* via .* src \(.*\) metric .*/\1/p' | head -1)" + IP_HEAD="$(getIP)" echo "http://${IP_HEAD}/backup.img.gz" >${TMP_PATH}/resp echo " ↑ " >>${TMP_PATH}/resp echo "$(TEXT "Click on the address above to download.")" >>${TMP_PATH}/resp @@ -1448,19 +1435,19 @@ function advancedMenu() { break done popd - if [ -z "${IFTOOL}" -o -z "${TMP_UP_PATH}/${USER_FILE}" ]; then + if [ -z "${IFTOOL}" -o ! -f "${TMP_UP_PATH}/${USER_FILE}" ]; then dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ --msgbox "$(printf "$(TEXT "Not a valid .zip/.img.gz file, please try again!")" "${USER_FILE}")" 0 0 else dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ --yesno "$(TEXT "Warning:\nDo not terminate midway, otherwise it may cause damage to the RR. Do you want to continue?")" 0 0 [ $? -ne 0 ] && ( - rm -f "${LOADER_DISK}" + rm -f "${TMP_UP_PATH}/${USER_FILE}" return ) dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Advanced")" \ --infobox "$(TEXT "Writing...")" 0 0 - umount "${BOOTLOADER_PATH}" "${SLPART_PATH}" "${CACHE_PATH}" + umount "${PART1_PATH}" "${PART2_PATH}" "${PART3_PATH}" if [ "${IFTOOL}" = "zip" ]; then unzip -p "${TMP_UP_PATH}/${USER_FILE}" | dd of="${LOADER_DISK}" bs=1M conv=fsync elif [ "${IFTOOL}" = "gzip" ]; then @@ -1520,12 +1507,12 @@ function tryRecoveryDSM() { [ "${unique}" = "${UNIQUE}" ] || continue # Found modelMenu "${M}" - done < <(find "${MODEL_CONFIG_PATH}" -maxdepth 1 -name \*.yml | sort) + done < <(find "${WORK_PATH}/model-configs" -maxdepth 1 -name \*.yml | sort) if [ -n "${MODEL}" ]; then productversMenu "${majorversion}.${minorversion}" if [ -n "${PRODUCTVER}" ]; then - cp -f "${DSMROOT_PATH}/.syno/patch/zImage" "${SLPART_PATH}" - cp -f "${DSMROOT_PATH}/.syno/patch/rd.gz" "${SLPART_PATH}" + cp -f "${DSMROOT_PATH}/.syno/patch/zImage" "${PART2_PATH}" + cp -f "${DSMROOT_PATH}/.syno/patch/rd.gz" "${PART2_PATH}" MSG="$(printf "$(TEXT "Found a installation:\nModel: %s\nProductversion: %s")" "${MODEL}" "${PRODUCTVER}")" SN=$(_get_conf_kv SN "${DSMROOT_PATH}/etc/synoinfo.conf") if [ -n "${SN}" ]; then @@ -1574,7 +1561,7 @@ function editUserConfig() { rm -f "${MOD_ZIMAGE_FILE}" rm -f "${MOD_RDGZ_FILE}" fi - DIRTY=1 + touch ${PART1_PATH}/.build } ############################################################################### @@ -1592,12 +1579,13 @@ function editGrubCfg() { ############################################################################### # Calls boot.sh to boot into DSM kernel/ramdisk function boot() { - [ ${DIRTY} -eq 1 ] && dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Alert")" \ + [ -f ${PART1_PATH}/.build ] && dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Alert")" \ --yesno "$(TEXT "Config changed, would you like to rebuild the loader?")" 0 0 if [ $? -eq 0 ]; then - make || return + make 2>&1 | dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Main menu")" --cr-wrap --no-collapse \ + --progressbox "$(TEXT "Making ...")" 20 100 || return fi - boot.sh + ${WORK_PATH}/boot.sh } ############################################################################### @@ -1610,7 +1598,7 @@ function languageMenu() { resp=$(cat ${TMP_PATH}/resp 2>/dev/null) [ -z "${resp}" ] && return LANGUAGE=${resp} - echo "${LANGUAGE}.UTF-8" >${BOOTLOADER_PATH}/.locale + echo "${LANGUAGE}.UTF-8" >${PART1_PATH}/.locale export LANG="${LANGUAGE}.UTF-8" } @@ -1684,10 +1672,11 @@ function downloadExts() { [ $? -ne 0 ] && return 1 fi fi - dialog --backtitle "$(backtitle)" --colors --title "${T}" \ - --infobox "$(TEXT "Downloading last version")" 0 0 - rm -f "${TMP_PATH}/${4}.zip" - STATUS=$(curl -kL -w "%{http_code}" "${PROXY}${3}/releases/download/${TAG}/${4}.zip" -o "${TMP_PATH}/${4}.zip") + ( + rm -f "${TMP_PATH}/${4}.zip" + STATUS=$(curl -kL -w "%{http_code}" "${PROXY}${3}/releases/download/${TAG}/${4}.zip" -o "${TMP_PATH}/${4}.zip") + ) 2>&1 | dialog --backtitle "$(backtitle)" --colors --title "${T}" \ + --progressbox "$(TEXT "Downloading ...")" 20 100 if [ $? -ne 0 -o ${STATUS} -ne 200 ]; then if [ ! "${5}" = "0" ]; then dialog --backtitle "$(backtitle)" --colors --title "${T}" \ @@ -1748,7 +1737,7 @@ function updateRR() { done < <(readConfigMap "replace" "${TMP_PATH}/update-list.yml") dialog --backtitle "$(backtitle)" --colors --title "${T}" \ --msgbox "$(printf "$(TEXT "RR updated with success to %s!\nReboot?")" "${TAG}")" 0 0 - rr-reboot.sh config + rebootTo config } # 1 - ext name @@ -1788,7 +1777,7 @@ function updateExts() { rm -rf "${LKM_PATH}/"* unzip "${TMP_PATH}/rp-lkms.zip" -d "${LKM_PATH}" >/dev/null 2>&1 fi - DIRTY=1 + touch ${PART1_PATH}/.build if [ ! "${2}" = "0" ]; then dialog --backtitle "$(backtitle)" --colors --title "${T}" \ --infobox "$(printf "$(TEXT "%s updated with success!")" "${1}")" 0 0 @@ -1802,9 +1791,9 @@ function updateExts() { function updateMenu() { while true; do CUR_RR_VER="${RR_VERSION:-0}" - CUR_ADDONS_VER="$(cat "${CACHE_PATH}/addons/VERSION" 2>/dev/null)" - CUR_MODULES_VER="$(cat "${CACHE_PATH}/modules/VERSION" 2>/dev/null)" - CUR_LKMS_VER="$(cat "${CACHE_PATH}/lkms/VERSION" 2>/dev/null)" + CUR_ADDONS_VER="$(cat "${PART3_PATH}/addons/VERSION" 2>/dev/null)" + CUR_MODULES_VER="$(cat "${PART3_PATH}/modules/VERSION" 2>/dev/null)" + CUR_LKMS_VER="$(cat "${PART3_PATH}/lkms/VERSION" 2>/dev/null)" PROXY="$(readConfigKey "proxy" "${USER_CONFIG_FILE}")" [ -n "${PROXY}" ] && [[ "${PROXY: -1}" != "/" ]] && PROXY="${PROXY}/" rm -f "${TMP_PATH}/menu" @@ -1963,7 +1952,7 @@ function notepadMenu() { ############################################################################### if [ "x$1" = "xb" -a -n "${MODEL}" -a -n "${PRODUCTVER}" -a loaderIsConfigured ]; then - install-addons.sh + updateAddons make boot && exit 0 || sleep 5 fi @@ -1991,7 +1980,7 @@ while true; do fi echo "l \"$(TEXT "Choose a language")\"" >>"${TMP_PATH}/menu" echo "k \"$(TEXT "Choose a keymap")\"" >>"${TMP_PATH}/menu" - if [ ${CLEARCACHE} -eq 1 -a -d "${CACHE_PATH}/dl" ]; then + if [ ${CLEARCACHE} -eq 1 -a -d "${PART3_PATH}/dl" ]; then echo "c \"$(TEXT "Clean disk cache")\"" >>"${TMP_PATH}/menu" fi echo "p \"$(TEXT "Update menu")\"" >>"${TMP_PATH}/menu" @@ -2032,7 +2021,8 @@ while true; do NEXT="d" ;; d) - make + make 2>&1 | dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Main menu")" --cr-wrap --no-collapse \ + --progressbox "$(TEXT "Making ...")" 20 100 NEXT="b" ;; b) @@ -2048,7 +2038,7 @@ while true; do ;; c) dialog --backtitle "$(backtitle)" --colors --title "$(TEXT "Cleaning")" \ - --prgbox "rm -rfv \"${CACHE_PATH}/dl\"" 0 0 + --prgbox "rm -rfv \"${PART3_PATH}/dl\"" 0 0 NEXT="d" ;; p) @@ -2079,7 +2069,7 @@ while true; do reboot ;; c) - rr-reboot.sh config + rebootTo config ;; s) break 2 diff --git a/files/initrd/opt/rr/model-configs/FS6400.yml.disabled b/files/initrd/opt/rr/model-configs/FS6400.yml.disabled index 34104827..f3c8dcf8 100644 --- a/files/initrd/opt/rr/model-configs/FS6400.yml.disabled +++ b/files/initrd/opt/rr/model-configs/FS6400.yml.disabled @@ -7,6 +7,8 @@ synoinfo: &synoinfo supportadt7490: "no" support_syno_hybrid_raid: supportraidgroup: + supportsas: "no" + supportsas_v2: "yes" maxlanport: "8" netif_seq: "0 1 2 3 4 5 6 7" buzzeroffen: "0xffff" @@ -17,6 +19,7 @@ cmdline: &cmdline syno_ttyS0: "serial,0x3f8" syno_ttyS1: "serial,0x2f8" elevator: elevator + modprobe.blacklist: mpt3sas patch: &patch - "ramdisk-etc-rc-*.patch" - "ramdisk-init-script-v4-*.patch" diff --git a/files/initrd/opt/rr/model-configs/HD6500.yml.disabled b/files/initrd/opt/rr/model-configs/HD6500.yml.disabled index 6b879138..8d99afcd 100644 --- a/files/initrd/opt/rr/model-configs/HD6500.yml.disabled +++ b/files/initrd/opt/rr/model-configs/HD6500.yml.disabled @@ -5,6 +5,8 @@ synoinfo: &synoinfo support_led_brightness_adjustment: "no" support_syno_hybrid_raid: supportraidgroup: + supportsas: "no" + supportsas_v2: "yes" maxlanport: "8" netif_seq: "0 1 2 3 4 5 6 7" buzzeroffen: "0xffff" @@ -15,6 +17,7 @@ cmdline: &cmdline syno_ttyS0: "serial,0x3f8" syno_ttyS1: "serial,0x2f8" elevator: elevator + modprobe.blacklist: mpt3sas patch: &patch - "ramdisk-etc-rc-*.patch" - "ramdisk-init-script-v4-*.patch" diff --git a/files/initrd/opt/rr/model-configs/RS2423+.yml b/files/initrd/opt/rr/model-configs/RS2423+.yml index 96e269f1..1dc36ff0 100644 --- a/files/initrd/opt/rr/model-configs/RS2423+.yml +++ b/files/initrd/opt/rr/model-configs/RS2423+.yml @@ -3,9 +3,6 @@ synoinfo: &synoinfo support_disk_compatibility: "no" support_memory_compatibility: "no" support_led_brightness_adjustment: "no" - support_leds_atmega1608: "no" - support_leds_lp3943: "no" - supportadt7490: "no" support_syno_hybrid_raid: supportraidgroup: maxlanport: "8" diff --git a/files/initrd/opt/rr/model-configs/SA3410.yml b/files/initrd/opt/rr/model-configs/SA3410.yml index 4d08a856..6e4b0f60 100644 --- a/files/initrd/opt/rr/model-configs/SA3410.yml +++ b/files/initrd/opt/rr/model-configs/SA3410.yml @@ -7,6 +7,7 @@ synoinfo: &synoinfo support_syno_hybrid_raid: supportraidgroup: supportsas: "no" + supportsas_v2: "yes" maxlanport: "8" netif_seq: "0 1 2 3 4 5 6 7" cmdline: &cmdline @@ -17,6 +18,7 @@ cmdline: &cmdline SMBusHddDynamicPower: 1 vender_format_version: 2 elevator: elevator + modprobe.blacklist: mpt3sas patch: &patch - "ramdisk-etc-rc-*.patch" - "ramdisk-init-script-v4-*.patch" diff --git a/files/initrd/opt/rr/model-configs/SA3610.yml b/files/initrd/opt/rr/model-configs/SA3610.yml index fbe0ac7a..ec7e17e9 100644 --- a/files/initrd/opt/rr/model-configs/SA3610.yml +++ b/files/initrd/opt/rr/model-configs/SA3610.yml @@ -8,6 +8,7 @@ synoinfo: &synoinfo support_syno_hybrid_raid: supportraidgroup: supportsas: "no" + supportsas_v2: "yes" maxlanport: "8" netif_seq: "0 1 2 3 4 5 6 7" cmdline: &cmdline @@ -16,6 +17,7 @@ cmdline: &cmdline syno_hdd_powerup_seq: 0 vender_format_version: 2 elevator: elevator + modprobe.blacklist: mpt3sas patch: &patch - "ramdisk-etc-rc-*.patch" - "ramdisk-init-script-v4-*.patch" diff --git a/files/initrd/opt/rr/ramdisk-patch.sh b/files/initrd/opt/rr/ramdisk-patch.sh index 388f52c9..067aca12 100755 --- a/files/initrd/opt/rr/ramdisk-patch.sh +++ b/files/initrd/opt/rr/ramdisk-patch.sh @@ -1,7 +1,9 @@ #!/usr/bin/env bash -. /opt/rr/include/functions.sh -. /opt/rr/include/addons.sh +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" + +. ${WORK_PATH}/include/functions.sh +. ${WORK_PATH}/include/addons.sh set -o pipefail # Get exit code from process piped @@ -13,12 +15,6 @@ echo -n "Patching Ramdisk" # Remove old rd.gz patched rm -f "${MOD_RDGZ_FILE}" -# Check disk space left -LOADER_DISK="$(blkid | grep 'LABEL="RR3"' | cut -d3 -f1)" -LOADER_DEVICE_NAME=$(echo ${LOADER_DISK} | sed 's|/dev/||') -SPACELEFT=$(df --block-size=1 | awk '/'${LOADER_DEVICE_NAME}'3/{print$4}') -[ ${SPACELEFT} -le 268435456 ] && rm -rf "${CACHE_PATH}/dl" - # Unzipping ramdisk echo -n "." rm -rf "${RAMDISK_PATH}" # Force clean @@ -93,7 +89,7 @@ done < <(readConfigMap "modules" "${USER_CONFIG_FILE}") while read PE; do RET=1 echo "Patching with ${PE}" >"${LOG_FILE}" 2>&1 - for PF in $(ls ${PATCH_PATH}/${PE}); do + for PF in $(ls ${WORK_PATH}/patch/${PE}); do echo -n "." echo "Patching with ${PF}" >>"${LOG_FILE}" 2>&1 ( @@ -116,7 +112,7 @@ _set_conf_kv "SN" "${SN}" "${RAMDISK_PATH}/etc/synoinfo.conf" >"${LOG_FILE}" 2>& # Patch /sbin/init.post echo -n "." -grep -v -e '^[\t ]*#' -e '^$' "${PATCH_PATH}/config-manipulators.sh" >"${TMP_PATH}/rp.txt" +grep -v -e '^[\t ]*#' -e '^$' "${WORK_PATH}/patch/config-manipulators.sh" >"${TMP_PATH}/rp.txt" sed -e "/@@@CONFIG-MANIPULATORS-TOOLS@@@/ {" -e "r ${TMP_PATH}/rp.txt" -e 'd' -e '}' -i "${RAMDISK_PATH}/sbin/init.post" rm -f "${TMP_PATH}/rp.txt" touch "${TMP_PATH}/rp.txt" @@ -150,7 +146,7 @@ rm -rf "${TMP_PATH}/modules" echo -n "." # Copying fake modprobe -cp -f "${PATCH_PATH}/iosched-trampoline.sh" "${RAMDISK_PATH}/usr/sbin/modprobe" +cp -f "${WORK_PATH}/patch/iosched-trampoline.sh" "${RAMDISK_PATH}/usr/sbin/modprobe" # Copying LKM to /usr/lib/modules gzip -dc "${LKM_PATH}/rp-${PLATFORM}-$([ -n "${KPRE}" ] && echo "${KPRE}-")${KVER}-${LKM}.ko.gz" >"${RAMDISK_PATH}/usr/lib/modules/rp.ko" @@ -171,6 +167,10 @@ echo "export LAYOUT=${LAYOUT}" >>"${RAMDISK_PATH}/addons/addons.sh" echo "export KEYMAP=${KEYMAP}" >>"${RAMDISK_PATH}/addons/addons.sh" chmod +x "${RAMDISK_PATH}/addons/addons.sh" +# Required addons: restore +installAddon revert +echo "/addons/revert.sh \${1} " >>"${RAMDISK_PATH}/addons/addons.sh" 2>"${LOG_FILE}" || dieLog + # Required addons: eudev, disks, localrss, wol installAddon eudev echo "/addons/eudev.sh \${1} " >>"${RAMDISK_PATH}/addons/addons.sh" 2>"${LOG_FILE}" || dieLog @@ -198,7 +198,7 @@ echo "inetd" >>"${RAMDISK_PATH}/addons/addons.sh" [ "2" = "${BUILDNUM:0:1}" ] && sed -i 's/function //g' $(find "${RAMDISK_PATH}/addons/" -type f -name "*.sh") # Build modules dependencies -/opt/rr/depmod -a -b ${RAMDISK_PATH} 2>/dev/null +${WORK_PATH}/depmod -a -b ${RAMDISK_PATH} 2>/dev/null # Network card configuration file for N in $(seq 0 7); do diff --git a/files/initrd/opt/rr/vmlinux-to-bzImage.sh b/files/initrd/opt/rr/vmlinux-to-bzImage.sh index 26025894..bc380137 100755 --- a/files/initrd/opt/rr/vmlinux-to-bzImage.sh +++ b/files/initrd/opt/rr/vmlinux-to-bzImage.sh @@ -1,7 +1,9 @@ #!/usr/bin/env bash # Based on code and ideas from @jumkey -. /opt/rr/include/functions.sh +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" + +. ${WORK_PATH}/include/functions.sh MODEL="$(readConfigKey "model" "${USER_CONFIG_FILE}")" PRODUCTVER="$(readConfigKey "productver" "${USER_CONFIG_FILE}")" diff --git a/files/initrd/opt/rr/zimage-patch.sh b/files/initrd/opt/rr/zimage-patch.sh index e6c873c7..6622aaf9 100755 --- a/files/initrd/opt/rr/zimage-patch.sh +++ b/files/initrd/opt/rr/zimage-patch.sh @@ -1,6 +1,8 @@ #!/usr/bin/env bash -. /opt/rr/include/functions.sh +[ -z "${WORK_PATH}" -o ! -d "${WORK_PATH}/include" ] && WORK_PATH="$(cd "$(dirname "${BASH_SOURCE[0]}")" >/dev/null 2>&1 && pwd)" + +. ${WORK_PATH}/include/functions.sh set -o pipefail # Get exit code from process piped @@ -12,13 +14,13 @@ echo -n "Patching zImage" rm -f "${MOD_ZIMAGE_FILE}" echo -n "." # Extract vmlinux -/opt/rr/bzImage-to-vmlinux.sh "${ORI_ZIMAGE_FILE}" "${TMP_PATH}/vmlinux" >"${LOG_FILE}" 2>&1 || dieLog +${WORK_PATH}/bzImage-to-vmlinux.sh "${ORI_ZIMAGE_FILE}" "${TMP_PATH}/vmlinux" >"${LOG_FILE}" 2>&1 || dieLog echo -n "." # Patch boot params and ramdisk check -/opt/rr/kpatch "${TMP_PATH}/vmlinux" "${TMP_PATH}/vmlinux-mod" >"${LOG_FILE}" 2>&1 || dieLog +${WORK_PATH}/kpatch "${TMP_PATH}/vmlinux" "${TMP_PATH}/vmlinux-mod" >"${LOG_FILE}" 2>&1 || dieLog echo -n "." # rebuild zImage -/opt/rr/vmlinux-to-bzImage.sh "${TMP_PATH}/vmlinux-mod" "${MOD_ZIMAGE_FILE}" >"${LOG_FILE}" 2>&1 || dieLog +${WORK_PATH}/vmlinux-to-bzImage.sh "${TMP_PATH}/vmlinux-mod" "${MOD_ZIMAGE_FILE}" >"${LOG_FILE}" 2>&1 || dieLog echo -n "." # Update HASH of new DSM zImage HASH="$(sha256sum ${ORI_ZIMAGE_FILE} | awk '{print$1}')" diff --git a/files/p1/EFI/BOOT/SynoBootLoader.conf b/files/p1/EFI/BOOT/SynoBootLoader.conf deleted file mode 100755 index 2fb0ba94..00000000 --- a/files/p1/EFI/BOOT/SynoBootLoader.conf +++ /dev/null @@ -1,19 +0,0 @@ -serial --unit=1 --speed=115200 -terminal serial -default 1 -timeout 3 -verbose -hiddenmenu -fallback 0 - -title SYNOLOGY_1 - root (hd0,0) - kernel /zImage root=/dev/md0 - initrd /rd.gz - -title SYNOLOGY_2 - root (hd0,1) - cksum /grub_cksum.syno - vender /vender show - kernel /zImage root=/dev/md0 - initrd /rd.gz diff --git a/files/p1/EFI/BOOT/SynoBootLoader.efi b/files/p1/EFI/BOOT/SynoBootLoader.efi deleted file mode 100755 index e69de29b..00000000 diff --git a/guide.md b/guide.md index c8f93853..79215e70 100644 --- a/guide.md +++ b/guide.md @@ -107,6 +107,15 @@ ## DEBUG * log: ``` + # 内核相关 + sysctl -n kernel.syno_serial # 查看当前鉴权的SN + cat /proc/sys/kernel/syno_serial # 查看当前鉴权的SN + sysctl -n kernel.syno_mac_address1 # 查看当前鉴权的mcac1 (kernel.syno_mac_addresses) + cat /proc/sys/kernel/syno_mac_address1 # 查看当前鉴权的mcac1 (/proc/sys/kernel/syno_mac_addresses) + sysctl -n kernel.syno_internal_netif_num # 查看当前鉴权的网卡数量 + cat /proc/sys/kernel/syno_internal_netif_num # 查看当前鉴权的网卡数量 + nproc # 查看当前线程数 + # 驱动相关 lsmod # 查看已加载驱动 ls -ld /sys/class/net/*/device/driver # 查看已加载网卡和对应驱动 @@ -128,6 +137,7 @@ # 服务相关 systemctl # 查看服务 netstat -tunlp # 查看端口 + systemctl disable cpufreq.service # 禁用 CPU 频率调节器 # 日志相关 dmesg # 内核日志 diff --git a/img-gen.sh b/img-gen.sh index 2b02dd87..55a80236 100755 --- a/img-gen.sh +++ b/img-gen.sh @@ -4,13 +4,8 @@ set -e . scripts/func.sh -# Convert po2mo, Get extractor, LKM, addons and Modules +# Convert po2mo convertpo2mo "files/initrd/opt/rr/lang" -getExtractor "files/p3/extractor" -getLKMs "files/p3/lkms" true -getAddons "files/p3/addons" true -getModules "files/p3/modules" true - IMAGE_FILE="rr.img" gzip -dc "files/grub.img.gz" >"${IMAGE_FILE}" @@ -30,12 +25,20 @@ getBuildroot "2023.02.x" "br" [ ! -f "br/bzImage-rr" -o ! -f "br/initrd-rr" ] && return 1 echo "Repack initrd" -cp -f "br/bzImage-rr" "files/p3/bzImage-rr" -repackInitrd "br/initrd-rr" "files/initrd" "files/p3/initrd-rr" +cp -f "br/bzImage-rr" "/tmp/p3/bzImage-rr" +repackInitrd "br/initrd-rr" "files/initrd" "/tmp/p3/initrd-rr" echo "Copying files" sudo cp -Rf "files/p1/"* "/tmp/p1" sudo cp -Rf "files/p3/"* "/tmp/p3" +# Get extractor, LKM, addons and Modules +getLKMs "/tmp/p3/lkms" true +getAddons "/tmp/p3/addons" true +getModules "/tmp/p3/modules" true +getExtractor "/tmp/p3/extractor" + +read -p "Press enter to continue" + sync echo "Unmount image file" diff --git a/scripts/func.sh b/scripts/func.sh index 38a28f5e..e4e4a1ad 100755 --- a/scripts/func.sh +++ b/scripts/func.sh @@ -176,7 +176,7 @@ function getModules() { # repack initrd # $1 initrd file # $2 plugin path -# $3 output path +# $3 output file function repackInitrd() { INITRD_FILE="${1}" PLUGIN_PATH="${2}" diff --git a/update-check.sh b/update-check.sh index 802986e3..d91efe9e 100755 --- a/update-check.sh +++ b/update-check.sh @@ -1,40 +1,6 @@ #!/usr/bin/env bash -# 23.5.0 -[ ! -f /mnt/p1/boot/grub/grub.cfg ] && exit 1 - -# 23.7.0 -. /opt/rr/include/functions.sh -if loaderIsConfigured; then - if [ -f "${ORI_RDGZ_FILE}" ]; then - rm -rf "${RAMDISK_PATH}" - mkdir -p "${RAMDISK_PATH}" - ( - cd "${RAMDISK_PATH}" - xz -dc <"${ORI_RDGZ_FILE}" | cpio -idm - ) >/dev/null 2>&1 - . "${RAMDISK_PATH}/etc/VERSION" - [ -n "$(readConfigKey "build" "${USER_CONFIG_FILE}")" ] && deleteConfigKey "build" "${USER_CONFIG_FILE}" - [ -n "$(readConfigKey "smallfixnumber" "${USER_CONFIG_FILE}")" ] && deleteConfigKey "smallfixnumber" "${USER_CONFIG_FILE}" - [ -z "$(readConfigKey "paturl" "${USER_CONFIG_FILE}")" ] && writeConfigKey "paturl" "" "${USER_CONFIG_FILE}" - [ -z "$(readConfigKey "patsum" "${USER_CONFIG_FILE}")" ] && writeConfigKey "patsum" "" "${USER_CONFIG_FILE}" - [ -z "$(readConfigKey "productver" "${USER_CONFIG_FILE}")" ] && writeConfigKey "productver" "${majorversion}.${minorversion}" "${USER_CONFIG_FILE}" - [ -z "$(readConfigKey "buildnum" "${USER_CONFIG_FILE}")" ] && writeConfigKey "buildnum" "${buildnumber}" "${USER_CONFIG_FILE}" - [ -z "$(readConfigKey "smallnum" "${USER_CONFIG_FILE}")" ] && writeConfigKey "smallnum" "${smallfixnumber}" "${USER_CONFIG_FILE}" - fi -fi - -# 23.9.7 -MAC1="$(readConfigKey "cmdline.mac1" "${USER_CONFIG_FILE}")" -deleteConfigKey "notsetmacs" "${USER_CONFIG_FILE}" -for N in $(1 8); do - deleteConfigKey "cmdline.mac${N}" "${USER_CONFIG_FILE}" - deleteConfigKey "original-mac${N}" "${USER_CONFIG_FILE}" -done -deleteConfigKey "cmdline.netif_num" "${USER_CONFIG_FILE}" -[ -n "${MAC1}" ] && writeConfigKey "mac1" "${MAC1}" "${USER_CONFIG_FILE}" - -MAC1="$(readConfigKey "mac1" "${USER_CONFIG_FILE}")" -[ -z "${MAC1}" ] && writeConfigKey "mac1" "001132$(printf '%02x%02x%02x' $((${RANDOM} % 256)) $((${RANDOM} % 256)) $((${RANDOM} % 256)))" "${USER_CONFIG_FILE}" +# rr +[ ! "rr" = "$(hostname)" ] && exit 1 exit 0