repetido nginx ubuntu 16.04 error on update install [duplicado]

1

Toda vez que executo sudo apt-get update , um erro é lançado em relação ao nginx.

The following NEW packages will be installed:
nginx
0 upgraded, 1 newly installed, 0 to remove and 2 not upgraded.
1 not fully installed or removed.
Need to get 0 B/3.498 B of archives.
After this operation, 37,9 kB of additional disk space will be used.
Selecting previously unselected package nginx.
(Reading database ... 542828 files and directories currently installed.)
Preparing to unpack .../nginx_1.10.0-0ubuntu0.16.04.4_all.deb ...
Unpacking nginx (1.10.0-0ubuntu0.16.04.4) ...
Setting up nginx-full (1.10.0-0ubuntu0.16.04.4) ...
Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details.
invoke-rc.d: initscript nginx, action "start" failed.
dpkg: error processing package nginx-full (--configure):
subprocess installed post-installation script returned error exit   status 1
dpkg: dependency problems prevent configuration of nginx:
nginx depends on nginx-core (>= 1.10.0-0ubuntu0.16.04.4) | nginx-full    (>= 1.10.0-0ubuntu0.16.04.4) | nginx-light (>= 1.10.0-0ubuntu0.16.04.4) |   nginx-extras (>= 1.10.0-0ubuntu0.16.04.4); however:
Package nginx-core is not installed.
Package nginx-full is not configured yet.
Package nginx-light is not installed.
Package nginx-extras is not installed.
nginx depends on nginx-core (<< 1.10.0-0ubuntu0.16.04.4.1~) | nginx- full (<< 1.10.0-0ubuntu0.16.04.4.1~) | nginx-light (<< 1.10.0-  0ubuntu0.16.04.4.1~) | nginx-extras (<< 1.10.0-0ubuntu0.16.04.4.1~);  however:
Package nginx-core is not installed.
Package nginx-full is not configured yet.
Package nginx-light is not installed.
Package nginx-extras is not installed.

dpkg: error processing package nginx (--configure):
dependency problems - leaving unconfigured
No apport report written because the error message indicates its a   followup error from a previous failure.
                      Errors were encountered while processing:
nginx-full
nginx
E: Sub-process /usr/bin/dpkg returned an error code (1)

Eu tentei resolver como sugerido em outras postagens sem sucesso:

sudo apt-get remove nginx
sudo apt-get -f install    # (as mentioned in this post)
$ systemctl status nginx.service
nginx.service - A high performance web server and a reverse proxy server
Loaded: loaded (/lib/systemd/system/nginx.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Mo 2016-11-07 21:05:51 CET; 7min ago
Process: 10372 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=1/FAILURE)

Eu também tentei o seguinte ... quando o erro persistir.

apt purge nginx
apt autoremove
apt install nginx

Quantas opções tenho aqui para seguir o caminho certo?

Devo tentar desinstalar / desativar o apache2?

    
por danny_C_O_T_W 07.11.2016 / 21:23

1 resposta

1

Desligar o apache2 antes de instalar o nginx deve corrigir esse problema.

pare o apache2

sudo systemctl stop apache2.service

impede que o apache2 inicie na inicialização

sudo systemctl disable apache2.service

Reinstale o nginx

sudo apt-get install nginx
    
por Navaneeth M 13.11.2016 / 09:23