From: Dennis Newbold Date: 2002-03-16T13:27:29+09:00 Subject: Re: (sort of)OT: CGI, FastCGI, etc. Hi Albert, I'm not a total expert myself, but -- 1. the short answer to your question is -- probably not much. A CGI script is something that you write, and which runs on a machine running a web server, such as Apache. As a small example, suppose you go to a website where they want you to fill out a form with some information about yourself. After you do this, you click on a button that probably says "SUBMIT" or something like that. The web browser program grabs all the stuff you typed in, and sends it over to the web server, which starts up a thread to execute a CGI script program, and gives all the data that the web browser sent to it to your CGI script program. Your CGI program can then do whatever it wants with the data: analyze it for errors, and send an error message back to the web browser, or spell check it, or write all the data into a record in a data base, or use the data to select some information from a database and send it back to the web browser or use your imagination. As you can see, the possibilities of CGI make it very attractive (especially when coupled with other stuff like PHP3, JavaScript, etc.). Which means that at any given point in time, a popular webserver is being asked to run 50 - 100 or more CGI scripts. That increases the load on the server, making it slower to respond to incoming requests. When those incoming requests are likely to generate money for the owner of the web server, this translates into lost revenues. This is where FastCGI comes in. FastCGI is basically a way to minimize the server load, so that it can handle requests more quickly. It is often implemented as a module that a webserver, such as Apache, can use. It works (I believe) by keeping the threads, code, and maybe some data, for frequently used CGI scripts in memory, which means that when the web server needs to run it, it doesn't have to start up a new thread or process, and run the code in from disk every time. There's some basic info about CGI scripting at the NCSA website (I believe, its been awhile since I looked at it), but your best bet is to start with a good book. Try a computer bookstore, or www.amazon.com, www.oreilly.com, www.fatbrain.com, www.opamp.com. Good luck. Dennis On Sat, 16 Mar 2002, Albert Wagner wrote: > I'm a total web newbie. I'm learning HTML and trying to understand how CGI > works. What relationship is there, if any, between the Ruby CGI class and > the FastCGI ruby module? How might I best start this steep climb? Books? > Docs? Links? > -- > Quantum Mechanics: The dreams stuff is made of >