0

I was trying to downgrade PHP back to 5.4 (my website became amazingly slow after upgrade). I followed the first step from this guide : How to downgrade PHP from 5.5.9 to 5.4 in Ubuntu 14.04 (Installed with LAMP)

Now I am stuck with not being able to install PHP5 anymore with

Get:1 http://de.archive.ubuntu.com/ubuntu/ trusty-updates/main php5 all 5.5.9+dfsg-1ubuntu4.25 [1,308 B]
Fetched 1,308 B in 0s (31.9 kB/s)
(Reading database ... 63966 files and directories currently installed.)
Removing phpmyadmin (4:4.0.10-1) ...
dpkg: error processing package phpmyadmin (--remove):
 subprocess installed post-removal script returned error exit status 10
Errors were encountered while processing:
 phpmyadmin
E: Sub-process /usr/bin/dpkg returned an error code (1)

How can I solve that?

I tried to get the install to complete with apt-get -f install but got that :

Reading package lists... Done
Building dependency tree
Reading state information... Done
The following packages will be REMOVED:
  phpmyadmin
0 upgraded, 0 newly installed, 1 to remove and 0 not upgraded.
1 not fully installed or removed.
After this operation, 23.0 MB disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 63213 files and directories currently installed.)
Removing phpmyadmin (4:4.0.10-1) ...
dpkg: error processing package phpmyadmin (--remove):
 subprocess installed post-removal script returned error exit status 10
Errors were encountered while processing:
 phpmyadmin
E: Sub-process /usr/bin/dpkg returned an error code (1)

Ubuntu 16.04.3

Tried to reboot, still same situation

-1

The Apt database is locked. Someone else is just trying to install something else. Maybe it's you in another terminal or maybe you have Synaptic Package Manager running. Try to find it by grep-ing your processes:

ps -ef | grep apt

or

ps -ef | grep synaptic

just try to exit or kill this application with kill -15 and try to install again.

  • Where did you get that idea? There's no hint as to a locked package database. The issue is the post-removal script of a package. -1 – David Foerster Jun 4 '18 at 9:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.