Deepin 安装 nginx 过程出现 nginx-full 尚未配置。具体报错:
正在设置 nginx-full (1.13.12-1) ... 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. ● 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 Tue 2018-11-27 11:07:01 CST; 6ms ago Docs: man:nginx(8) Process: 15531 ExecStart=/usr/sbin/nginx -g daemon on; master_process on; (code=exited, status=1/FAILURE) Process: 15523 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=0/SUCCESS) 11月 27 11:06:59 wecot nginx[15531]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) 11月 27 11:06:59 wecot nginx[15531]: nginx: [emerg] bind() to [::]:80 failed (98: Address already in use) 11月 27 11:07:00 wecot nginx[15531]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) 11月 27 11:07:00 wecot nginx[15531]: nginx: [emerg] bind() to [::]:80 failed (98: Address already in use) 11月 27 11:07:00 wecot nginx[15531]: nginx: [emerg] bind() to 0.0.0.0:80 failed (98: Address already in use) 11月 27 11:07:00 wecot nginx[15531]: nginx: [emerg] bind() to [::]:80 failed (98: Address already in use) 11月 27 11:07:01 wecot nginx[15531]: nginx: [emerg] still could not bind() 11月 27 11:07:01 wecot systemd[1]: nginx.service: Control process exited, code=exited status=1 11月 27 11:07:01 wecot systemd[1]: nginx.service: Failed with result 'exit-code'. 11月 27 11:07:01 wecot systemd[1]: Failed to start A high performance web server and a reverse proxy server. dpkg: 处理软件包 nginx-full (--configure)时出错: installed nginx-full package post-installation script subprocess returned error exit status 1 dpkg: 依赖关系问题使得 nginx 的配置工作不能继续: nginx 依赖于 nginx-full (<< 1.13.12-1.1~) | nginx-light (<< 1.13.12-1.1~) | nginx-extras (<< 1.13.12-1.1~);然而: 软件包 nginx-full 尚未配置。 未安装软件包 nginx-light。 未安装软件包 nginx-extras。 nginx 依赖于 nginx-full (>= 1.13.12-1) | nginx-light (>= 1.13.12-1) | nginx-extras (>= 1.13.12-1);然而: 软件包 nginx-full 尚未配置。 未安装软件包 nginx-light。 未安装软件包 nginx-extras。 dpkg: 处理软件包 nginx (--configure)时出错: 依赖关系问题 - 仍未被配置 在处理时有错误发生: nginx-full nginx E: Sub-process /usr/bin/dpkg returned an error code (1)
原因:已经安装了 apache ,并且apache 正处于运行状态。
解决:停掉 apache 服务或删除apache相关文件
service apache2 stop #停止apache 服务 sudo apt-get --purge remove apache2 # 删除包和配置文件 sudo apt-get install nginx