Não é possível remover o apache2 do ubuntu16.04

0

Estou tentando desinstalar o apache2 usando apt-get purge apache2 está mostrando isso

root@indrajit-MacBookPro:/home/indrajit# apt-get purge apache2
Reading package lists... Done
Building dependency tree       
Reading state information... Done
You might want to run 'apt-get -f install' to correct these:
The following packages have unmet dependencies:
 apache2-suexec : Depends: apache2.2-common but it is not going to be installed
E: Unmet dependencies. Try 'apt-get -f install' with no packages (or specify a solution).

Tentou executar apt-get -f install e também está falhando. Aqui está a saída.

root@indrajit-MacBookPro:/home/indrajit# apt-get -f install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following packages were automatically installed and are no longer required:
  apache2-data gstreamer0.10-gconf gstreamer0.10-plugins-good
  gstreamer0.10-pulseaudio gstreamer0.10-x libcdaudio1 libdirectfb-1.2-9
  libenca0 libmpcdec6 libslv2-9 linux-headers-4.4.0-31
  linux-headers-4.4.0-31-generic linux-headers-4.4.0-71
  linux-headers-4.4.0-71-generic linux-image-4.4.0-31-generic
  linux-image-4.4.0-71-generic linux-image-extra-4.4.0-31-generic
  linux-image-extra-4.4.0-71-generic snap-confine
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  apache2.2-bin apache2.2-common
Suggested packages:
  apache2-doc
The following NEW packages will be installed:
  apache2.2-bin apache2.2-common
0 upgraded, 2 newly installed, 0 to remove and 616 not upgraded.
2 not fully installed or removed.
Need to get 0 B/1,572 kB of archives.
After this operation, 4,512 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 301525 files and directories currently installed.)
Preparing to unpack .../apache2.2-bin_2.2.22-1ubuntu1.11_amd64.deb ...
Unpacking apache2.2-bin (2.2.22-1ubuntu1.11) ...
dpkg: error processing archive /var/cache/apt/archives/apache2.2-bin_2.2.22-1ubuntu1.11_amd64.deb (--unpack):
 trying to overwrite '/usr/lib/apache2/modules/mod_authnz_ldap.so', which is also in package apache2-bin 2.4.18-2ubuntu3.8
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Preparing to unpack .../apache2.2-common_2.2.22-1ubuntu1.11_amd64.deb ...
Unpacking apache2.2-common (2.2.22-1ubuntu1.11) ...
dpkg: error processing archive /var/cache/apt/archives/apache2.2-common_2.2.22-1ubuntu1.11_amd64.deb (--unpack):
 trying to overwrite '/usr/share/apport/package-hooks/apache2.py', which is also in package apache2-bin 2.4.18-2ubuntu3.8
dpkg-deb: error: subprocess paste was killed by signal (Broken pipe)
Processing triggers for systemd (229-4ubuntu17) ...
Processing triggers for ureadahead (0.100.0-19) ...
Processing triggers for ufw (0.35-0ubuntu2) ...
Errors were encountered while processing:
 /var/cache/apt/archives/apache2.2-bin_2.2.22-1ubuntu1.11_amd64.deb
 /var/cache/apt/archives/apache2.2-common_2.2.22-1ubuntu1.11_amd64.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

mas quando eu tento localizar o apache2 ele está mostrando

root@indrajit-MacBookPro:/home/indrajit# which apache2
/usr/sbin/apache2

como desinstalar that.its realmente needed.Thanks pela sua ajuda

    
por indrajit guha 23.05.2018 / 12:04

1 resposta

0

Como mencionado no comando, resolvo o problema desinstalando libapache2-mod-fastcgi via apt-get purge libapache2-mod-fastcgi e apache2-suexec via apt-get purge apache2-suexec . finalmente

apt-get purge apache2
    
por indrajit guha 23.05.2018 / 22:15