Skip to content

007revad/Synology_DSM_reinstall

Repository files navigation

Synology DSM re-install

Donate committers.top badge

Description

Easily re-install the same DSM version without losing any data or settings

  • If you need to re-install the same full release DSM version this is much easier than resetting the Synology.
  • It can also be used to roll back from an update version to the same full release version.

Important

You must download a full version pat file. If you download a small update pat file you will get an error saying:
The update that you are applying is not compatible with this version of DSM

How to tell if a .pat file is a full release or a small update

  • Full release DSM pat files are:
    • Normally named DSM_model_build.pat like DSM_DS224+_64570.pat
    • Are 270MB or larger and always much larger than small updates.
  • Small update pat files are:
    • Always named synology_arch_model.pat like synology_geminilake_224+.pat
    • Are 1MB to 130MB and always much smaller than full updates.
  • Note: Sometimes a full release is named like a small update .pat file when Synology messes up the file naming.

Steps to reinstall DSM

  1. Disable DSM Auto Update via "Control Panel > Update & Restore > Update Settings > Notify me... > OK".
  2. Download the same DSM full release build version from Synology's download site.
  3. Run this script via SSH or from Task Scheduler.
  4. Go to "Control Panel > Update & Restore > Manual DSM Update".
  5. Browse to the DSM .pat file you downloaded in step 2 and click Open then OK.
  6. Optionally unplug your router from the Internet after DSM has started installing to prevent DSM updating to the latest update version.
  7. Click Update.
  8. Wait for the Synology NAS to finished updating and rebooting.
  9. If you unpluged your router from the Internet in step 6, reconnect it now.

Download the script

  1. Download the latest version Source code (zip) from https://github.com/007revad/Synology_DSM_reinstall/releases
  2. Save the download zip file to a folder on the Synology.
  3. Unzip the zip file.

How to run the script

You can run the script either via SSH or in Task Scheduler.

Scheduling the script in Synology's Task Scheduler

Running the script via SSH

How to enable SSH and login to DSM via SSH

Note: Replace /volume1/scripts/ with the path to where the script is located.

sudo -s /volume1/scripts/syno_dsm_reinstall.sh

Screenshots

Here's the result after running the script.

The script has edited DSM's VERSION file to a lower build number

Select your downloaded DSM .pat file

No complaints from DSM