Live data from Hacker News

Nginx has replaced Apache as the most used web server among the top 10,000 sites

w3techs.com

51–60 of 76 posts

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#51
post #4

Earlier quoted context omitted.

Nginx is used as a reverse proxy for less strong application servers. IMHO (and experience) doing it for Apache would be pretty useless.

Depends heavily on how you have configured Apache. If you are using something like PHP and the forking model (most common MPM configuration), you can only handle as many requests as you have workers; additionally you are spinning up a full PHP interpreter when serving static assets. In my experience[1], putting Nginx in front of Apache to serve static assets and leaving Apache as a sort of application server is one o…

I'd agree, but I suspect that anybody who cares about PHP-performance has probably already moved to FPM.

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#53
post #34

Earlier quoted context omitted.

I disagree. I don't care if nginx is in front of apache, varnish, or some ruby or python web server. If nginx is what serves the final request to the client, it's the webserver. Period. edit: nginx is the last mile. You can't say everyone in the USA has access to fiber because further upstream their traffic traverses a fiber network. Their last mile is DSL/Cable/etc. When it comes to the user experience, last mile is…

By that logic, the webserver would be the last thing in front of the user, their router, their ISP, whatever...

I dont agree. Their router processes data below the application layer. Thus why not define the webserver as the last server to serve at the http layer ?

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#55
post #28

Did anyone else pause when they read the title line... "Usage of web servers broken down by ranking". I'm picturing a graph of the most commonly broken web servers for half a second.

I'll take the downvotes as a "no we didn't, and we think you are trying to be funny".

But, I actually did read that for a half a second and think the phrase "broken down" can be done without. It doesn't add anything in my opinion, I know it is broken down (its a graph), the phrase is unnecessary, and it caused me at least to stumble mentally for half an instant.

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#56

How can I tell, by visiting a site, what web server is being used?

curl -I www.ycombinator.com

This gives you the HTTP Header, example output: HTTP/1.1 301 Moved Permanently Server: nginx Date: Mon, 26 May 2014 16:11:30 GMT Content-Type: text/html Content-Length: 178 Connection: keep-alive Location: http://ycombinator.com/

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#57
post #56

How can I tell, by visiting a site, what web server is being used?

curl -I www.ycombinator.com This gives you the HTTP Header, example output: HTTP/1.1 301 Moved Permanently Server: nginx Date: Mon, 26 May 2014 16:11:30 GMT Content-Type: text/html Content-Length: 178 Connection: keep-alive Location: http://ycombinator.com/

Oh wow, that's cool. I didn't know that. Thanks.

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#59
post #4

Earlier quoted context omitted.

Nginx is used as a reverse proxy for less strong application servers. IMHO (and experience) doing it for Apache would be pretty useless.

Depends heavily on how you have configured Apache. If you are using something like PHP and the forking model (most common MPM configuration), you can only handle as many requests as you have workers; additionally you are spinning up a full PHP interpreter when serving static assets. In my experience[1], putting Nginx in front of Apache to serve static assets and leaving Apache as a sort of application server is one o…

> additionally you are spinning up a full PHP interpreter when serving static assets.

I think that if you do this you are one RewriteRule away from doing it right.

> In my experience[1], putting Nginx in front of Apache to serve static assets and leaving Apache as a sort of application server

I also think that using nginx only for static content is wasting perfectly good resources for nothing. Apache can serve static assets just as good as nginx does. No need for an other layer in your stack.

Re: Nginx has replaced Apache as the most used web server among the top 10,000 sites

#60
We abandoned Apache as we found configuring Tomcat with Apache to be a major pain whereas configuring NGINX with Tomcat or other J2EE application servers is almost a no-brainer. Ditto with SSL termination. Since then we've moved all static file serving to NGINX as having both Apache and NGINX did not make sense. I know that a lot of other JVM shops did the same.
Post reply on HN