Sorry but it only posted a small part of what I did here is the rest:
apt-get remove apache2-mpm-prefork apache2-utils apache2.2-common
libapache2-mod-php5 libapr1 libaprutil1 libdbd-mysql-perl libdbi-perl
libnet-daemon-perl libplrpc-perl libpq5 mysql-client-5.0 mysql-common
mysql-server mysql
I had that problem too, I don't know what exactly I did to fix it so I'll just
put it all here.
First to become a root, and also so I did not need to enter my password with
each line I ran:
sudo -i
Then I removed the lamp packages with:
dpkg --configure -a
apt-get --purge remove apache2