Comments (6)
Possibly related to this particular issue is that the script hangs for me on Ubuntu Server 16.04 LTS:
# /etc/init.d/nginx start
[....] Starting nginx (via systemctl): nginx.service
^C <-- Waited for at least a minute before killing the script and yet...
# ps aux | grep nginx
root 3121 0.0 0.0 49312 3084 ? Ss 21:22 0:00 nginx: master process /usr/local/sbin/nginx -c /usr/local/nginx/conf/nginx.conf
www-data 3122 0.0 0.0 49312 5300 ? S 21:22 0:00 nginx: worker process
www-data 3123 0.0 0.0 49312 5300 ? S 21:22 0:00 nginx: worker process
# cat /etc/default/nginx
DAEMON=/usr/local/sbin/nginx
PIDSPATH=/var/run
# cat /var/run/nginx.pid
3121
On the flip side, a php-fpm init.d script I've used unchanged since Ubuntu 12.04 LTS still works great. I was using the 2009 version of this nginx init.d script, ran into the same script hanging issue, and updated to the latest version of this script in the hope that it would fix the issue. As evidenced above, it didn't.
Also of note: /etc/init.d/nginx stop
does not actually stop anything. It immediately exits and says [ ok ] Stopping nginx (via systemctl): nginx.service.
. service nginx stop
also does nothing.
My configure line for nginx is:
./configure --pid-path=/var/run/nginx.pid --sbin-path=/usr/local/sbin --with-http_ssl_module
Nothing fancy there.
July 2016 marks the release of 16.04.1 LTS. At that point, 16.04 LTS becomes generally available to all LTS users - of which, I'd wager most are running servers. I suspect there will be a LOT more +1's on this issue shortly after that happens.
from nginx-init-ubuntu.
Yes absolutely LTS is on the road map.
Should have it done by end of the month.
-Jason
On May 12, 2016, at 1:42 AM, AMK [email protected] wrote:
This is for Ubuntu 14.04 upstart script. Do you have any plan to update it for Ubuntu 16.04 to use systemd script.
Thanks.
Andrew—
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub
from nginx-init-ubuntu.
Great, thanks.
from nginx-init-ubuntu.
+1
from nginx-init-ubuntu.
FYI, I switched over to this script:
https://github.com/Fleshgrinder/nginx-sysvinit-script
From an active contributor on PHP internals and an officially recognized repo from the nginx side of things. Also, the script actually works out-of-the-box (I only had to configure the pid file) on Ubuntu 16.04 LTS. I'm not a fan of running make on an init.d script, but the makefile doesn't really do much.
from nginx-init-ubuntu.
I got an start up error of the nginx init script: PID file /usr/local/nginx/logs/nginx.pid not readable (yet?) after start: No such file or directory
Though, I tried modifying the init script and have configured nginx with: --pid-path=/var/run/nginx.pid --lock-path=/var/run/nginx.lock
The script mentioned by @cubiclesoft did very well without the need of modification but I am missing the console feedback as it's given in this script on start, restart, stop etc.
from nginx-init-ubuntu.
Related Issues (18)
- /etc/init.d/nginx: You don't have permissions to execute nginx. HOT 2
- /etc/init.d/nginx: 425: .: 3: Too many open files HOT 4
- . HOT 1
- Override of "NGINXPATH" (/etc/default/nginx) doesn't affect DAEMON variable HOT 4
- The settings in `/etc/default/nginx` is not updated to const defined earlier HOT 6
- spec-compliant status exit codes HOT 11
- /etc/init.d/nginx: 1: /etc/init.d/nginx: N: not found HOT 1
- There is a typo in the doc. HOT 4
- Get 502 on all sites after reload HOT 3
- Variable description in your README.md HOT 6
- Unable to stop nginx HOT 3
- Version Command
- better configuration instructions HOT 5
- nginx permissions denied
- Request to add umask HOT 1
- Ubuntu 20.04 - service nginx "reload" error HOT 1
- problem with "service nginx restart" HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nginx-init-ubuntu.