1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!DOCTYPE manualpage SYSTEM "../style/manualpage.dtd">
3 <?xml-stylesheet type="text/xsl" href="../style/manual.en.xsl"?>
4 <!-- $LastChangedRevision$ -->
7 Licensed to the Apache Software Foundation (ASF) under one or more
8 contributor license agreements. See the NOTICE file distributed with
9 this work for additional information regarding copyright ownership.
10 The ASF licenses this file to You under the Apache License, Version 2.0
11 (the "License"); you may not use this file except in compliance with
12 the License. You may obtain a copy of the License at
14 http://www.apache.org/licenses/LICENSE-2.0
16 Unless required by applicable law or agreed to in writing, software
17 distributed under the License is distributed on an "AS IS" BASIS,
18 WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
19 See the License for the specific language governing permissions and
20 limitations under the License.
23 <manualpage metafile="netware.xml.meta">
24 <parentdocument href="./">Platform Specific Notes</parentdocument>
26 <title>Using Apache With Novell NetWare</title>
30 <p>This document explains how to install, configure and run
31 Apache 2.0 under Novell NetWare 6.0 and above. If you find any bugs,
32 or wish to contribute in other ways, please use our
33 <a href="http://httpd.apache.org/bug_report.html">bug reporting
36 <p>The bug reporting page and dev-httpd mailing list are <em>not</em>
37 provided to answer questions about configuration or running Apache.
38 Before you submit a bug report or request, first consult this document, the
39 <a href="../faq/">Frequently Asked Questions</a> page and the other
40 relevant documentation topics. If you still have a question or problem,
41 post it to the <a href="news://developer-forums.novell.com/novell.devsup.webserver">
42 novell.devsup.webserver</a> newsgroup, where many Apache users are more than
43 willing to answer new and obscure questions about using Apache on NetWare.</p>
45 <p>Most of this document assumes that you are installing Apache
46 from a binary distribution. If you want to compile Apache
47 yourself (possibly to help with development, or to track down
48 bugs), see the section on <a href="#comp">Compiling Apache for
49 NetWare</a> below.</p>
55 <title>Requirements</title>
57 <p>Apache 2.0 is designed to run on NetWare 6.0 service pack 3
58 and above. If you are running a service pack less
59 than SP3, you must install the latest
60 <a href="http://developer.novell.com/ndk/libc.htm">NetWare Libraries
63 <p>NetWare service packs are available <a
64 href="http://support.novell.com/misc/patlst.htm#nw">here</a>.</p>
66 <p>Apache 2.0 for NetWare can also be run in a NetWare 5.1 environment
67 as long as the latest service pack or the latest version
68 of the <a href="http://developer.novell.com/ndk/libc.htm">NetWare Libraries
69 for C (LibC)</a> has been installed . <strong>WARNING:</strong> Apache 2.0
70 for NetWare has not been targeted for or tested in this environment.</p>
76 <title>Downloading Apache for NetWare</title>
78 <p>Information on the latest version of Apache can be found on
79 the Apache web server at <a
80 href="http://www.apache.org/">http://www.apache.org/</a>. This
81 will list the current release, any more recent alpha or
82 beta-test releases, together with details of mirror web and
83 anonymous ftp sites. Binary builds of the latest releases of
84 Apache 2.0 for NetWare can be downloaded from
85 <a href="http://www.apache.org/dist/httpd/binaries/netware">here</a>.</p>
91 <title>Installing Apache for NetWare</title>
93 <p>There is no Apache install program for NetWare currently. If you
94 are building Apache 2.0 for NetWare from source, you will need to
95 copy the files over to the server manually.</p>
97 <p>Follow these steps to install Apache on NetWare from the
98 binary download (assuming you will install to
99 <code>sys:/apache2</code>):</p>
102 <li>Unzip the binary download file to the root of the <code>SYS:</code>
103 volume (may be installed to any volume)</li>
105 <li>Edit the <code>httpd.conf</code> file setting <directive
106 module="core">ServerRoot</directive> and <directive
107 module="core">ServerName</directive> along with any file path values
108 to reflect your correct server settings</li>
110 <li>Add <code>SYS:/APACHE2</code> to the search path, for example:
111 <example>SEARCH ADD SYS:\APACHE2</example>
116 <p>Follow these steps to install Apache on NetWare manually
117 from your own build source (assuming you will install to
118 <code>sys:/apache2</code>):</p>
121 <li>Create a directory called <code>Apache2</code> on a
124 <li>Copy <code>APACHE2.NLM</code>, <code>APRLIB.NLM</code>
125 to <code>SYS:/APACHE2</code></li>
127 <li>Create a directory under <code>SYS:/APACHE2</code>
128 called <code>BIN</code></li>
130 <li>Copy <code>HTDIGEST.NLM</code>, <code>HTPASSWD.NLM</code>,
131 <code>HTDBM.NLM</code>, <code>LOGRES.NLM</code>, <code>ROTLOGS.NLM</code>
132 to <code>SYS:/APACHE2/BIN</code></li>
134 <li>Create a directory under <code>SYS:/APACHE2</code>
135 called <code>CONF</code></li>
137 <li>Copy the <code>HTTPD-STD.CONF</code> file to the
138 <code>SYS:/APACHE2/CONF</code> directory and rename to
139 <code>HTTPD.CONF</code></li>
141 <li>Copy the <code>MIME.TYPES</code>, <code>CHARSET.CONV</code> and
142 <code>MAGIC</code> files to <code>SYS:/APACHE2/CONF</code> directory</li>
144 <li>Copy all files and subdirectories in <code>\HTTPD-2.0\DOCS\ICONS</code>
145 to <code>SYS:/APACHE2/ICONS</code></li>
147 <li>Copy all files and subdirectories in <code>\HTTPD-2.0\DOCS\MANUAL</code>
148 to <code>SYS:/APACHE2/MANUAL</code></li>
150 <li>Copy all files and subdirectories in <code>\HTTPD-2.0\DOCS\ERROR</code>
151 to <code>SYS:/APACHE2/ERROR</code></li>
153 <li>Copy all files and subdirectories in <code>\HTTPD-2.0\DOCS\DOCROOT</code>
154 to <code>SYS:/APACHE2/HTDOCS</code></li>
156 <li>Create the directory <code>SYS:/APACHE2/LOGS</code>
159 <li>Create the directory <code>SYS:/APACHE2/CGI-BIN</code>
162 <li>Create the directory <code>SYS:/APACHE2/MODULES</code>
163 and copy all nlm modules into the <code>modules</code> directory</li>
165 <li>Edit the <code>HTTPD.CONF</code> file searching for all
166 <code>@@Value@@</code> markers and replacing them with the
167 appropriate setting</li>
169 <li>Add <code>SYS:/APACHE2</code> to the search path, for example:
170 <example>SEARCH ADD SYS:\APACHE2</example>
174 <p>Apache may be installed to other volumes besides the default <code>SYS</code> volume.</p>
176 <p>During the build process, adding the keyword "install" to the makefile command line
177 will automatically produce a complete distribution package under the subdirectory
178 <code>DIST</code>. Install Apache by simply copying the distribution that was produced
179 by the makfiles to the root of a NetWare volume (see: <a href="#comp">Compiling Apache for
180 NetWare</a> below).</p>
186 <title>Running Apache for NetWare</title>
188 <p>To start Apache just type <code>apache</code> at the
189 console. This will load apache in the OS address space. If you
190 prefer to load Apache in a protected address space you may
191 specify the address space with the load statement as follows:</p>
194 load address space = apache2 apache2
197 <p>This will load Apache into an address space called apache2.
198 Running multiple instances of Apache concurrently on NetWare is
199 possible by loading each instance into its own protected
202 <p>After starting Apache, it will be listening to port 80
203 (unless you changed the <directive module="mpm_common">Listen</directive>
204 directive in the configuration files).
205 To connect to the server and access the default page,
206 launch a browser and enter the server's name or address. This
207 should respond with a welcome page, and a link to the Apache
208 manual. If nothing happens or you get an error, look in the
209 <code>error_log</code> file in the <code>logs</code>
212 <p>Once your basic installation is working, you should
213 configure it properly by editing the files in the
214 <code>conf</code> directory.</p>
216 <p>To unload Apache running in the OS address space just type
217 the following at the console:</p>
229 <p>If apache is running in a protected address space specify the
230 address space in the unload statement:</p>
233 unload address space = apache2 apache2
236 <p>When working with Apache it is important to know how it will
237 find the configuration files. You can specify a configuration
238 file on the command line in two ways:</p>
241 <li><code>-f</code> specifies a path to a particular
242 configuration file</li>
246 apache2 -f "vol:/my server/conf/my.conf"
250 apache -f test/test.conf
253 <p>In these cases, the proper <directive module="core">ServerRoot</directive>
254 should be set in the configuration file.</p>
256 <p>If you don't specify a configuration file name with <code>-f</code>,
257 Apache will use the file name compiled into the server, usually
258 <code>conf/httpd.conf</code>. Invoking Apache with the <code>-V</code>
259 switch will display this value labeled as <code>SERVER_CONFIG_FILE</code>.
260 Apache will then determine its <directive module="core">ServerRoot</directive>
261 by trying the following, in this order:</p>
264 <li>A <code>ServerRoot</code> directive via a
265 <code>-C</code> switch.</li>
267 <li>The <code>-d</code> switch on the command line.</li>
269 <li>Current working directory</li>
271 <li>The server root compiled into the server.</li>
274 <p>The server root compiled into the server is usually <code>sys:/apache2</code>.
275 invoking apache with the <code>-V</code> switch will display this value labeled as
276 <code>HTTPD_ROOT</code>.</p>
278 <p>Apache 2.0 for NetWare includes a set of command line directives that can
279 be used to modify or display information about the running instance of the
280 web server. These directives are only available while Apache is running. Each
281 of these directives must be preceded by the keyword <code>APACHE2</code>.</p>
285 <dd>Instructs Apache to terminate all running worker
286 threads as they become idle, reread the configuration file and restart each
287 worker thread based on the new configuration.</dd>
290 <dd>Displays version information about the currently
291 running instance of Apache.</dd>
294 <dd>Displays a list of loaded modules both built-in
298 <dd>Displays a list of all available directives.</dd>
301 <dd>Enables or disables the thread status display
302 on the console. When enabled, the state of each running threads is displayed
303 on the Apache console screen.</dd>
306 <dd>Terminates the running instance of the Apache
310 <dd>Describes each of the runtime directives.</dd>
313 <p>By default these directives are issued against the instance of Apache running
314 in the OS address space. To issue a directive against a specific instance running
315 in a protected address space, include the -p parameter along with the name of the
316 address space. For more information type "apache2 Help" on the command line.</p>
322 <title>Configuring Apache for NetWare</title>
324 <p>Apache is configured by reading configuration files usually stored
325 in the <code>conf</code> directory. These are the same as files used
326 to configure the Unix version, but there are a few different directives for
327 Apache on NetWare. See the <a href="../">Apache
328 documentation</a> for all the available directives.</p>
330 <p>The main differences in Apache for NetWare are:</p>
334 <p>Because Apache for NetWare is multithreaded, it does not
335 use a separate process for each request, as Apache does on some Unix
336 implementations. Instead there are only threads running: a parent
337 thread, and multiple child or worker threads which handle the requests.</p>
339 <p>Therefore the "process"-management directives are different:</p>
341 <p><directive module="mpm_common">MaxConnectionsPerChild</directive> -
342 Like the Unix directive, this controls how many connections
343 a worker thread will serve before exiting. The recommended default,
344 <code>MaxConnectionsPerChild 0</code>, causes the thread to continue servicing
345 request indefinitely. It is recommended on NetWare, unless there is some
346 specific reason, that this directive always remain set to <code>0</code>.</p>
348 <p><directive module="mpm_common">StartThreads</directive> -
349 This directive tells the server how many threads it should start initially.
350 The recommended default is <code>StartThreads 50</code>.</p>
352 <p><directive module="mpm_common">MinSpareThreads</directive> -
353 This directive instructs the server to spawn additional worker threads
354 if the number of idle threads ever falls below this value. The recommended
355 default is <code>MinSpareThreads 10</code>.</p>
357 <p><directive module="mpm_common">MaxSpareThreads</directive> -
358 This directive instructs the server to begin terminating worker threads
359 if the number of idle threads ever exceeds this value. The recommended
360 default is <code>MaxSpareThreads 100</code>.</p>
362 <p><directive module="mpm_netware">MaxThreads</directive> -
363 This directive limits the total number of work threads to a maximum
364 value. The recommended default is <code>ThreadsPerChild 250</code>.</p>
366 <p><directive module="mpm_common">ThreadStackSize</directive> -
367 This directive tells the server what size of stack to use
368 for the individual worker thread. The recommended default
369 is <code>ThreadStackSize 65536</code>.</p>
373 <p>The directives that accept filenames as arguments must use
374 NetWare filenames instead of Unix names. However, because Apache
375 uses Unix-style names internally, forward slashes must be used
376 rather than backslashes. It is recommended that all rooted file paths
377 begin with a volume name. If omitted, Apache will assume the
378 <code>SYS:</code> volume which may not be correct.</p>
382 <p>Apache for NetWare has the ability to load modules at
383 runtime, without recompiling the server. If Apache is
384 compiled normally, it will install a number of optional
385 modules in the <code>\Apache2\modules</code> directory.
386 To activate these, or other modules, the <directive
387 module="mod_so">LoadModule</directive> directive
388 must be used. For example, to active the status module, use
392 LoadModule status_module modules/status.nlm
396 href="../mod/mod_so.html#creating">creating loadable
397 modules</a> is also available.</p>
401 <section id="use-add">
403 <title>Additional NetWare specific directives:</title>
406 <li><directive module="core">CGIMapExtension</directive> -
407 This directive maps a CGI file extension to a script interpreter.</li>
410 <li><directive module="mod_nw_ssl">SecureListen</directive> -
411 Enables SSL encryption for a specified port.</li>
414 <li><directive module="mod_nw_ssl">NWSSLTrustedCerts</directive> -
415 Adds trusted certificates that are used to create secure connections to proxied servers.</li>
418 <li><directive module="mod_nw_ssl">NWSSLUpgradeable</directive> -
419 Allow a connection created on the specified address/port to be upgraded to an SSL connection.</li>
428 <title>Compiling Apache for NetWare</title>
430 <p>Compiling Apache requires MetroWerks CodeWarrior 6.x or higher. Once
431 Apache has been built, it can be installed to the root of any NetWare
432 volume. The default is the <code>sys:/Apache2</code> directory.</p>
434 <p>Before running the server you must fill out the <code>conf</code>
435 directory. Copy the file <code>HTTPD-STD.CONF</code> from the distribution
436 <code>conf</code> directory and rename it to <code>HTTPD.CONF</code>.
437 Edit the <code>HTTPD.CONF</code> file searching for all <code>@@Value@@</code>
438 markers and replacing them with the appropriate setting. Copy over
439 the <code>conf/magic</code> and <code>conf/mime.types</code> files as well.
440 Alternatively, a complete distribution can be built by including the keyword
441 <code>install</code> when invoking the makefiles.</p>
443 <section id="comp-req">
445 <title>Requirements:</title>
447 <p>The following development tools are required to build
448 Apache 2.0 for NetWare:</p>
451 <li>Metrowerks CodeWarrior 6.0 or higher with the
452 <a href="http://developer.novell.com/ndk/cwpdk.htm">NetWare PDK 3.0</a>
455 <li><a href="http://developer.novell.com/ndk/libc.htm">NetWare Libraries
456 for C (LibC)</a></li>
458 <li><a href="http://developer.novell.com/ndk/cldap.htm">LDAP Libraries
461 <li><a href="http://www.gzip.org/zlib/">ZLIB Compression Library source code</a></li>
463 <li>AWK utility (awk, gawk or similar). AWK can be downloaded from
464 <a href="http://developer.novell.com/ndk/apache.htm">http://developer.novell.com/ndk/apache.htm</a>.
465 The utility must be found in your windows path and must be named <code>awk.exe</code>.</li>
467 <li>To build using the makefiles, you will need GNU make version 3.78.1 (GMake) available at
468 <a href="http://developer.novell.com/ndk/apache.htm">http://developer.novell.com/ndk/apache.htm</a>.</li>
473 <section id="comp-make">
475 <title>Building Apache using the NetWare makefiles:</title>
478 <li>Set the environment variable <code>NOVELLLIBC</code> to the
479 location of the NetWare Libraries for C SDK, for example:
480 <example>Set NOVELLLIBC=c:\novell\ndk\libc</example>
483 <li>Set the environment variable <code>METROWERKS</code> to the
484 location where you installed the Metrowerks CodeWarrior compiler,
486 <example>Set METROWERKS=C:\Program Files\Metrowerks\CodeWarrior</example>
487 If you installed to the default location <code>C:\Program
488 Files\Metrowerks\CodeWarrior</code>, you don't need to set this.</li>
490 <li>Set the environment variable <code>LDAPSDK</code> to the
491 location where you installed the LDAP Libraries for C, for example:
492 <example>Set LDAPSDK=c:\Novell\NDK\cldapsdk\NetWare\libc</example>
495 <li>Set the environment variable <code>ZLIBSDK</code> to the
496 location where you installed the source code for the ZLib Library,
498 <example>Set ZLIBSDK=D:\NOVELL\zlib</example>
501 <li>Set the environment variable <code>PCRESDK</code> to the location
502 where you installed the source code for the PCRE Library, for example:
503 <example>Set PCRESDK=D:\NOVELL\pcre</example>
506 <li>Set the environment variable <code>AP_WORK</code> to the full path of
507 the <code>httpd</code> source code directory.
508 <example>Set AP_WORK=D:\httpd-2.0.x</example>
511 <li>Set the environment variable <code>APR_WORK</code> to the full path of
512 the <code>apr</code> source code directory. Typically <code>\httpd\srclib\apr</code>
513 but the APR project can be outside of the httpd directory structure.
514 <example>Set APR_WORK=D:\apr-1.x.x</example>
517 <li>Set the environment variable <code>APU_WORK</code> to the full path of
518 the <code>apr-util</code> source code directory. Typically <code>\httpd\srclib\apr-util</code>
519 but the APR-UTIL project can be outside of the httpd directory structure.
520 <example>Set APU_WORK=D:\apr-util-1.x.x</example>
523 <li>Make sure that the path to the AWK utility and the GNU make utility
524 (<code>gmake.exe</code>) have been included in the system's
525 <code>PATH</code> environment variable.</li>
527 <li>Download the source code and unzip to an appropriate directory on
528 your workstation.</li>
530 <li>Change directory to <code>\httpd-2.0</code> and build the prebuild utilities
531 by running "<code>gmake -f nwgnumakefile prebuild</code>". This target will create
532 the directory <code>\httpd-2.0\nwprebuild</code> and copy each of the utilities
533 to this location that are necessary to complete the following build steps.
536 <li>Copy the files <code>\httpd-2.0\nwprebuild\GENCHARS.nlm</code> and
537 <code>\httpd-2.0\nwprebuild\DFTABLES.nlm</code> to the <code>SYS:</code> volume of a
538 NetWare server and run them using the following commands:
540 SYS:\genchars > sys:\test_char.h<br />
541 SYS:\dftables sys:\chartables.c<br />
545 <li>Copy the files <code>test_char.h</code> and <code>chartables.c</code>
546 to the directory <code>\httpd-2.0\os\netware</code> on the build machine.</li>
548 <li>Change directory to <code>\httpd-2.0</code> and build Apache by running
549 "<code>gmake -f nwgnumakefile</code>". You can create a distribution directory by
550 adding an install parameter to the command, for example:
551 <example>gmake -f nwgnumakefile install</example>
557 <section id="comp-add">
559 <title>Additional make options</title>
562 <li><code>gmake -f nwgnumakefile</code><p>Builds release versions of all of the
563 binaries and copies them to a <code>\release</code> destination directory.</p></li>
565 <li><code>gmake -f nwgnumakefile DEBUG=1</code><p>Builds debug versions of all of the
566 binaries and copies them to a <code>\debug</code> destination directory.</p></li>
568 <li><code>gmake -f nwgnumakefile install</code><p>Creates a complete Apache
569 distribution with binaries, docs and additional support files in a
570 <code>\dist\Apache2</code> directory.</p></li>
572 <li><code>gmake -f nwgnumakefile prebuild</code><p>Builds all of the prebuild utilities
573 and copies them to the <code>\nwprebuild</code> directory.</p></li>
575 <li><code>gmake -f nwgnumakefile installdev</code><p>Same as install but also creates a
576 <code>\lib</code> and <code>\include</code> directory in the destination directory
577 and copies headers and import files.</p></li>
579 <li><code>gmake -f nwgnumakefile clean</code><p>Cleans all object files and binaries
580 from the <code>\release.o</code> or <code>\debug.o</code> build areas depending on whether
581 <code>DEBUG</code> has been defined.</p></li>
583 <li><code>gmake -f nwgnumakefile clobber_all</code><p>Same as clean and also deletes
584 the distribution directory if it exists.</p></li>
589 <section id="comp-add-env">
591 <title>Additional environment variable options</title>
594 <li>To build all of the experimental modules, set the environment
595 variable <code>EXPERIMENTAL</code>:
596 <example>Set EXPERIMENTAL=1</example>
599 <li>To build Apache using standard BSD style sockets rather than
600 Winsock, set the environment variable <code>USE_STDSOCKETS</code>:
601 <example>Set USE_STDSOCKETS=1</example>
608 <section id="comp-mod_ssl">
610 <title>Building mod_ssl for the NetWare platform</title>
612 <p>By default Apache for NetWare uses the built-in module
613 <module>mod_nw_ssl</module> to provide SSL services. This module
614 simply enables the native SSL services implemented in NetWare OS
615 to handle all encryption for a given port. Alternatively, mod_ssl
616 can also be used in the same manner as on other platforms.</p>
618 <p>Before mod_ssl can be built for the NetWare platform, the OpenSSL
619 libraries must be provided. This can be done through the following
623 <li>Download the recent OpenSSL 0.9.8 release source code from the
624 <a href="http://www.openssl.org/source/">OpenSSL Source</a>
625 page (older 0.9.7 versions need to be patched and are therefore not
628 <li>Edit the file <code>NetWare/set_env.bat</code> and modify any
629 tools and utilities paths so that they correspond to your build
632 <li>From the root of the OpenSSL source directory, run the following
635 Netware\set_env netware-libc<br />
636 Netware\build netware-libc
638 For performance reasons you should enable to build with ASM code.
639 Download NASM from the <a href="http://nasm.sourceforge.net/">SF site</a>.
640 Then configure OpenSSL to use ASM code:
642 Netware\build netware-libc nw-nasm enable-mdc2 enable-md5
644 Warning: dont use the CodeWarrior Assembler - it produces broken code!
647 <li>Before building Apache, set the environment variable
648 <code>OSSLSDK</code> to the full path to the root of the openssl
649 source code directory, and set WITH_MOD_SSL to 1.
651 Set OSSLSDK=d:\openssl-0.9.8x<br />