Skip to Main Content
Linux System Administration
book

Linux System Administration

by Tom Adelstein, Bill Lubanovic
March 2007
Intermediate to advanced content levelIntermediate to advanced
304 pages
11h 12m
English
O'Reilly Media, Inc.
Content preview from Linux System Administration
A Simple LAMP Setup
|
123
comments that Apache interprets to echo the values of variables or include the con-
tents of other HTML files. SSI file inclusion is a simple way for a site to define a com-
mon header and footer for its pages, for instance.
SSI has its limits, though, and most dynamic sites use the far more powerful Common
Gateway Interface (CGI) programs. These executable programs can be written in any
language that Linux supports, although the most popular choices are dynamic (“script-
ing”) languages such as Perl, PHP, Python, and Ruby, followed by Java. CGI is a proto-
col that specifies how web clients and servers should exchange requests and responses.
When CGI first appeared on the Web, CGI programs were completely separate from
web servers. Each request caused the web server to start up a new CGI process. The
startup cost increased system load as sites got busier, so alternatives were developed.
People often confuse the CGI protocol with this early implementation method and
think that CGI is inherently slow. However, the CGI standard does not define imple-
mentation. There are faster methods that follow the same CGI protocol.
One faster method is FastCGI, which starts up the CGI program as a separate long-
running process and manages two-way communications between it and the web
server. This avoids the constant reload cost, and the process separation ensures that
if the CGI program ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Mastering Linux System Administration

Mastering Linux System Administration

Christine Bresnahan, Richard Blum
Mastering Linux Administration

Mastering Linux Administration

Alexandru Calcatinge, Julian Balog

Publisher Resources

ISBN: 9780596009526Supplemental ContentCatalog PageErrata