downgrade PHP 5.3 to 5.2 on lenny
Solution 1
Apt won't downgrade packages by default. What you want to do is for each of the packages you want to downgrade, run apt-get install <package>=<version to downgrade to>
, so something like apt-get install php5-mysql=5.2.6.dfsg.1-1+lenny3
for example.
Solution 2
Check your /var/cache/apt/archives directory. If you haven't done an apt-get clean recently, you will have the original .deb files on your system.
ls -al *5.2.12*deb
if that contains libapache2-mod-php5 and all of the php5 modules that you normally use, you can either dpkg -i the entire list of them, or, if there aren't any extras,
dpkg -i *5.2.12*deb
Related videos on Youtube
![Admin](/assets/logo_square_200-5d0d61d6853298bd2a4fe063103715b4daf2819fc21225efa21dfb93e61952ea.png)
Admin
Updated on September 17, 2022Comments
-
Admin almost 2 years
Unfortunately I did upgrade PHP to version 5.3, but it end up breaking up some web apps, now I'm trying to go back to 5.2. I removed both sources php53.dotdeb.org from
/etc/apt/sources.list
and I didapt-get update && apt-get upgrade
, but it didn't downgrade anything.Any ideas on how to go back will be appreciated
Thanks
-
womble over 14 yearsProbably everything relating to PHP; Most good repos tag their package versions with a unique tag, like '
dotdeb
'; I expect thatdpkg -l |grep dotdeb
will probably list all of the relevant packages; you'll need toapt-cache policy <package>
to get the version you want to downgrade to.