Live data from Hacker News

Nginx reaches 33.3% web server market share while Apache falls below 50%

w3techs.com

171–180 of 190 posts

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#171

"Just to put that growth rate in perspective: this is 70 times the number of sites that switch to Node.js, another fast-growing web server." I find it hard to believe this could be accurate considering the vast majority of Node.js deployments are also utilizing Nginx as a reverse-proxy in front of it. I think a large portion of nginx's uptake is actually due to Node.js' popularity.

Yeah - I think "put this behind nginx" is pretty standard practice for nodejs projects. I mean, even for relative beginners, advice like this is common (and sound)

https://www.digitalocean.com/community/tutorials/how-to-host...

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#172
post #130

Earlier quoted context omitted.

Configuration files are important. You understand that once you have to untangle thousands upon thousands of lines of apache configuration. Luckily for me, that can pay a decent rate :D In the context of load balancing, on the performance + latency + load balancing mechanism + configuration files criteria, Apache is the worst by a huge margin compared to both HAProxy and nginx.

"performance + latency + load balancing mechanism" Maybe 5-7 years ago then yeah... maybe. Not even close today. Apache has lowest latency and faster total transaction time based on various benchmarks. It all depends on how you are using it. "configuration files criteria" Got me there. But then again, 2.4 adds a LOT of ways to even streamline that, like mod_macro, mod_define, etc...

Performance + latency => I dunno what world you live in. Apache is still stuck in the prefork era (not that it's mandatory but it is how it works most of the time). It's not even playing in the same order of magnitude.

Load balancing => Apache doesn't even support healthchecks. I won't even get into the lack of TCP/TLS support or the lack of some load balancing algorithms.

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#173

Huh, I'm surprised Apache is still so high? Are there huge hosting sites that use it or something? Wordpress? I (and I know no one) who has reached for Apache over NGINX in a decade.

Of course. I don't know how you would even do shared hosting with nginx, as I don't think it has a .htaccess equivalent, and restarting the server for everyone else wouldn't be acceptable

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#174
post #130

Earlier quoted context omitted.

"performance + latency + load balancing mechanism" Maybe 5-7 years ago then yeah... maybe. Not even close today. Apache has lowest latency and faster total transaction time based on various benchmarks. It all depends on how you are using it. "configuration files criteria" Got me there. But then again, 2.4 adds a LOT of ways to even streamline that, like mod_macro, mod_define, etc...

Performance + latency => I dunno what world you live in. Apache is still stuck in the prefork era (not that it's mandatory but it is how it works most of the time). It's not even playing in the same order of magnitude. Load balancing => Apache doesn't even support healthchecks. I won't even get into the lack of TCP/TLS support or the lack of some load balancing algorithms.

I don't know what world you live in, but Apache only runs prefork if you configure it to run in prefork. Saying that is "how it works most of the time" is complete and total nonsense. I don't even know how to parse that...

Also complete and total nonsense is the lack of health checks (which is, iirc, only available for paid nginx), TLS support and load balancing algos. I think nginx has some kind of hash LB method that httpd doesn't, although httpd has round-robin, byrequests, bytraffic, and bybusyness.

Wow.

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#175

Earlier quoted context omitted.

> event doesn't support HTTPS, or rather, it stops being event-based when you turn on HTTPS Have you got any reference to this? I think I should have noticed, having run Apache with fairly bursty traffic. The only reference in the documentation was a four year old one, which said it was problematic six years prior to that... I find the Event MPM to be very stable under pressure and unless you have some really specifi…

Hmm, it seems like it works now in 2.4. That's a reason to keep Apache but I still can't see a reason to run anything new on it.

2.4 is only five years old. 2.2 is more likely, if it was fixed ten years ago. In the few cases I have built Apache I usually don't bother with DSOs, and I usually run only the Event MPM.

The basis you pick your web server on shouldn't be whether it's "new" or "old". It is what your software runs on, what support contracts you have, and what functionality you need. But don't use it if you can't configure it. Preferrably your organization should have knowledge about every piece of software in production.

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#176

So I reckon Docker & PHP7/HHVM have contributed for sure. So much easier deploying Nginx - not to mention just plain nicer.

Shame that Apache httpd 2.4 w/ HHVM is actually fastest: https://www.youtube.com/watch?v=JNbKJ22DS10

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#177
post #158

Earlier quoted context omitted.

PHP is definitely a huge chunk of the reason why nginx has taken over Apache. php-fpm with nginx is the defacto standard , and PHP is far more prevalent than a lot of people think. Apache's mod_php(X) vs. nginx+php-fpm isn't even a debate. If someone is currently using Apache+mod_php, they probably have a smaller product that will eventually have to switch to nginx+fpm in order to scale. While I imagine PHP is the si…

fpm is being dropped now that php 7 contains many of the improvements that made fpm popular. php_mod+apache with .htaccess turned off is the faster stack. Put a nginx server to server static content in front and that's the fastest stack going forward

FPM isn't just popular because of speed. Its popular because of pools and the fact that its not a giant security risk by having it installed. mod_php shares permissions across everything it executes. If you have any site on the same Apache stack as another, they're accessible to each other as far as PHP is concerned. This makes the attack surface of a website significantly larger unless you're hosting exactly one site you have locked down to one directory.

I also really doubt that php7.1 mod and apache without .htaccess is faster than nginx and php7.1-fpm under 'ondemand' mode. Even a 5$ DO server can handle hundreds of requests a second to big frameworks like Drupal or Mediawiki, and they're securely seperated. Locking down permissions on a group level to the executing php-pool, so you can then make only specific users belong to that pool and bind a directory in their home to the actual website location.

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#178
post #174

Earlier quoted context omitted.

Performance + latency => I dunno what world you live in. Apache is still stuck in the prefork era (not that it's mandatory but it is how it works most of the time). It's not even playing in the same order of magnitude. Load balancing => Apache doesn't even support healthchecks. I won't even get into the lack of TCP/TLS support or the lack of some load balancing algorithms.

I don't know what world you live in, but Apache only runs prefork if you configure it to run in prefork . Saying that is "how it works most of the time" is complete and total nonsense. I don't even know how to parse that... Also complete and total nonsense is the lack of health checks (which is, iirc, only available for paid nginx), TLS support and load balancing algos. I think nginx has some kind of hash LB method t…

There are numerous modules and setup stuck in prefork mode. And the alternative with workers is a joke compared to the event loop of HAProxy and nginx.

HAProxy > nginx > apache

Of course if you compare apache to nginx, you can find stuff where nginx is lacking too.

Agreed, a lot of critical features are stripped in the open source nginx.

TLS = tcp with tls, not https.

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#179

Earlier quoted context omitted.

I assume boznz meant an entire (different) article could be written with that headline. One can certainly call this or the theoretical opposite article spin.

You could maybe write three sentences on "still a lot of Apache". It's the changes that you need to learn about.

I could certainly write a lot more than that on the topic, as could any decent writer. What one needs to learn about and one writes about is not necessarily the same thing. Again, I think the original comment here was more of a general statement about the manipulability of statistical analysis "articles".

Re: Nginx reaches 33.3% web server market share while Apache falls below 50%

#180

Earlier quoted context omitted.

You could maybe write three sentences on "still a lot of Apache". It's the changes that you need to learn about.

I could certainly write a lot more than that on the topic, as could any decent writer. What one needs to learn about and one writes about is not necessarily the same thing. Again, I think the original comment here was more of a general statement about the manipulability of statistical analysis "articles".

You can write an article about anything in the world. But when it comes to statistical analysis then in a pretty objective sense there is only one interesting thing to say about this data. Despite theoretical ability to be manipulative, only one of these two angles qualifies as news.
Post reply on HN