Page compression: You can increase the speed of your application and do not require any costs.
Web caching: A page cache that does not change or changes very infrequently, and the next time the browser accesses these pages again, it does not need to download the pages again, thereby increasing the user's access speed.
Lab requirements: Two virtual machines, one Linux virtual machine, one Windows virtual machine. Linux virtual machine installation apache,windows Virtual machine Install grab kit is used to verify.
Experimental steps:
(a) page compression
1. Unzip the httpd, Apr, Apr-util installation package into the/OPT directory
Tar zxvf apr-1.4.6.tar.gz-c/opt/
Tar zxvf apr-util-1.4.1.tar.gz-c/opt/
Tar zxvf httpd-2.4.2.tar.gz-c/opt/
2. Switch to the OPT directory and copy the extracted folders recursively into the Apr folder
3. Installing GCC, gcc-c++, Pcre, Pcre-devel, zlib-devel kits with the Yum repository
4. Configure configuration Files
5. Converting to a binary file and installing it
6. Turn on the HTTPD function and establish a soft connection
7. Under httpd Master profile/etc/httpd.conf, modify the IP and hostname domain that listens to the local host
- Turn on the httpd service to turn off firewalls and enhanced security features
Service httpd Start
Service Iptables Stop
Setenforce 0
9. Open the module in the Apache master configuration file/etc/httpd.conf
10. At the end of the Apache master configuration file, add
11. Verify that the script is in/usr/local/httpd/bin, execute./apachectl-t, restart the httpd service, and see if the authentication module is turned on.
12. Enable the capture kit on the Windows virtual machine to verify
(ii) Web caching
1. Configure Configuration Files
2. Converting to a binary file and installing it
3. Turn on the HTTPD function and establish a soft connection
4. Under httpd Master profile/etc/httpd.conf, modify the IP and hostname domain that listens to the local host
5. Turn on the httpd service to turn off firewall and enhanced security features
Service httpd Start
Service Iptables Stop
Setenforce 0
6. Open the module in the Apache Master Profile/etc/httpd.conf and add it at the end of the configuration file
7. Check that the verification module is turned on
8. Enable the capture kit on the Windows virtual machine to verify
Apache Web page and security optimization