Downgrade from Debian SID to Stable from Jessie to Wheezy
Downgrade from Debian SID to Stable from Jessie to Wheezy. This Tutorial describes the downgrade process you need to run to ge back stable rel after sid upgrade. Recently, a problem occurred on my server after i had upgraded my system with the SID repository in my sources.list. The Debian release jessie came out and after upgrading to this release some services no longer ran properly anymore. So I had to run a task to get back to Wheezy to recover the failing services.
So here are the few easy steps you will need to downgrade a Debian SID release to Wheezy or any kind of other release you like:
Important Update Note: Since new SID/Jessie release gets delivered with systemd as default,
It is important to switch back from systemd to sysv first before the downgrade process by doing:
apt-get install sysvinit-core sysvinit sysvinit-utils
Then reboot your server and remove all the systemd stuff!
apt-get remove --purge --auto-remove systemd
And continue with the previous downgrade tutorial steps:
First of all you have to remove or replace all SID tags from your
/etc/apt/sources.list to your preffered target release
Mine sources.list file looks like this after changes have made:
deb http://security.debian.org/ wheezy/updates main deb-src http://security.debian.org/ wheezy/updates main deb http://cdn.debian.net/debian/ wheezy main contrib non-free deb-src http://cdn.debian.net/debian/ wheezy main contrib non-free
Now we have to use the Apt-Pinning feature to get the correct default release tag for our apt downgrade
Modify or create the file /etc/apt/preferences and put following text in it:
Package: * Pin: release a=stable Pin-Priority: 1001
Important Update note: Replace a=stable with n=wheezy if you are running not the SID but Jessie final release!
At the next step we have to run the apt update and upgrade process for downgrading all packages
So you will need to enter these two commands to finish the downgrade process:
apt-get update apt-get upgrade apt-get dist-upgrade
Apt will ask you for downgrading all packages now.
Just say yes, let it go and pray that all packages getting installed and downgraded properly!
If some packages failing on downgrade you have to purge them by doing:
apt-get purge yourfailingpackage
And reinstall them with
apt-get install yourfailingpackage after purging it.