source: server/major/apache.xml@ fd69a62

10.0 10.1 11.0 11.1 11.2 11.3 12.0 12.1 7.10 7.6 7.6-blfs 7.6-systemd 7.7 7.8 7.9 8.0 8.1 8.2 8.3 8.4 9.0 9.1 basic bdubbs/svn elogind gnome kde5-13430 kde5-14269 kde5-14686 kea ken/TL2024 ken/inkscape-core-mods ken/tuningfonts krejzi/svn lazarus lxqt nosym perl-modules plabs/newcss plabs/python-mods python3.11 qt5new rahul/power-profiles-daemon renodr/vulkan-addition systemd-11177 systemd-13485 trunk upgradedb xry111/intltool xry111/llvm18 xry111/soup3 xry111/test-20220226 xry111/xf86-video-removal
Last change on this file since fd69a62 was fd69a62, checked in by Fernando de Oliveira <fernando@…>, 10 years ago

Updates to httpd-2.4.9, Python-3.4.0, lcms2-2.6, libFS-1.0.6 and x264-20140316-2245. Several small fixes to Apr-Util-1.5.3, UPower-0.9.23 and Avahi-0.6.3. Thanks Armin K. for discussions.

git-svn-id: svn://svn.linuxfromscratch.org/BLFS/trunk/BOOK@12874 af4574ff-66df-0310-9fd7-8a98e5e911e0

  • Property mode set to 100644
File size: 15.7 KB
Line 
1<?xml version="1.0" encoding="ISO-8859-1"?>
2<!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
3 "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
4 <!ENTITY % general-entities SYSTEM "../../general.ent">
5 %general-entities;
6
7 <!ENTITY apache-download-http
8 "http://archive.apache.org/dist/httpd/httpd-&apache-version;.tar.bz2">
9 <!ENTITY apache-download-ftp " ">
10 <!ENTITY apache-md5sum "2ef4e65353497606b24fa9bb3e5a3c40">
11 <!ENTITY apache-size "4.8 MB">
12 <!ENTITY apache-buildsize "97 MB">
13 <!ENTITY apache-time "0.7 SBU">
14]>
15
16<sect1 id="apache" xreflabel="Apache-&apache-version;">
17 <?dbhtml filename="apache.html"?>
18
19 <sect1info>
20 <othername>$LastChangedBy$</othername>
21 <date>$Date$</date>
22 </sect1info>
23
24 <title>Apache-&apache-version;</title>
25
26 <indexterm zone="apache">
27 <primary sortas="a-Apache">Apache</primary>
28 </indexterm>
29
30 <sect2 role="package">
31 <title>Introduction to Apache HTTPD</title>
32
33 <para>
34 The <application>Apache HTTPD</application> package contains an open-source HTTP
35 server. It is useful for creating local intranet web sites or running huge
36 web serving operations.
37 </para>
38
39 &lfs75_checked;
40
41 <bridgehead renderas="sect3">Package Information</bridgehead>
42 <itemizedlist spacing="compact">
43 <listitem>
44 <para>
45 Download (HTTP): <ulink url="&apache-download-http;"/>
46 </para>
47 </listitem>
48 <listitem>
49 <para>
50 Download (FTP): <ulink url="&apache-download-ftp;"/>
51 </para>
52 </listitem>
53 <listitem>
54 <para>
55 Download MD5 sum: &apache-md5sum;
56 </para>
57 </listitem>
58 <listitem>
59 <para>
60 Download size: &apache-size;
61 </para>
62 </listitem>
63 <listitem>
64 <para>
65 Estimated disk space required: &apache-buildsize;
66 </para>
67 </listitem>
68 <listitem>
69 <para>
70 Estimated build time: &apache-time;
71 </para>
72 </listitem>
73 </itemizedlist>
74
75 <bridgehead renderas="sect3">Additional Downloads</bridgehead>
76 <itemizedlist spacing="compact">
77 <listitem>
78 <para>
79 Required patch:
80 <ulink url="&patch-root;/httpd-&apache-version;-blfs_layout-1.patch"/>
81 </para>
82 </listitem>
83 </itemizedlist>
84
85 <bridgehead renderas="sect3">Apache HTTPD Dependencies</bridgehead>
86
87 <bridgehead renderas="sect4">Required</bridgehead>
88 <para role="required">
89 <xref linkend="apr-util"/> and
90 <xref linkend="pcre"/>
91 </para>
92
93 <bridgehead renderas="sect4">Recommended</bridgehead>
94 <para role="recommended">
95 <xref linkend="openssl"/>
96 </para>
97
98 <bridgehead renderas="sect4">Optional</bridgehead>
99 <para role="optional">
100 <xref linkend="db"/>,
101 <xref linkend="doxygen"/>,
102 <xref linkend="libxml2"/>,
103 <xref linkend="lynx"/>,
104 <xref linkend="openldap"/> (<xref linkend="apr-util"/> needs to be
105 installed with ldap suport),
106 <xref linkend="rsync"/>,
107 <ulink url="http://www.distcache.org/">Distcache</ulink>, and
108 <xref linkend="lua"/>
109 </para>
110
111 <para condition="html" role="usernotes">
112 User Notes: <ulink url="&blfs-wiki;/apache"/>
113 </para>
114 </sect2>
115
116 <sect2 role="installation">
117 <title>Installation of Apache HTTPD</title>
118
119 <para>
120 For security reasons, running the server as an unprivileged user and group
121 is strongly encouraged. Create the following group and user using the
122 following commands as <systemitem class="username">root</systemitem>:
123 </para>
124
125<screen role="root"><userinput>groupadd -g 25 apache &amp;&amp;
126useradd -c "Apache Server" -d /srv/www -g apache \
127 -s /bin/false -u 25 apache</userinput></screen>
128
129 <para>
130 Build and install <application>Apache HTTPD</application> by running the
131 following commands:
132 </para>
133
134<screen><userinput>patch -Np1 -i ../httpd-&apache-version;-blfs_layout-1.patch &amp;&amp;
135sed '/dir.*CFG_PREFIX/s@^@#@' -i support/apxs.in &amp;&amp;
136./configure --enable-layout=BLFS \
137 --enable-mods-shared="all cgi" \
138 --enable-mpms-shared=all \
139 --with-apr=/usr/bin/apr-1-config \
140 --with-apr-util=/usr/bin/apu-1-config \
141 --enable-suexec=shared \
142 --with-suexec-bin=/usr/lib/httpd/suexec \
143 --with-suexec-docroot=/srv/www \
144 --with-suexec-caller=apache \
145 --with-suexec-userdir=public_html \
146 --with-suexec-logfile=/var/log/httpd/suexec.log \
147 --with-suexec-uidmin=100 &amp;&amp;
148make</userinput></screen>
149
150 <para>
151 This package does not come with a test suite.
152 </para>
153
154 <para>
155 Now, as the <systemitem class="username">root</systemitem> user
156 (notice that DESTDIR does not work properly as unpriviledged user):
157 </para>
158
159<screen role="root"><userinput>make install &amp;&amp;
160
161mv -v /usr/sbin/suexec /usr/lib/httpd/suexec &amp;&amp;
162chgrp apache /usr/lib/httpd/suexec &amp;&amp;
163chmod 4754 /usr/lib/httpd/suexec &amp;&amp;
164
165chown -v -R apache:apache /srv/www</userinput></screen>
166
167 </sect2>
168
169 <sect2 role="commands">
170 <title>Command Explanations</title>
171
172 <para>
173 <command>sed '/dir.*CFG_PREFIX/s@^@#@'...</command>: Forces the
174 <application>apxs</application> utility to use absolute pathnames for
175 modules, when instructed to do so.
176 </para>
177
178 <para>
179 <parameter>--enable-mods-shared="all cgi"</parameter>: The modules should be
180 compiled and used as Dynamic Shared Objects (DSOs) so they can be included
181 and excluded from the server using the run-time configuration directives.
182 </para>
183
184 <para>
185 <parameter>--enable-mpm-shared=all</parameter>: This switch ensures that all
186 MPM (Multi Processing Modules) are built as Dynamic Shared Objects (DSOs),
187 so the user can choose which one to use at runtime.
188 </para>
189
190 <para>
191 <parameter>--enable-suexec</parameter>: This switch enables building of the
192 <application>Apache</application> suEXEC module which can be used to allow
193 users to run CGI and SSI scripts under user IDs different from the user ID
194 of the calling web server.
195 </para>
196
197 <para>
198 <parameter>--with-suexec-*</parameter>: These switches control suEXEC module
199 behavior, such as default document root, minimal UID that can be used to
200 run the script under the suEXEC. Please note that with minimal UID 100, you
201 can't run CGI or SSI scripts under suEXEC as the
202 <systemitem class="username">apache</systemitem> user.
203 </para>
204
205 <para>
206 <command>... /usr/lib/httpd/suexec</command>: These commands put
207 <command>suexec</command> wrapper into proper location, since it
208 is not meant to be run directly. They also adjust proper
209 permissions of the binary, making it setgid
210 <systemitem class="username">apache</systemitem>.
211 </para>
212
213 <para>
214 <command>chown -R apache:apache /srv/www</command>: By default, the
215 installation process installs files (documentation, error messages,
216 default icons, etc.) with the ownership of the user that extracted the
217 files from the tar file. If you want to change the ownership to another
218 user, you should do so at this point. The only requirement is that the
219 document directories need to be accessible by the <command>httpd</command>
220 process with (r-x) permissions and files need to be readable (r--) by the
221 <systemitem class="username">apache</systemitem> user.
222 </para>
223
224 </sect2>
225
226 <sect2 role="configuration">
227 <title>Configuring Apache</title>
228
229 <sect3 id="apache-config">
230 <title>Config Files</title>
231
232 <para>
233 <filename>/etc/httpd/httpd.conf</filename> and
234 <filename>/etc/httpd/extra/*</filename>
235 </para>
236
237 <indexterm zone="apache apache-config">
238 <primary sortas="e-etc-httpd-httpd.conf">/etc/httpd/httpd.conf</primary>
239 </indexterm>
240
241 <indexterm zone="apache apache-config">
242 <primary sortas="e-etc-httpd-extra-star">/etc/httpd/extra/*</primary>
243 </indexterm>
244
245 </sect3>
246
247 <sect3>
248 <title>Configuration Information</title>
249
250 <para>
251 See <ulink url="/usr/share/httpd/manual/configuring.html"/>
252 for detailed instructions on customising your
253 <application>Apache</application> HTTP server configuration file.
254 </para>
255
256 </sect3>
257
258 <sect3 id="httpd-init">
259 <title>Boot Script</title>
260
261 <para>
262 If you want the <application>Apache</application> server to
263 start automatically when the system is booted, install the
264 <filename>/etc/rc.d/init.d/httpd</filename> init script included
265 in the <xref linkend="bootscripts"/> package.
266 </para>
267
268 <indexterm zone="apache httpd-init">
269 <primary sortas="f-apache">apache</primary>
270 </indexterm>
271
272<screen role="root"><userinput>make install-httpd</userinput></screen>
273
274 </sect3>
275
276 </sect2>
277
278 <sect2 role="content">
279 <title>Contents</title>
280
281 <segmentedlist>
282 <segtitle>Installed Programs</segtitle>
283 <segtitle>Installed Libraries</segtitle>
284 <segtitle>Installed Directories</segtitle>
285
286 <seglistitem>
287 <seg>
288 ab, apachectl, apxs, checkgid, dbmmanage, fcgistarter,
289 htcacheclean, htdbm, htdigest, htpasswd, httpd,
290 httxt2dbm, logresolve, rotatelogs, and suexec
291 </seg>
292 <seg>
293 Several libraries under /usr/lib/httpd/modules/
294 </seg>
295 <seg>
296 /etc/httpd,
297 /srv/www,
298 /usr/include/httpd,
299 /usr/lib/httpd,
300 /usr/share/httpd,
301 /var/log/httpd, and
302 /var/run/httpd
303 </seg>
304 </seglistitem>
305 </segmentedlist>
306
307 <variablelist>
308 <bridgehead renderas="sect3">Short Descriptions</bridgehead>
309 <?dbfo list-presentation="list"?>
310 <?dbhtml list-presentation="table"?>
311
312 <varlistentry id="ab">
313 <term><command>ab</command></term>
314 <listitem>
315 <para>
316 is a tool for benchmarking your <application>Apache</application>
317 HTTP server.
318 </para>
319 <indexterm zone="apache ab">
320 <primary sortas="b-ab">ab</primary>
321 </indexterm>
322 </listitem>
323 </varlistentry>
324
325 <varlistentry id="apachectl">
326 <term><command>apachectl</command></term>
327 <listitem>
328 <para>
329 is a front end to the <application>Apache</application> HTTP server
330 which is designed to help the administrator control the functioning
331 of the <application>Apache</application> httpd daemon.
332 </para>
333 <indexterm zone="apache apachectl">
334 <primary sortas="b-apachectl">apachectl</primary>
335 </indexterm>
336 </listitem>
337 </varlistentry>
338
339 <varlistentry id="apxs">
340 <term><command>apxs</command></term>
341 <listitem>
342 <para>
343 is a tool for building and installing extension modules for the
344 <application>Apache</application> HTTP server.
345 </para>
346 <indexterm zone="apache apxs">
347 <primary sortas="b-apxs">apxs</primary>
348 </indexterm>
349 </listitem>
350 </varlistentry>
351
352 <varlistentry id="checkgid">
353 <term><command>checkgid</command></term>
354 <listitem>
355 <para>
356 is a program that checks whether it can setgid to the group
357 specified. This is to see if it is a valid group for Apache2 to use
358 at runtime. If the user (should be run as superuser) is in that
359 group, or can setgid to it, it will return 0.
360 </para>
361 <indexterm zone="apache checkgid">
362 <primary sortas="b-checkgid">checkgid</primary>
363 </indexterm>
364 </listitem>
365 </varlistentry>
366
367 <varlistentry id="dbmmanage">
368 <term><command>dbmmanage</command></term>
369 <listitem>
370 <para>
371 is used to create and update the DBM format files used to store
372 usernames and passwords for basic authentication of HTTP users.
373 </para>
374 <indexterm zone="apache dbmmanage">
375 <primary sortas="b-dbmmanage">dbmmanage</primary>
376 </indexterm>
377 </listitem>
378 </varlistentry>
379
380 <varlistentry id="htcacheclean">
381 <term><command>htcacheclean</command></term>
382 <listitem>
383 <para>
384 is used to clean up the disk cache.
385 </para>
386 <indexterm zone="apache htcacheclean">
387 <primary sortas="b-htcacheclean">htcacheclean</primary>
388 </indexterm>
389 </listitem>
390 </varlistentry>
391
392 <varlistentry id="htdbm">
393 <term><command>htdbm</command></term>
394 <listitem>
395 <para>
396 is used to manipulate the DBM password databases.
397 </para>
398 <indexterm zone="apache htdbm">
399 <primary sortas="b-htdbm">htdbm</primary>
400 </indexterm>
401 </listitem>
402 </varlistentry>
403
404 <varlistentry id="htdigest">
405 <term><command>htdigest</command></term>
406 <listitem>
407 <para>
408 is used to create and update the flat-files used to store usernames,
409 realms and passwords for digest authentication of HTTP users.
410 </para>
411 <indexterm zone="apache htdigest">
412 <primary sortas="b-htdigest">htdigest</primary>
413 </indexterm>
414 </listitem>
415 </varlistentry>
416
417 <varlistentry id="htpasswd">
418 <term><command>htpasswd</command></term>
419 <listitem>
420 <para>
421 is used to create and update the flat-files used to store usernames
422 and passwords for basic authentication of HTTP users.
423 </para>
424 <indexterm zone="apache htpasswd">
425 <primary sortas="b-htpasswd">htpasswd</primary>
426 </indexterm>
427 </listitem>
428 </varlistentry>
429
430 <varlistentry id="httpd">
431 <term><command>httpd</command></term>
432 <listitem>
433 <para>
434 is the <application>Apache</application> HTTP server program.
435 </para>
436 <indexterm zone="apache httpd">
437 <primary sortas="b-httpd">httpd</primary>
438 </indexterm>
439 </listitem>
440 </varlistentry>
441
442 <varlistentry id="httxt2dbm">
443 <term><command>httxt2dbm</command></term>
444 <listitem>
445 <para>
446 is used to generate DBM files from text, for use in RewriteMap.
447 </para>
448 <indexterm zone="apache httxt2dbm">
449 <primary sortas="b-httxt2dbm">httxt2dbm</primary>
450 </indexterm>
451 </listitem>
452 </varlistentry>
453
454 <varlistentry id="logresolve">
455 <term><command>logresolve</command></term>
456 <listitem>
457 <para>
458 is a post-processing program to resolve IP-addresses in
459 <application>Apache</application>'s access log files.
460 </para>
461 <indexterm zone="apache logresolve">
462 <primary sortas="b-logresolve">logresolve</primary>
463 </indexterm>
464 </listitem>
465 </varlistentry>
466
467 <varlistentry id="rotatelogs">
468 <term><command>rotatelogs</command></term>
469 <listitem>
470 <para>
471 is a simple program for use in conjunction with
472 <application>Apache</application>'s piped log file feature.
473 </para>
474 <indexterm zone="apache rotatelogs">
475 <primary sortas="b-rotatelogs">rotatelogs</primary>
476 </indexterm>
477 </listitem>
478 </varlistentry>
479
480 </variablelist>
481
482 </sect2>
483
484</sect1>
Note: See TracBrowser for help on using the repository browser.