9 Downgrade package with dependent package
Dave Russell edited this page 2023-10-15 11:33:29 +11:00

How to downgrade a Synology DSM package that has dependent packages

Initial Situation

  • Package SAN Manager (aka ScsiTarget) version 1.0.09-0305 from DSM 7.2
  • Package SAN Manager (aka ScsiTarget) version 1.0.10-0314 from DSM 7.2.1
  • The DSM downgrade caused SAN Manager to fail to start due to not being compatible with DSM 7.2.
  • Uninstalling SAN Manager via SSH fails due to dependant packages Snapshot Replication and Virtual Machine Manager (even though I uninstalled Snapshot Replication and Virtual Machine Manager via SSH).
  • Unable to do manual package install of ScsiTarget version 1.0.09-0305 because newer version is installed.

Problem

Synology DSM won't let you downgrade packages and you can not uninstall a package (to install the older version) when there are packages installed that depend on the package you want be downgrade.

Prepare

  • Do a full system and data backup just in case
  • Enable SSH server on the Synology via "Control Center > Terminal & SNMP".
  • Download the older package version from https://archive.synology.com/download/Package
  • Disable automatic updates entirely, or just for the package that you want to downgrade.

How to downgrade a package

  1. Log into your Synology via SSH as an administrative user.
  2. Go to package directory
    Navigate to /var/packages/ and find the directory of your package, that has a dependency on the package to downgrade, in my case: ScsiTarget in /var/packages/ScsiTarget
  3. Backup the INFO file.
  4. Open the INFO file with vim and find the version line, in my case:
    version="1.0.10-0314"
  5. Change it to the version you want to install: version="1.0.09-0305"
  6. Save the change.
  7. Open Package Center and click Repair for SAN Manager.
  8. Package Center will download and install SAN Manager 1.0.09-0305
  9. You can now install Snapshot Replication and Virtual Machine Manager.