If you want to restore the original QNAP firmware or re-install Debian on your TS-41x or TS-42x device for some reason, you can follow the instructions below. Please note that this will only work if your Debian system is still working. If your Debian system is broken but the machine itself works, you can use the recovery mode to restore the QNAP firmware or re-install Debian.
Restoring the original QNAP firmware
There are two steps to restore the original QNAP firmware. First, you have to put the backup of the flash partitions from the QNAP firmware you made before the installation of Debian into flash.
cat mtd1 > /dev/mtdblock1 cat mtd2 > /dev/mtdblock2
Second, you have to restart your QNAP, and then go to the web interface to format your disk and install the full QNAP firmware.
After you put the QNAP firmware back in flash and installed the complete the QNAP software, your device will run the original software from QNAP again.
If you want to re-install Debian using Debian installer, you can put the installer in flash and restart your device.
Since there are two different kernel variants for QNAP devices, you first have to determine which variant you need. You can do this by calling this script:
You also have to download the initrd files of the installer (make sure the initrd does not get uncompressed when you download it).
You can now write the installer files to flash:
cat kernel-628x > /dev/mtdblock1 cat initrd > /dev/mtdblock2
Reboot your QNAP device and Debian installer will start and you can connect via SSH, as documented on the install page. Please be aware that the SSH key of the machine will have changed.