আমি সম্প্রতি আমার উবুন্টু সার্ভারটি 16.04 সংস্করণে আপগ্রেড করেছি। তারপর থেকে আমি nginx পরিষেবা শুরু করতে পারবেন না।
ফলাফল service nginx restart
:
Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details.
আমার সিস্টেম লগ কি বলে ( cat /var/log/syslog
):
May 20 17:03:53: Stopped A high performance web server and a reverse proxy server.
May 20 17:03:53: Starting A high performance web server and a reverse proxy server...
May 20 17:03:53: nginx.service: Failed at step EXEC spawning /usr/sbin/nginx: No such file or directory
May 20 17:03:53: nginx.service: Control process exited, code=exited status=203
May 20 17:03:53: Failed to start A high performance web server and a reverse proxy server.
May 20 17:03:53: nginx.service: Unit entered failed state.
May 20 17:03:53: nginx.service: Failed with result 'exit-code'.
এর ফলাফল cat /lib/systemd/system/nginx.service
:
# Stop dance for nginx
# =======================
#
# ExecStop sends SIGSTOP (graceful stop) to the nginx process.
# If, after 5s (--retry QUIT/5) nginx is still running, systemd takes control
# and sends SIGTERM (fast shutdown) to the main process.
# After another 5s (TimeoutStopSec=5), and if nginx is alive, systemd sends
# SIGKILL to all the remaining processes in the process group (KillMode=mixed).
#
# nginx signals reference doc:
# http://nginx.org/en/docs/control.html
#
[Unit]
Description=A high performance web server and a reverse proxy server
After=network.target
[Service]
Type=forking
PIDFile=/run/nginx.pid
ExecStartPre=/usr/sbin/nginx -t -q -g 'daemon on; master_process on;'
ExecStart=/usr/sbin/nginx -g 'daemon on; master_process on;'
ExecReload=/usr/sbin/nginx -g 'daemon on; master_process on;' -s reload
# Use TERM instead of QUIT to prevent Nginx from leaving stale Unix socket and failing the next start (https://trac.nginx.org/nginx/ticket/753)
ExecStop=-/sbin/start-stop-daemon --quiet --stop --retry TERM/5 --pidfile /run/nginx.pid
# Give Passenger a chance to clean up before being killed by systemd.
ExecStop=/bin/sleep 1
TimeoutStopSec=5
KillMode=mixed
[Install]
WantedBy=multi-user.target
প্রকৃতপক্ষে কোন ফাইল নেই /usr/sbin/nginx
, তাই আমি চেষ্টা করেছি apt install nginx
, কিন্তু এখানে ফলাফল:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:
The following packages have unmet dependencies:
nginx : Depends: nginx-core (>= 1.10.0-0ubuntu0.16.04.4) but it is not going to be installed or
nginx-full (>= 1.10.0-0ubuntu0.16.04.4) but it is not going to be installed or
nginx-light (>= 1.10.0-0ubuntu0.16.04.4) but it is not going to be installed or
nginx-extras (>= 1.10.0-0ubuntu0.16.04.4) but it is not going to be installed
Depends: nginx-core (< 1.10.0-0ubuntu0.16.04.4.1~) but it is not going to be installed or
nginx-full (< 1.10.0-0ubuntu0.16.04.4.1~) but it is not going to be installed or
nginx-light (< 1.10.0-0ubuntu0.16.04.4.1~) but it is not going to be installed or
nginx-extras (< 1.10.0-0ubuntu0.16.04.4.1~) but it is not going to be installed
E: Unable to correct problems, you have held broken packages.
আপডেট 1:
ফলাফল systemctl status nginx.service
চলমান পরে updatedb
:
● 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 Sat 2017-05-20 17:41:49 CEST; 1min 30s ago
Docs: man:nginx(8)
Process: 11212 ExecStart=/usr/sbin/nginx -g daemon on; master_process on; (code=exited, status=1/FAILURE)
Process: 11210 ExecStartPre=/usr/sbin/nginx -t -q -g daemon on; master_process on; (code=exited, status=0/SUCCESS)
May 20 17:41:48 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use)
May 20 17:41:48 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] listen() to 0.0.0.0:80, backlog 511 failed (98: Address already in use)
May 20 17:41:48 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use)
May 20 17:41:49 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] listen() to 0.0.0.0:80, backlog 511 failed (98: Address already in use)
May 20 17:41:49 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] listen() to [::]:80, backlog 511 failed (98: Address already in use)
May 20 17:41:49 ns3031916.ip-178-32-217.eu nginx[11212]: nginx: [emerg] still could not bind()
May 20 17:41:49 ns3031916.ip-178-32-217.eu systemd[1]: nginx.service: Control process exited, code=exited status=1
May 20 17:41:49 ns3031916.ip-178-32-217.eu systemd[1]: Failed to start A high performance web server and a reverse proxy server.
May 20 17:41:49 ns3031916.ip-178-32-217.eu systemd[1]: nginx.service: Unit entered failed state.
May 20 17:41:49 ns3031916.ip-178-32-217.eu systemd[1]: nginx.service: Failed with result 'exit-code'.
একটি নববধূ হিসাবে, আমি যে জগাখিচুড়ি মধ্যে বেশ হারিয়ে গেছে এবং আমি বাস্তব সাহায্য একটি বিট প্রয়োজন।
আপনার সময় জন্য আপনাকে অনেক ধন্যবাদ.
updatedb
, এখনও একটি ত্রুটি বার্তা আছে: Job for nginx.service failed because the control process exited with error code. See "systemctl status nginx.service" and "journalctl -xe" for details.
কিন্তু এটি শেষ থেকে ভিন্ন। আপনি এর ফলাফল দেখতে চান systemctl status nginx.service
মধ্যে আপডেট 1