6 ms·
nginx is creating a name and market for itself as a reverse proxy, even though there are better solutions for reverse-proxies out there, everything from HAProxy
by jimjag 10y ago
nginx is creating a name and market for itself as a reverse proxy, even though there are better solutions for reverse-proxies out there, everything from HAProxy to Apache Traffic Server to even Apache httpd. But this is an important market to have. Why? Because it allows for the perception that the "web runs on nginx" simply because all you see are the nginx web proxies and nothing behind that.
So what are the servers behind nginx? 9 times out of 10 it is Apache httpd, and numerous instances of it at that. So for each single nginx server "seen" in these surveys, there are unknown multiples of Apache httpd behind the scenes doing the real work.
But all that messes up the popular, if incorrect, narrative that Apache httpd is dying and nginx is gobbling up instances. It's all about marketing baby, for a product that really isn't truly "open source" but more so open core. And people buy it hook, line, and sinker.
- vfaronov 10y ago> So what are the servers behind nginx? 9 times out of 10 it is Apache httpd, and numerous instances of it at that. Can you cite a source for this? In my practice, the servers behind nginx are usually platform-specific application servers, such as Gunicorn or uWSGI for Python.
- iamacynic 10y agoyeah, or just ... more nginx.
- snowwrestler 10y agoI think the idea is that if you count every single website on the web, a huge number of them are crappy little sites on shared hosting. Shared hosting usually relies on .htaccess rules, which are only valid under Apache. Popular PHP CMS software also relies on .htaccess. Wordpress for example allegedly powers about a quarter of all websites, and auto-creates an .htaccess file when you enable pretty links, which basically everyone does. Drupal ships with multiple .htaccess files. Sure it's possible to adapt this code into Nginx configuration, but there is really no reason to do that. It's far easier to set up Nginx in front of Apache and get most of the Nginx benefits that way.
- user5994461 10y agoOr tomcat / jboss / websphere for Java applications. There really are a lot of platforms. Equally, there is a truckload of LAMP sites out there (Linux Apache MySQL Php) to give Apache the edge on pure quantity. It's been the standard for personal site hosting and forums for two decades. That's a long lasting effect. That's not where there is value and work for developers though.
- ag_47 10y ago> even though there are better solutions for reverse-proxies out there... Apache Traffic Server to even Apache httpd Really? Completely disagree. Just look at the configuration files for these vs nginx.
- jimjag 10y agoSo your total criteria for what constitutes a "better reverse proxy" isn't performance, isn't lowest latency, isn't full HTTP compliance, isn't dynamic reconfiguration, or pluggable load balancing mechanisms but rather configuration files?? Sorry if I don't hold your opinion to that high a standard in that case.
- ag_47 10y agoYou're right, we should build a CloudFlare competitor based on ATS and take over the market.
- user5994461 10y agoConfiguration 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.
- jimjag 10y ago"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...
- user5994461 10y agoPerformance + 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.
- snug 10y ago> 9 times out of 10 it is Apache httpd, and numerous instances of it at that. A lot of your post is not wrong, but that statistic is just not right at all. Less that half of the time we see apache instances behind NGINX, and it's mostly because it's legacy, and hard to move away from it. The other half of the time it's application specific web servers, or other NGINX instances. Source: Worked for Cloudflare and now work at NGINX
- jimjag 10y agoOf course, as someone who works for NGINX I would guess you would see more nginx behind nginx. Based on discussions with people who do Apache httpd support as well as what I've personally seen, 90% isn't that far off the mark. People like using httpd for dynamic content. A lot.
- diminoten 10y agoTo summarize your point (and correct me if I'm mistaken), Apache httpd is legacy that people don't seem to want to make the effort to move off of, but still want the benefits of nginx, so they'll stand up nginx in front of httpd, rather than migrate off of Apache (and update their platforms to support that). I feel the "marketing" concept is less actual marketing and more feature appeal, but I guess that's similar? Maybe not, though. Features provide actual value, whereas marketing is ... tricksy.
- btb 10y agoApache httpd "legacy"? Seems a bit exaggerated. As far as I can tell it works just fine, have plenty of very good tutorials(like those from digital ocean), performance wise no problems(at least for our usage). And seems simpler to setup. At my work we use IIS for our main website, but I've been asked to setup and configure a few wordpress installations. I've played around with both nginx and apache, but it was much easier to find clear instructions to setup wordpress on apache, so thats what I went with. I also really like apaches .htaccess support. Easy to lock down access to wp-admin by just dropping a .htaccess file in there restricting access to local ip range, instead of having to pollute the nginx config file with that sort of thing.
- diminoten 10y ago"works just fine" is completely orthogonal to "legacy", same as "well documented", etc. The way you're writing, you sound like you've tried one (Apache), and not really the other (nginx) and are basing your opinion on that, not on any merit-based evaluation...
- sokerpart 10y agoYou forgot to mention, that you're Jim Jagielski, the director of The Apache Software Foundation, who carefully monitors nginx news and never miss an opportunity to say something bad about it. Haters gonna hate.
- sctb 10y agoWhen users have flagged comments for violating the guidelines, please don't post them again.