"Guide" This article focuses on installing a Web server--apache with proxy and override rule features on the corporate firewall, as well as concrete steps for compiling and setting up Apache. After a successful installation, flexible virtual host settings allow external users to access multiple Web servers on the internal LAN via a firewall.
test environment and network structure
The test environment used in this article is Redhat Linux 7.2, Apache 1.3.24, the company domain name assumption is company.com.
The typical network structure of the company is shown in the attached figure.
Note: 2 network cards are installed on the firewall in the drawings, where the external public address of the E0 port is the 1.2.3.4,E1 port corresponding to the internal reserved address of 192.168.2.1. There are 3 Web servers within the LAN, A, B, and C, and their corresponding domain names are weba.company.com, webb.company.com, and webc.company.com, each with an internal reserved address.
Second, the Operation steps
As shown in the attached picture, the company is connected to the Internet via a dedicated line, has a firewall installed, there are 3 Web servers inside the LAN, only internal reserved address, but hope they can provide external Web services.
1. Setting up DNS
The DNS,IP address for setting up the internal 3 Web servers on the firewall (which is also the company's DNS server) is 1.2.3.4. In this way, when parsing weba.company.com, webb.company.com, and webc.company.com on the Internet, it points to the external interface address 1.2.3.4 of the same IP address, the firewall.
2. Download Apache
Download the current version of the Apache 1.3.24 to the/root directory from the Apache website (http://www.apache.org) and download the address for http://www.apache.org/dist/httpd/apache_1.3.24.tar.gz.
3. Change the source code so that the maximum allowable number of requests connected to more than 256
Because Apache defaults to allow a maximum number of connections of 256, the number of connections on a busy Web site may not be enough, especially if this article describes the use of the Apache reverse proxy on the firewall to allow external users access to multiple internal Web servers, you can change src/ Include/httpd.h the method of the file, the concrete steps are as follows.