![]() ![]() In nginx, the syntax for such a setup is quite concise: We can setup nginx to handle all incoming requests, and have nginx distribute the requests to an arbitrary number of upstream Apache servers for handling. We could beef up the Apache server a bit (more RAM, another CPU), or we could start to scale up with more servers. The application gets a lot of traffic, and the current Apache server can no longer be performant with the number of client requests. Let’s say we have a Ruby on Rails application running on Phusion Passenger on Apache HTTP. I hope that you’ll find them informative and helpful. The rest of this post will contain nginx configuration examples which I have used when setting up and maintaining applications and network infrastructures for both Atomic Object and our clients. Using nginx in this way, it is not difficult to create a readily scalable solution for a given web-application to handle a huge number of simultaneous requests. ![]() The client requests can all be for a single service or application (load balancing) or for a variety of different services and applications which live together on an internal network (reverse proxying). This makes nginx an excellent load balancer and reverse proxy - a single nginx server can handle the large number of incoming concurrent client connections and distribute them to number of different of upstream servers to actually handle the client requests. While both nginx and Apache HTTP are capable of handling a large number of requests per second, nginx can handle a larger number of concurrent requests without severe performance degradation and the increased memory usage seen in Apache under the same conditions (nginx relies on a non-blocking I/O, event-driven model while Apache relies on threads which may block on I/O). It is capable of handling a huge number of concurrent client connections easily (see the C10K problem). Nginx is a modern, open-source, high-performance web server. Read the new version, published July 2013.**
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |