I've just gone through the ball pain of upgrading to an upstream version of a package and then deciding to downgrade. This was via a maintainers private repository. In my case this was all about trying out the latest systemd 233 version (yet unreleased).
The key is to understand that you need to specify all the packages that should be downgraded. If you get this right, chances are apt will do what you want. If you miss something out, apt will tell you that the action will cause lots of packages to get removed. To make sure we use the '-s' flag to try out the downgrade before actually doing it.
The steps you need to take are thus:
1) List all dependencies that were upgraded to upstream (use some other keyword if your situation is different):
dpkg -l|grep upstream
This gives you a list of packages with an upstream version number.
2) List what the correct stable version is for each package:
for i in libnss-resolve:amd64 libsystemd0:amd64 libpam-systemd:amd64 libsystemd0:i386 libudev1:amd64 libudev1:i386 systemd systemd-sysv udev; do apt-cache show $i; done|grep Version
3) Double check all is good:
apt -s --allow-downgrades --no-remove --reinstall install libnss-resolve:amd64=232-21ubuntu5 libsystemd0:amd64=232-21ubuntu5 libpam-systemd:amd64=232-21ubuntu5 libsystemd0:i386=232-21ubuntu5 libudev1:amd64=232-21ubuntu5 libudev1:i386=232-21ubuntu5 systemd=232-21ubuntu5 systemd-sysv=232-21ubuntu5 udev=232-21ubuntu5
0 to upgrade, 0 to newly install, 9 to downgrade, 0 to remove and 0 not to upgrade.
(not sure if --reinstall was required btw, but this is what I did)
4) Remove the -s and do it.
apt --allow-downgrades --no-remove --reinstall install libnss-resolve:amd64=232-21ubuntu5 libsystemd0:amd64=232-21ubuntu5 libpam-systemd:amd64=232-21ubuntu5 libsystemd0:i386=232-21ubuntu5 libudev1:amd64=232-21ubuntu5 libudev1:i386=232-21ubuntu5 systemd=232-21ubuntu5 systemd-sysv=232-21ubuntu5 udev=232-21ubuntu5
ppa-purge
first? – landroni Feb 04 '14 at 07:38synaptic
, when you select the xyz package, all dependencies will be selected by default.But you may always deselect all dependencies and just install main package.Later you may install all dependencies.But again, this works only if you are ready to reinstall. – Registered User Feb 05 '14 at 11:04