Nginx Agent and reverse Agent (rpm package installation)
Note:
Case 1:
When the back end is a separate php-fpm server module
Fastcgi protocol is required
Case 2:
When the backend is LAMP, the Apache protocol is used.
There is no need to open the fastcgi module
Write a location / {directly
Proxy_pass http://backservers;
}
Can
The fastcgi_params in the Nginx installed in this experiment is not applicable this time, so you need to change it:
Fastcgi_params module content:
Fastcgi_param GATEWAY_INTERFACE CGI/1.1
Fastcgi_param SERVER_SOFTWARE nginx
Fastcgi_param QUERY_STRING $query_string
Fastcgi_param REQUEST_METHOD $request_method
Fastcgi_param CONTENT_TYPE $content_type
Fastcgi_param CONTENT_LENGTH $content_length
Fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name
Fastcgi_param SCRIPT_NAME $fastcgi_script_name
Fastcgi_param REQUEST_URI $request_uri
Fastcgi_param DOCUMENT_URI $document_uri
Fastcgi_param DOCUMENT_ROOT $document_root
Fastcgi_param SERVER_PROTOCOL $server_protocol
Fastcgi_param REMOTE_ADDR $remote_addr
Fastcgi_param REMOTE_PORT $remote_port
Fastcgi_param SERVER_ADDR $server_addr
Fastcgi_param SERVER_PORT $server_port
Fastcgi_param SERVER_NAME $server_name
Ab-n 1000-c 100 http://192.168.253.100/cwy/
Test concurrency
Test MySQL connectivity:
Using the Apache protocol:
Location / up/ {
Proxy_pass http://cwy/;
Proxy_set_header Host $host
Proxy_set_header X-Real-IP $remote_addr
}