The biggest advantage of fastcgi is that it is highly efficient, because once the program is loaded into memory, it stays on for a long time, and does not load up on the memory for every execution, like a normal program. Because for the large number of visits, the actual implementation of relatively simple procedures, it is best to write a fastcgi way, can significantly improve the concurrency processing capacity.
Because Nginx does not bring fastcgi tools, we need lighttpd spawn-fcgi Older versions of the spawn-fcgi are brought in lighttpd, and new versions can be installed independently. Older versions of the system need to first
Apt Install lighttpd
Do not let lighttpd run, or modify the LIGHTTPD default port Vi/etc/lighttpd/lighttpd.conf Server.port = 81
What we need is: /usr/bin/spawn-fcgi
For example, our fastcgi program is/home/www/cgi-bin/fast.bin, and he's our own CGI program written and compiled in C or other languages. Let him reside in the background with the following command, and bind to port 10001
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.