Redhat System Web server simple build and Web virtual host

Source: Internet
Author: User

Build environment: Redhat 5.8 httpd-2.2.3-63.el5.i386

HTTP protocol Simple introduction: Http:hyper Text Transfer Protocol: Hypertext Transfer Protocol, is a TCP based transmission mode, TCP transmission mode is 3 times handshake to establish the connection, four times disconnected. To resolve the slow connection speed, the local caching mechanism is added. Browser caching is the speed at which Web pages are accessed.

The way the Web server handles concurrent connection requests is as follows

1, single-threaded Web server (single-threaded Web servers)

In this schema, the Web server processes one request at a time and reads and processes the next request at the end. All other requests are ignored during a request processing, so there will be serious problems in scenarios where concurrent requests are more numerous.

2, multi-process/multi-threaded Web server

In this architectural approach, the Web server generates multiple processes or threads to process multiple user requests in parallel, and processes or threads can be generated on demand or in advance. Some Web server applications generate a separate process or thread to respond to each user request, but multiple simultaneous processes or threads will consume a significant amount of system resources once the number of concurrent requests reaches tens of thousands.

3. I/O multiplexing Web server

To be able to support more concurrent user requests, more and more Web servers are using multiple reusable architectures-synchronizing monitoring of the active state of all connection requests, and performing a series of specific actions for a connection when the state of a join changes (such as when data is ready or an error occurs); The connection is reset back to the temporary stable state and returned to the Open connections list until the next state change. Because of its multiplexing nature, processes or threads are not occupied by idle connections, thus providing an efficient mode of operation.

4. Multiplexing multi-threaded Web server

A Web server architecture that combines the functions of multiple processes and multiplexing to avoid allowing a process to serve too many user requests and to take full advantage of the computing power provided by multiple CPU hosts.

The following basic installation, testing of the Web server

1. Installation httpd

Yum Install httpd

Start a service

Service httpd Start

You can see the test page

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.