Advantages and disadvantages of Apache and nginx: nginx concurrency wins

Source: Internet
Author: User

Advantages of nginx

A) Lightweight and Web Services, which consume less memory and resources than Apache

B.) Anti-concurrency. nginx processes Requests asynchronously and non-blocking, while Apache is blocking. In high concurrency, nginx can maintain low resource consumption and high performance.

C) highly modular design, relatively simple Writing module

D. The community is active, and various high-performance modules are produced quickly.

Advantages of Apache

A.) rewrite, which is more powerful than nginx rewrite

B) There are too many modules, and you can find all of them.

C. fewer bugs and more nginx bugs

D) ultra-stable
The core difference is that Apache is a synchronous multi-process model. One connection corresponds to one process. nginx is asynchronous. Multiple connections (tens of thousands of connections) can correspond to one process.

 

Differences between APACHE and nginx

1. Compared with Apache, nginx uses fewer resources and supports more concurrent connections, reflecting higher efficiency. In the case of high-connection concurrency, nginx is a good alternative to the Apache server. It can support responses with up to 50,000 concurrent connections.

2. nginx as a server Load balancer server: nginx supports both rails and PHP programs for external services and HTTP proxy servers. nginx is written in C. Both system resource overhead and CPU usage are much more efficient than perlbal.

3. As a mail proxy server: nginx is also a very good mail proxy server.

4. nginx is a simple installation, and the configuration file is very simple (it also supports Perl syntax). For servers with very few bugs: nginx is particularly easy to start, in addition, it can run almost without interruption and does not need to be restarted even if it runs for several months. you can upgrade the software without interruption.

5. nginx processes static files well and consumes less memory
6. The load capacity of nginx is much higher than that of Apache. There are many cluster sites, front-end nginx anti-concurrency, and backend Apache clusters, with good cooperation.

7. nginx is superior to Apache in the following two aspects: 1. nginx itself is a reverse proxy server 2. nginx supports layer-7 Server Load balancer. In other cases, nginx may support a higher concurrency than Apache. However, according to Netcraft statistics, Apache still occupies April 2011 of the statistics in 62.71%, nginx is 7.35%, so in general, aapche is still the first choice of most companies, because its mature technology and development community are already very good performance.

8. Apache has an advantage in Processing dynamic data, nginx has good concurrency, and CPU memory usage is low. If rewrite is frequent, it should be Apache.

Which one should you choose? See how to select nginx and Apache
 

Original article title: Advantages and Disadvantages of Apache and nginx concurrent wins

Address: http://www.abcde.cn/info/show-25-61-1.html

Copyright belongs to the Internet era. For more information, see the source.


This article from the "Network Age" blog, please be sure to keep this source http://abcdeceo.blog.51cto.com/9097642/1435338

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.