[ Previous ] [ Contents ] [ Index ] [ Next ]

Configuration File Reference

The following tables describe all the possible parameters that can be set in each section of the configuration file. Note that some sections are not necessary at all if a specific capability is not included. For example, you don't need a section configuring the nstext (full text capabilities) module for a server if that server does not include the nstext module.

Note on Boolean Parameter Values:

There are several ways to specify a boolean parameter value. The reference tables below use "on" for true and "off" for false. However, any of the following values are valid:

Boolean Value

Equivalent Boolean Values

on

y, yes, t, true, 1 (one)

off

n, no, f, false, 0 (zero)

The Parameters Section

[ns/parameters]

This section is used to specify global AOLserver parameters.

Parameter

Default Value

Description

AllowRoot

off

Boolean value. Unix only. If set to on, AOLserver can be run as root if the User key is set to "root" or the Uid key is set to "0".

Setting this parameter on is a potential security risk and is not recommended.

AuxConfigDir

A directory containing additional configuration files whose contents will be merged with the primary configuration file. After loading the primary configuration file (the value of the -c parameter on the nsd command line, usually nsd.ini), any files in the directory specified by AuxConfigDir with an .ini extension are loaded in alphabetical order.

If a configuration file section in an auxiliary configuration file already exists in the primary configuration file, the key/value pairs in that section are added to the  end of the existing section from the primary configuration file. If, as a  result, a specific parameter is set more than once in a section, the first setting will be used. Therefore, a parameter set in an auxiliary configuration file cannot override the same parameter set in the primary configuration file or in an auxiliary configuration file loaded before it.  Some parameters, such as the Map parameters in  the CGI and SHTML sections, can have multiple settings.  In this case, all Map parameter settings will be used.

CatchExceptions

on

(Unix only) Boolean value. If set to on, it registers server handlers for SIGBUS, SIGILL, SIGSEGV, SIGFPE, SIGIOT, SIGEMT, and SIGSYS. You may want to set this parameter off when debugging a new C module.

CheckExitCode

off

Boolean value. If set to on, an error is reported when a child process exits with a non-zero status.

CheckInterval

60

The number of seconds between server checks for scheduled procedures.

Debug

off

Boolean value. If set to on, debug messages will be printed to the global server log. Note: Setting Debug on will produce a large amount of debug output.

DNSCache

on

Boolean. If set to on, enables DNS cache to speed lookup of remote IP addresses. Since the DNS cache can dramatically speed lookup time, especially in the case of a busy server with the nslog module set to resolve host names, it is recommended that DNSCache be left on.

DNSCache-PurgeInterval

240

The number of minutes after which DNS cache entries expire.

DNSCacheTimeout

60

The number of minutes between cache purges for the DNS cache.

Gid

(If neither Gid nor Group is set, the default group of the user specified by the User parameter is used.)

Unix group number.

Group

(If neither Gid nor Group is set, the default group of the user specified by the User parameter is used.)

Unix group name. This parameter is ignored if the gid parameter is set.

Home

The AOLserver home directory (the directory where AOLserver was installed). This parameter is required.

ListenBacklog

32

The maximum length of the queue of pending connections.

LogExpanded

off

Boolean value. If set to on, each server log entry will be 2 lines long (instead of 1).

LogMaxBackup

10

The maximum number of server log backup files.

LogPid

on

Boolean value. If set to on, the pid (process id) will be included in server log entries.

LogRoll

on

Boolean value. If set to on, the server log file will be rolled on a SIGHUP.

LogServer

on

Boolean value. If set to on, the virtual server name will be included in server log entries.

LogTid

on

Boolean value. If set to on, the tid (thread id) will be included in server log entries.

LogTime

on

Boolean value. If set to on, timestamps will be included in server log entries.

LowMemorySleep

on

Boolean value.  If set to On and the server can't allocate sufficient memory, the server behaves as follows:  it sleeps for a second and tries again, then (if unsuccessful) sleeps for ten seconds and tries again.  If the server is still unsuccessful at allocating memory, the server is killed.

If set to Off and the server can't allocate sufficient memory, the server is killed immediately.

MailHost

localhost

The SMTP server AOLserver should use when sending email using the Tcl ns_sendmail function.

MaxStartThreads

5

The number of threads to start AOLserver with.

MaxStartWait

0

Maximum number of seconds to wait for servers to start. If all servers have not initialized in this time, the server will be immediately stopped.

MaxStopWait

60

Maximum number of seconds to wait for servers to stop. If active connections are not completed in this time, the server will be immediately stopped.

ModuleDirectory

bin

The directory where the server loads modules from, specified as either an absolute path or a relative path from the server home directory.

OpenMax

Process limit on open files

Unix only. AOLserver will attempt to increase the maximum number of open files allowed for the process to the value specified.

PidFile

serverhome/log

/nspid.setup-server-port

The pathname of the file where the server puts its pid.

SelectLoopBufferSize

4096

The size, in bytes, of the buffer to use when transferring data. This should be the same size as your machine's configured network send buffer size.

Enable select-loop serving of simple files for each virtual server with the SelectLoop parameter in the [ns/server/server-name] section.

SelectLoopCount

1

The number of simultaneous select loops to use. If you have a multi-processor machine, this should be set to the number of processors you have, which allows each processor to share the load.

The maximum number of simultaneous servings of static data is SelectLoopCount multiplied by SelectLoopMaxServe.

Enable select-loop serving of simple files for each virtual server with the SelectLoop parameter in the [ns/server/server-name] section.

SelectLoopMaxSize

256

The maximum number of simultaneous servings per select loop. If more than this number of files is served simultaneously, the overflow are served by regular threads. The regular threads will have the standard busy thread behavior if it is enabled.

The maximum number of simultaneous servings of static data is SelectLoopCount multiplied by SelectLoopMaxServe.

Enable select-loop serving of simple files for each virtual server with the SelectLoop parameter in the [ns/server/server-name] section.

SelectLoopThreshold

16384

The minimum size, in bytes, of files to be served by the select loop. With very small files that can be served by a single write() call, the select loop imposes additional overhead over letting the connection thread handle it.

Enable select-loop serving of simple files for each virtual server with the SelectLoop parameter in the [ns/server/server-name] section.

ServerLog

/log/server.log under the AOLserver home directory

The file to contain any notices, warnings, or errors generated by AOLserver if AOLserver is run as a background process. If AOLserver is run in the foreground, messages are written to standard output, and this parameter is ignored.

SkipLocks

Off

If set to On, mutex locking in Tcl interpreters is turned  off, resulting in a performance improvement. However, the following limitations are then enforced as well:  

  • You can't register requests after server startup (via Ns_RegisterRequest, Ns_RegisterProxyRequest, or ns_register_proc)

  • ·You can't define new Tcl procedures after server startup.

  • ·Errors in using Tcl thread objects (critical sections, events, caches, mutexes, read/write locks, semaphores, or threads) will cause the server to crash rather than display an error message.

SmtpPort

An SMTP smarterhost to be used, for example, to send mail through a firewall or a private/secured copy of sendmail running as a daemon on your local machine.

StackSize

SGI and DEC OSF: 32000

All others: the operating system default

The thread stack size. You may need to increase this parameter if an AOLserver request function or Tcl script is deeply nested, exhausting the stack space of the thread. If AOLserver is configured to use ADPs, for example, you may want to increase the thread stack size to 128K or more.

Uid

Unix only: Unix uid which can be set instead of setting the User parameter.

Umask

022

Unix only. A 3-digit, octal mask (code) that refers to the read/write/execute file permissions for owner, group, and other, respectively. It is used to turn-off any of the the nine permission bits when a file is created by AOLserver. This applies to all files that the server creates.

For example, a value of 022 would disable write permissions for everyone but the owner of the files. The default value of 0 does not turn off any permission bits, meaning files created by AOLserver have the value 644 for permissions, which gives read/write permission for the owner and read permission for everyone else.

User

Unix only: The user name that AOLserver is to be run as. If you start the AOLserver as the root user, you must set this parameter. If you have selected a port number below 1024 (a "privileged" port), you will need to start the AOLserver as the "root" and specify a Unix user for the server to change to after it acquires the port. If your port number is greater than 1024, you can leave this blank.

The MIME Types and MIME Icons Sections

The [ns/mimetypes] and [ns/mimeicons] configuration file sections allow you to have global settings for MIME types and MIME icons that can then be overridden by individual virtual servers in the [ns/server/server-name/mimetypes] and [ns/server/server-name/mimeicons] sections. This capability helps you maintain multiple virtual servers without having to set the MIME types and MIME icons for each virtual server.

Note that these configuration file sections are not listed in the Setup Server. To set the parameters, you can either use Expert Mode in the Setup Server and then choose Edit Configuration Sections, or you can edit the configuration file directly.

[ns/mimeicons]

This section is used to add .gif icons for each MIME type when generating directory listings in Fancy mode (see the DirectoryListing parameter in the [ns/server/server-name] section). Each parameter specifies an application and a .gif file. This section can be overridden by the [ns/server/server-name/mimeicons] settings for an individual virtual server.

Parameter

Default Value

Description

application

(defaults listed below)

A .gif file corresponding to the MIME type application.

The default MimeIcons parameter definitions are:

    text/*=/NS/Asset/doc.gif
    image/*=/NS/Asset/image.gif
    video/*=/NS/Asset/video.gif
    audio/*=/NS/Asset/sound.gif

AOLserver checks the mappings from most restrictive to least restrictive, so you could add the following definition as a subset of the text/* mapping:

    text/plain=/NS/Asset/plain.gif

[ns/mimetypes]

This section is used to map file name extensions to the content-type headers returned to browsers. Each parameter specifies an extension and the type to return. This section can be overridden by the [ns/server/server-name/mimetypes] settings for an individual virtual server.

Parameter

Default Value

Description

Default

The default MIME type to use if there is no explicit mapping specified for a file name extension.

NoExtension

The MIME type to use for files with no extension.

file-extension

(default MIME types listed below)

A content-type to return in the header information for the specified file extension.

The default MIME type parameter definitions are:

    .ai=application/postscript
    .aif=audio/aiff
    .aiff=audio/aiff
    .ani=application/x-navi-animation
    .art=image/x-art
    .au=audio/basic
    .avi=video/x-msvideo
    .bin=application/x-macbinary
    .bmp=image/bmp
    .dcr=application/x-director
    .dir=application/x-director
    .dp=application/commonground
    .dxr=application/x-director
    .elm=text/plain
    .exe=application/octet-stream
    .gbt=text/plain
    .gif=image/gif
    .gz=application/x-compressed
    .hqx=application/mac-binhex40
    .htm=text/html
    .html=text/html
    .jfif=image/jpeg
    .jpe=image/jpeg
    .jpg=image/jpeg
    .jpeg=image/jpeg
    .js=application/x-javascript
    .ls=application/x-javascript
    .map=application/x-navimap
    .mocha=application/x-javascript
    .mov=video/quicktime
    .mpe=video/mpeg
    .mpeg=video/mpeg
    .mpg=video/mpeg
    .nvd=application/x-navidoc
    .nvm=application/x-navimap
    .pbm=image/x-portable-bitmap
    .pdf=application/pdf
    .pgm=image/x-portable-graymap
    .pic=image/pict
    .pict=image/pict
    .pnm=image/x-portable-anymap
    .ps=application/postscript
    .qt=video/quicktime
    .ra=audio/x-pn-realaudio
    .ram=audio/x-pn-realaudio
    .ras=image/x-cmu-raster
    .rgb=image/x-rgb
    .rtf=application/rtf
    .sit=application/x-stuffit
    .snd=audio/basic
    .stl=application/x-navistyle
    .tar=appliation/x-tar
    .text=text/plain
    .tgz=application/x-compressed
    .tif=image/tiff
    .tiff=image/tiff
    .txt=text/plain
    .vrml=x-world/x-vrml
    .wav=audio/x-wav
    .wrl=x-world/x-vrml
    .xbm=image/x-xbitmap
    .xpm=image/x-xpixmap
    .z=application/x-compressed
    .zip=application/x-compressed

The Setup Server Section

[ns/setup]

This section is used to specify setup server parameters.

Parameter

Default Value

Description

ContinueOnError

on

Boolean value. If on, AOLserver will continue to run the setup server even if an error occurs loading any of the other virtual servers at startup. If off, AOLserver will stop if all virtual servers do not sucessfully start an error occurs.

Enabled

on

Boolean value. If on, AOLserver will start up the setup server.

Password

The nsadmin password for the setup server. Note that if the password is left blank, anyone can modify your configuration.

Port

9876

The port number that the setup server listens on. Note that the setup server listens on all IP addresses, only the port may be varied.

The Servers Sections

[ns/servers]

This section lists (and names) each of the virtual servers that are to be run within the AOLserver process.

Parameter

Possible Values

Description

server-name

"description text"

The name (user-defined) of a virtual server, which must be all lowercase. The description text can be any user-defined comments. The "setup" and "nssetup" server names are reserved by the built-in setup server.

[ns/server/server-name]

This section configures a virtual server. There should be one of these sections for each virtual server listed in the [ns/servers] section if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Assets

/servers/server/assets

Directory where graphics files to be included in pages are stored. It must be an absolute path.

If no directory is specified, the default directory (shown at left) under the installation directory is used. If the default directory does not exist, the /assets directory under the installation directory is used.

CheckInterval

60

The interval in seconds between internal server checks for dynamic thread creation or release.

Check-ModifiedSince

on

Boolean. If set to off, the "If-Modified-Since" headers will be ignored.

CheckStats

off

Boolean value. If set to On, statistics are sent to the server log in intervals determined by the CheckStatsInterval parameter. After each interval, two lines are written to the server log, one with totals for each statistic since the server started, and one with values for each statistic for the last interval.

If set to Off, statistics are still gathered and available to the Tcl functions.

The reported statistics are:

  • requests: the number of requests queued

  • HWM-queued: the maximum number (high water mark) of queued requests

  • HWM-threads: the maximum number (high water mark) of threads in use

  • busyconns: the number of connections rejected by the busy threads

  • mintime: the minimum time, in seconds, taken to serve a connection

  • maxtime: the longest time, in seconds, taken to serve a connection

  • avgtime: the total connection time, in seconds, divided by  the number of requests

  • bytes: the total number of bytes served

The statistics that return a time are generally only useful for virtual servers that serve large and somewhat uniformly-sized items. Because simple pages serve so quickly, the minimum time usually hovers around zero.

Note that these statistics are not guaranteed to be 100% accurate - they are designed to give a general idea of server performance, and the gathering of the statistics favors minimal impact on performanace over perfect accuracy. Because of this, we recommend that you not use them to generate billing information.

You can, alternatively, use the ns_intervalstats and ns_resetintervalstats Tcl functions to gather interval statistics instead of the CheckStats and CheckStatsInterval parameters. We recommend, however, that you do not use both the Tcl interval functions and the interval configuration parameters, because the interval parameters will reset the statistics underneath the Tcl functions and may cause unintended results.

CheckStatsInterval

300

The number of seconds in an interval for purposes of writing statistics to the server log. Statistics reporting must be enabled with the CheckStats parameter. Interval statistics are reset after the statistics have been written to the server log.

CreatMode

664

Unix only. A 3-digit, octal mask (code) that refers to the read/write/execute file permissions for owner, group, and other, respectively. It is used to set any of the nine permission bits for all content files that the server creates.

For example, a value of 666 would allow read/write access for the owner, group, and other. The umask parameter is applied to this value. So, if this parameter was set to 666, and umask was set to 22, the resulting mode would be 644.

DirectoryFile

index.htm, index.html, index.shtml

A comma-separated list of default files to get if the URL specifies only a directory. For example:

DirectoryFile=index.htm, index.html, index.shtml

This virtual server will try each of the filenames in the list, left to right.

DirectoryListing

Simple

Valid values are "None", "Simple", "Stats", and "Fancy". Controls the level of detail in the automatically-generated directory listings.

"None" specifies that no directory listing is generated and a forbidden response message will be returned. "Stats" is the same as "Fancy" except that the description is not listed.

ElevateAcceptPriority

Solaris: on

All others: off

Boolean value. If set to on, the thread that accepts connections is given priority over threads that process connections, which can increase throughput.

EnableTclPages

off

Boolean value. If set to On, all *.tcl files under the pageroot will be parsed. If it is Off, *.tcl files are treated as text/plain.

FileLocking

off

Boolean. If set to on, AOLserver enables the locking of pages with AOLpress (version 1.2 or higher).

If set to off, page locking is disabled, and the Lock and Unlock menu items will be dimmed in AOLpress.

FlushContent

on

Boolean. If set to on, this virtual server will read all HTTP client content before closing the connectoin.

FlushQueue

off

Boolean. If on, this virtual server flushes its connection queue before stopping.

ForbiddenResponse*

A URL to display when a "Forbidden" status is returned. For example: /errorpages/forbidden.html.

HeaderCase

Preserve

Determines how AOLserver treats the case of incoming HTTP header key names. (The case of header key values is always preserved.) If set to Preserve, case is preserved for key names. If set to ToLower, header key names are converted to lower case. If set to ToUpper, header key names are converted to upper case.

HideDotFiles

on

Boolean. If set to on, files that match ".*" (excluding "..") are not shown in a directory listing for the virtual server.

LogQueryOnTclError

Off

Boolean value. This parameter allows you to turn on or off the reporting of form data to the server log when there is an error. If there is an error when processing a POST and the LogQueryOnTclError parameter is set to On, the set of keys and values from the form are written to the server log in addition to the Tcl traceback.

If set to Off, the default, only the Tcl traceback is written to the server log.

MaxBusyThreads

0

The maximum number of threads this virtual server can use within the nsd process for handling "server busy" connections. If additional threads are requested, the requests will be forced to wait. If 0, the "server busy" error will never be given.

See the MaxThreads parameter for a description of server busy connections.

MaxLine

8192

The maximum number of bytes for the HTTP request or header line.

MaxHeaders

16384

The maximum number of bytes for all HTTP header lines in a request.

MaxPost

65536

The maximum size in bytes of an HTTP POST accessed through the Ns_ConnGetQuery function (in C) or the ns_conn form function (in Tcl).

For larger POSTs, access the content directly with the Ns_ConnRead function.

MaxThreads

50

The maximum number of threads this virtual server can use within the AOLServer process, excluding threads used for returning "server busy" status pages. The absolute maximum number of threads the virtual server can use is MaxThreads plus MaxBusyThreads. If more threads are requested than MaxThreads, the requests will be forced to wait until MaxWait requests are pending (at which point "server busy" status will be returned), or the number of waiting requests drops below MaxThreads.

About Server Busy Connections: When a connection comes in, it is added to a list of connections. As many as MaxThreads of these are processed at once, and the rest wait their turn in the queue. When this queue grows to MaxWait (not counting the connections currently being processed, of which there are up to MaxThreads) new threads are spawned to return a "server busy" error; as many as MaxBusyThreads are started to do this. Once MaxBusyThreads has been reached, connections queue up to be given the "server busy" error. If LogBusyRequests is set to On, "server busy" connections will be added to the access log.

MaxWait

25

The number of connections over MaxThreads to queue before sending the "server busy" error message. Does not apply if MaxBusyThreads is 0.

MinBusyThreads

0

The number of threads in the server process to initialize when this virtual server is started for handling "server busy" connections.

See the MaxThreads parameter for a description of server busy connections.

MinThreadAge

60

The minimum lifetime in seconds for a connection thread. AOLserver will not terminate threads which were recently started even if the server is idle at the moment.

MinThreads

0

The number of threads in the AOLserver process to initialize when this virtual server is started.

MkdirMode

775

Unix only. A 3-digit, octal mask (code) that refers to the read/write/execute directory permissions for owner, group, and other, respectively. It is used to set any of the nine permission bits for all content directories that the server creates.

For example, a value of 666 would allow read/write access for the owner, group, and other. The umask parameter is applied to this value. So, if this parameter was set to 666, and umask was set to 22, the resulting mode would be 644.

Note that execute permission is required for Unix users to search directories.

NotFoundResponse*

A URL to display when a "Not Found" status is returned. For example: /errorpages/notfound.html.

NoticeBackground

Background image for notice pages.

NoticeBgColor

#ffffff (white)

Background color for notice pages, specified as either a valid HTML color name or an RGB value.

PageRoot

/servers/server/pages

Directory where pages for this virtual server are stored.

QuotaSize

0

The maximum size in kilobytes to which the pageroot and its descendants are allowed to grow. The quota is also enforced for the nsftp module. The default value of 0 means that there is no quota for this virtual server.

ReturnMWTopPage

off

Boolean value. Set to On to enable MiniWeb top pages to be returned. This parameter is off by default, for speed and efficiency reasons.

SelectLoop

Off

Boolean value. Set this parameter to On if you want to enable this virtual server to use the select loop to serve static data (files and files from cache). When this feature is enabled, static data are served from a single thread in a single loop based on the select() system call. This should improve performance on most systems over many threads serving static data.

There is one common select loop that is shared among all of the virtual servers, but you can enable each virtual server with this parameter to use or not use the select loop.

Configure select-loop serving of simple files with the SelectLoop* parameters in the [ns/parameters] section.

ServerBusyResponse

A URL to display when a "server busy" status is returned. For example, /errorpages/busy.html. Avoid referencing inline images on the same virtual server on this page.

See the MaxThreads parameter for a description of server busy connections.

ServerInternalErrorResponse*

A URL to display when an internal server error occurs. For example: /errorpages/server-internal-error.html.

TrailerFindEnd

on

Boolean. If set to on, the trailer will be inserted just before any </BODY> and </HTML> end tags. Otherwise, the trailer is added after these tags and may be ignored by some browsers.

TrailerFmt

%c

The date/time format used for the result of the :LASTMOD: variable (if it is used in TrailerText).

TrailerText

HTML tags and text that make up the content of your trailer. Must be all on one line. You can use the :LASTMOD: variable to insert the date the page was last modified.

TrailerType

text/html

Set to text/html to enable a trailer that includes both text and HTML tags.

UnauthorizedResponse*

A URL to display when an "Unauthorized" status is returned. For example: /errorpages/unauthorized.html.

UserMapDir

The subdirectory under the user's home directory in which to search for files when a URL containing ~username is specified. If blank (the default), ~username URLs will not be mapped to user directories.

Note that this parameter can be overridden by an URL to file mapping in the Aliases section if the mapping specifies "/~" as the URL. See page 50 for more information.

Verbose

off

Boolean value. Set to on to specify verbose status messages. Note: Setting Verbose on will result in a large amount of output in the server log.

Webmaster

The email address for the webmaster. If specified, a link to the webmaster's email address is provided on notice pages.

*These parameters allow you to define custom error message pages for specific AOLserver return statuses. If these custom error messages cause an error, AOLserver returns the normal error message page corresponding to the return status and logs the additional error to the error log.

[ns/server/server-name/adp]

This section is used to configure AOLserver Dynamic Pages (ADPs). Caching for ADPs can also be enabled by loading the nscache module in the [ns/server/server-name/modules] section and setting parameters in the [ns/server/server-name/module/nscache] and [ns/server/server-name/module/nscache/adp] sections.

Parameter

Default Value

Description

Map

The Map parameter specifies which pages the server will parse. You can specify a file extension (such as /*.adp) or a directory (such as /usr/pages/adp). If no directory is specified, the pages directory is assumed. The wildcards * ? and [] can be included in the Map specification. You can specify multiple Map settings.

The following example specifies that all files in the pages directory with the extensions .adp or .dci will be parsed, and all files in the /usr/pages/myadps directory will be parsed.

    Map=/*.adp
    Map=/*.asp
    Map=/usr/pages/myadps

GlobalInclude

Off

Boolean value. Set to On to specify that Tcl in ADPs run with ns_adp_parse or ns_adp_include will be evaluated at the global level. If this parameter is Off, Tcl in ADPs will be evaluated locally.

HideSource

On

Boolean value. Set to On to restrict users from viewing the source of the Tcl script in browsers that allow HTML source to be viewed. If the HTTP client sends an Accept header containing text/x-server-parsed-html, the source of the file is returned. AOLpress sends this header if you view the HTML source (by clicking on the Show HTML icon or choosing "Show HTML" from the Tools menu) and then choose "Reload Without SSI" from the File menu.

If this parameter is Off, you can view the Tcl script source in AOLpress as described above.

If this parameter is On, only the HTML resulting from the Tcl script will be shown when a user views the HTML source for a page.

IgnoreErrors

On

Boolean value. If set to Off, and an error occurs while evaluating an ADP, an error page will be returned and the remainder of the ADP will not be evaluated.

If set to On, errors in ADPs will be ignored and the ADP will continue processing.

MaxCallDepth

256

The maximum number of nested ADP evaluations. Nested ADP evaluations, such as recursive ns_adp_include calls (where an ADP includes itself), can often lead to crashes

The ns_adp_include and ns_adp_parse Tcl functions, and the Ns_AdpParseFile and Ns_AdpParseFp and  Ns_AdpParseBuffer C functions, return an error if this limit is exceeded.

[ns/server/server-name/aliases]

This section is used to specify the file returned for the specified URLs. All mappings are listed as URL=file pairs. See the "Configuring URL to File Mappings" section for details and examples.

Parameter

Value

Description

URL

filename

The URL is a relative URL to be mapped to a different filename. A leading slash "/" is optional, except for the special case where the specified URL consists only of a slash, in which case the mapping overrides the PageRoot parameter defined for this virtual server and defines the implicit root for all of the relative paths specified in the other mappings.

The filename is the filename that the specified URL will be mapped to. You must specify a file and not another URL.

[ns/server/server-name/cgi]

This section configures CGI for a virtual server. There should be one of these sections for each virtual server if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Environment

Specifies a section in the configuration file to be used as the default environment for CGI scripts run on this server. For example, if you set Environment=CGIenv, you must include a [ns/environment/CGIenv] in the configuration file containing environment variable definitions. The environment variables will be in addition to the standard CGI variables.

GetHostByAddr

off

Boolean value. If set to Off (the default), REMOTE_HOST will be the same as REMOTE_ADDR, thereby improving performance by eliminating reverse lookup requests. If set to On, a reverse lookup request is used to supply the REMOTE_HOST value.

Interps

Specifies a section in the configuration file to define mappings between extensions of CGI script files and programs. For example, if you set Interp=CGIinterps, you must include a [ns/interps/CGIinterps] section in the configuration file containing appropriate mappings. See below for a description of the format of an Interps section.

Map

Method, URL, and directory where CGI programs reside. A trailing slash on the URL is not allowed. The directory must be an absolute pathname. A trailing slash on the directory is optional. If the directory is missing, the pages directory is assumed. Examples:

Map =GET /cgi /usr/local/cgi

Map =POST /*.cgi

You may have more than one Map entry. Typically, there are at least Map entries for the GET and POST methods.

MaxInput

1,024,000

Maximum number of bytes that the virtual server will send from an HTTP client as input into an NPH (non-parsed header) CGI program. This limit is provided because the input to an NPH script is provided as a temporary file which should not grow without bound instead of through a pipe.

[ns/server/server-name/db]

This section specifies the database pools that will be accesible by a virtual server. The available database pools are listed in the [ns/db/pools] section. There should be one of these sections for each virtual server if you want to restrict a virtual server's access to a subset of the available database pools.

Parameter

Default Value

Description

DefaultPool

The default pool for the ns_conn db and ns_db gethandle Tcl functions to access.

Pools

(no database pools are accessible by default)

A comma-delimited list of pool names specifying the pools that are to be accessible from this virtual server, or "*" to signify that all pools should be accessible.

The available pools are listed in the [ns/db/pools] section.

[ns/server/server-name/mimeicons]

This section is used to add .gif icons for each MIME type when generating directory listings in Fancy mode (see the DirectoryListing parameter in the [ns/server/server-name] section). Each parameter specifies an application and a .gif file. This section overrides the [ns/mimeicons] settings for this virtual server.

Parameter

Default Value

Description

application

(defaults listed below)

A .gif file corresponding to the MIME type application.

The default MimeIcons parameter definitions are:

    text/*=/NS/Asset/doc.gif
    image/*=/NS/Asset/image.gif
    video/*=/NS/Asset/video.gif
    audio/*=/NS/Asset/sound.gif

AOLserver checks the mappings from most restrictive to least restrictive, so you could add the following definition as a subset of the text/* mapping:

    text/plain=/NS/Asset/plain.gif

[ns/server/server-name/mimetypes]

This section is used to map file name extensions to the content-type headers returned to browsers. Each parameter specifies an extension and the type to return. This section overrides the [ns/mimetypes] settings for this virtual server.

Parameter

Default Value

Description

Default

The default MIME type to use if there is no explicit mapping specified for a file name extension.

file-extension

(default MIME types listed below)

A content-type to return in the header information.

NoExtension

The MIME type to use for files with no extension.

The default MIME type parameter definitions are:

    .ai=application/postscript
    .aif=audio/aiff
    .aiff=audio/aiff
    .ani=application/x-navi-animation
    .art=image/x-art
    .au=audio/basic
    .avi=video/x-msvideo
    .bin=application/x-macbinary
    .bmp=image/bmp
    .dcr=application/x-director
    .dir=application/x-director
    .dp=application/commonground
    .dxr=application/x-director
    .elm=text/plain
    .exe=application/octet-stream
    .gbt=text/plain
    .gif=image/gif
    .gz=application/x-compressed
    .hqx=application/mac-binhex40
    .htm=text/html
    .html=text/html
    .jfif=image/jpeg
    .jpe=image/jpeg
    .jpg=image/jpeg
    .jpeg=image/jpeg
    .js=application/x-javascript
    .ls=application/x-javascript
    .map=application/x-navimap
    .mocha=application/x-javascript
    .mov=video/quicktime
    .mpe=video/mpeg
    .mpeg=video/mpeg
    .mpg=video/mpeg
    .nvd=application/x-navidoc
    .nvm=application/x-navimap
    .pbm=image/x-portable-bitmap
    .pdf=application/pdf
    .pgm=image/x-portable-graymap
    .pic=image/pict
    .pict=image/pict
    .pnm=image/x-portable-anymap
    .ps=application/postscript
    .qt=video/quicktime
    .ra=audio/x-pn-realaudio
    .ram=audio/x-pn-realaudio
    .ras=image/x-cmu-raster
    .rgb=image/x-rgb
    .rtf=application/rtf
    .sit=application/x-stuffit
    .snd=audio/basic
    .stl=application/x-navistyle
    .tar=appliation/x-tar
    .text=text/plain
    .tgz=application/x-compressed
    .tif=image/tiff
    .tiff=image/tiff
    .txt=text/plain
    .vrml=x-world/x-vrml
    .wav=audio/x-wav
    .wrl=x-world/x-vrml
    .xbm=image/x-xbitmap
    .xpm=image/x-xpixmap
    .z=application/x-compressed
    .zip=application/x-compressed

[ns/server/server-name/shtml]

This section configures server-parsed HTML for a virtual server. There should be one of these sections for each virtual server if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Map

The Map parameter lets you specify which pages the server should parse. If the directory is missing, the pages directory is assumed. The format can be either of:

type_or_location

type_or_location(option, ...)

The type_or_location can be a file extension (such as /*.shtml) or a directory (/usr/pages/parsed). It can also contain the * ? and [ ] wildcards.

The options are:

NoExec prevents the #exec command from being parsed.

NoIncludeSrc specifies that the server will not return the source of each command. If NoIncludeSrc is omitted (the default condition), the server will return the source of each command, followed by the results of parsing it, followed by "<!--#nsendcmd-->". This capability can be used by browsers that allow editing of server-parsed HTML, and will eventually be supported by AOLpress.

For example, consider this command:

    <!-- #echo var="DATE_LOCAL" -->

If NoIncludeSrc is omitted, AOLserver will translate the command into:

    <!-- #echo var="DATE_LOCAL" -->
    Fri May 03 18:22:01 1996
    <!-- #nsendcmd -->

A standard browser will ignore the SHTML command, because it is in a comment.

RunCmdInDir specifies that the #exec command will be run in the directory where the server-parsed HTML page resides, instead of the server home directory. For example:

Map=/*.shtml(RunCmdInDir)

SetExpires sets the expired header for a .shtml file to the current date.

SetLastModified sets the last-modified header to the mod-time of the .shtml file.

SubstituteErrors causes any error messages caused by invalid commands to be included in the page. Normally error messages are sent back instead of the parsed document.

[ns/server/server-name/tcl]

This section configures Tcl for a specific virtual server. There should be one of these sections for each virtual server if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

AutoClose

on

If AutoClose is on, all non-shared files opened by an individual interpreter in the group will be closed when Ns_TclDeAllocateInterp is invoked. (Other interpreters in the group are not affected.) Ns_TclDeAllocateInterp is called after each Tcl request procedure.

It is recommended that you leave the AutoClose parameter set to on and share files between interpreters.

ClientDebug

An IP address to be enabled by default for client Tcl debugging. You can use this parameter to debug ADPs as well, in which case error backtraces resulting from running an embedded Tcl script are inserted into the page.

You can have multiple ClientDebug entries to specify multiple addresses. For example:

    ClientDebug=111.222.333.444
    ClientDebug=111.222.333.445

Wildcards and significant bit designations are not supported when specifying addresses for ClientDebug.

EnableAdmin

On

Boolean value. If set to Off, the Tcl Administration link is removed from the /NS/Admin page and all of the Tcl administration URLs (e.g., /NS/Tcl/Admin, /NS/EvalTcl, etc.) are disabled. If you try to access any of the Tcl administration URLs, you will receive a "not found" error.

If this parameter is set to On, the default, Tcl evaluation is enabled.

InitScript

source [ns_library private]/init.tcl

Tcl script to run at startup.

Library

/servers/server/modules/tcl

Directory for private Tcl script library for this virtual server. Tcl scripts in this private library will override identically-named Tcl scripts in the shared Tcl library.

NumInterps

5

This parameter is ignored since AOLserver now uses linked interpreters. It is allowed for backwards compatibility only.

ReinitScript

Tcl script run before every Tcl script.

SharedGlobals

Off

Boolean value. Set to On to retain backwards compatibility with AOLserver Version 2.1, which used only one global variable table per virtual server.

If this parameter is Off, each Tcl interpreter will have its own global variable table, and a shared variable table will be used for variables global to all the interpreters for a virtual server. Use the ns_share Tcl command to make a variable global to all Tcl interpreters for a virtual server.

SharedLibrary

/modules/tcl

Directory for shared Tcl script library used by this virtual server. Any Tcl scripts in this shared library will be overridden by identically-named Tcl scripts in the private Tcl script library.

[ns/server/server-name/modules]

This section lists the AOLserver modules that are to be loaded into a virtual server. There should be one of these sections for each virtual server listed in the [ns/servers] section.

The name of the module can be any name you choose, but it must then be referenced as the module name in the appropriate [ns/server/server-name/module/module-name] section. For example, if you specify mynsdb=nsdb.so, you must configure the module in a section called [ns/server/server-name/module/mynsdb] instead of [ns/server/server-name/module/nsdb].

The file specified as the usual value for each parameter exists in the bin directory under the AOLserver home directory by default. If it resides somewhere else, include an absolute path specification along with the file.

Parameter

Usual Value

Description

nscache

nscache.so

If present, ADP caching, static file caching, and Tcl caching can be enabled. Enable caching in the [ns/server/server-name/module/nscache] section.

nsdynamo

nsdynamo.so

If present, enables support for ATG's Dynamo Server. See page 129 for configuration instructions.

nsftp

nsftp.so

If present, enables FTP access for this virtual server. Configure the FTP module in the [ns/server/server-name/module/nsftp] section.

Note: Make sure the nsperm module is loaded before the nsftp module.

nslog

nslog.so

If present, enables an access log for this virtual server.Configure the access log in the [ns/server/server-name/module/nslog] section

nsnlog

nsnlog.so

If present, enables network logging for this virtual server.Configure network logging in the [ns/server/server-name/module/nsnlog] section

nsperm

nsperm.so

If present, enables access control capabilities for this virtual server. Configure these capabilities in the [ns/server/server-name/module/nsperm] section.

nsservlet

nsservlet.so

If present, enables support for the Java Servlet API. See page 131 for configuration instructions.

nssock

nssock.so

If present, allows TCP/IP sockets connection for this virtual server.Configure the sockets connection in the [ns/server/server-name/module/nssock] section.

nsssl

nsssl.so

If present, allows SSL connections for this virtual server.Configure the SSL connection in the [ns/server/server-name/module/nsssl] section.

nstext

nstext.so

If present, enables full-text processing for this virtual server. Configure the full-text module in the [ns/server/server-name/module/nstext] section

nsvhost

nsvhost.so

If present for a virtual server, enables virtual hosting with this virtual server as the "master" server. See page 127 for information on configuring virtual hosting.

[ns/server/server-name/module/nscache]

This section allows you to enable ADP, static file, or Tcl caching.

Parameter

Default Value

Description

CacheADP

Off

Boolean value. If set to On, ADP caching is enabled. Configure ADP caching in the [ns/server/server-name/module/nscache/adp] section.

CacheStatic

Off

Boolean value. If set to On, static file caching is enabled. Configure static file caching in the [ns/server/server-name/module/nscache/static] section.

CacheTcl

Off

Boolean value. If set to On, Tcl caching is enabled. Note that Tcl scripts are not cached by default; you must use the ns_cache function to cache a script. However, this parameter can be set to Off to disable all Tcl caching from taking place, regardless if ns_cache is used.

Configure Tcl caching in the [ns/server/server-name/module/nscache/tcl] section.

[ns/server/server-name/module/nscache/adp]

This section allows you to configure ADP caching.

Parameter

Default Value

Description

DefaultExpires

60

The number of seconds after which a cache entry will automatically expire and be removed from the cache. The ADP cache uses any Expires headers that are set when the ADP is served to determine when ADPs should expire from the cache. The DefaultExpires time is only used if no Expires header is set explicity by the ADP.

You can also use the ns_setexpires Tcl function to set the Expires header.

DoStat

On

Boolean value. If set to On, a "stat" call is performed for each request, and the cache will detect when files have changed on disk and update them in the cache. There is a slight performance penalty in this case.

If set to Off, files are not checked on every request. Files are updated in the cache only when they expire naturally.

MaxEntry

0

The maximum size, in kilobytes, for any single cache entry. Setting this parameter to 0 means that there is no limit to the size of a cache entry. Set this parameter to a value greater than 0 to prevent a single large file from using up too much of the cache.

MaxExpires

10800

The maximum number of seconds after which cache entries will be forced to expire, even if a higher value was set in the Expires header during processing. The default value, 10800, is equivalent to 3 hours.

MaxSize

0

The maximum size, in kilobytes, of the cache. Setting this parameter to 0 means that there is no limit on the size of the cache.

[ns/server/server-name/module/nscache/static]

This section allows you to configure static file caching. AOLserver allows caching of HTML pages and simple (static) files, such as graphics. You can minimize the number of times each file must be read from disk, allowing pages to be served more efficiently.

If static file caching is enabled, there will be a Cache Administration link on the /NS/Admin page of the server. You can follow the link to get to the Cache Administration page, which will allow you to empty the static file cache.

Parameter

Default Value

Description

DefaultExpires

60

The number of seconds after which a cache entry will automatically expire and be removed from the cache. The static file cache uses any Expires headers that are set when the HTML  page is served to determine when pages should expire from the cache. You cannot explicitly set an Expires header for the page unless it is an ADP.

DoStat

On

Boolean value. If set to On, a "stat" call is performed for each request, and the cache will detect when files have changed on disk and update them in the cache. There is a slight performance penalty in this case. If set to Off, files are not checked on every request. Files are updated in the cache only when they expire naturally.

MaxEntry

0

The maximum size, in kilobytes, for any single cache entry. Setting this parameter to 0 means that there is no limit to the size of a cache entry. Set this parameter to a value greater than 0 to prevent a single large file from using up too much of the cache. For example, setting MaxEntry=1024 means that any file over one megabyte in size will always be retreived from disk and never from the cache.

MaxSize

0

The maximum size, in kilobytes, of the cache. Setting this parameter to 0 means that there is no limit on the size of the cache.

[ns/server/server-name/module/nscache/tcl]

This section allows you to configure Tcl caching. To use Tcl caching, the Tcl scripts to be cached must reside in a Tcl module. For example:

    [ns/server/server1/modules]
    nscache=nscache.so
    myTclCache=Tcl

The Tcl scripts would then reside in the directory:

    /servers/server1/modules/tcl/myTclCache

Parameter

Default Value

Description

DoStat

On

Boolean value. If set to On, a "stat" call is performed for each request, and the cache will detect when files have changed on disk and update them in the cache. There is a slight performance penalty in this case.

If set to Off, files are not checked on every request. Files are updated in the cache only when they expire naturally.

Enabled

On

Boolean value. If set to On, the Tcl cache is enabled, and ns_cache eval will attempt to get the result from the cache before evaluating the procedure.

If set to Off, ns_cache eval will always evaluate the procedure.

MaxEntries

The maximum number of entries that can be in this cache. The default is that there is no limit.

MaxEntryAge

The maximum amount of time in seconds (since it was last accessed) that an entry should stay in the cache. The default is that there is no limit.

MaxEntrySize

The maximum number of bytes per entry that will be cached. If the data to be cached is greater than size, it won't be cached. The default is that there is no limit.

MaxLifetime

The maximum amount of time in seconds (since it was orginally put into the cache) that an an entry should stay in the cache.

MaxSize

The kbytes argument specifies the total number of kilobytes to keep in the cache.

PrunePercentage

10

The percentage of cache entries that should be pruned when MaxEntries is reached. Specifying 0 (zero) specifies that the cache should not be pruned. The default is 10%.

[ns/server/server-name/module/nsdynamo]

This section configures support for ATG's Dynamo Server. See page 129 for complete configuration instructions.

Parameter

Default Value

Description

DynamoFileExts

jhtml, jhtm, jtxt, dyn, map, dynjava

These are the various file extensions of your Dynamo documents.

DynamoHost

localhost

This is a hostname or a comma delimited set of hostnames that the Dynamo server uses to listen for incoming Dynamo request from AOLserver.

Note: There should be one DynamoHost for each DynamoPort in sequence.

DynamoPort

20000

The is a  port number or a comma delimited set of port numbers that the Dynamo servers should listen for remote connect request on.

Note: There should be one DynamoHost for each DynamoPort in sequence.

DynamoTimeout

300

The timeout value in seconds for connections to the Dynamo server and for data transfers.

DynamoUrl

/dynamo_docs

The Dynamo URL to use when registering the Dynamo handler and the directory where your Dynamo documents reside.

DynamoVerbose

Off

Boolean value. Set to on to enable verbose error messages.

Note: Setting DynamoVerbose may result in a large amount of output in the server log file.

[ns/server/server-name/module/nsftp]

This section configures the nsftp module for a virtual server. There should be one of these sections for each virtual server that includes an nsftp module if you want to change any of the default settings for the parameters..

Parameter

Default Value

Description

FtpAddress

The IP address to listen for remote FTP connect request on. If this parameter is not set, nsftp will listen on all interfaces.

FtpAdminEmailAddr

nsadmin@hostname

The email address used for the "site help" command.

FtpAllowAnonymous

Off

Boolean value. Set to on to enable anonymous logins. If anonymous logins are enabled, users can browse and download from the web site via FTP.

This parameter is valid only if FtpRootDir is set to a directory inside your virtual server page root.

FtpAllowChangeMode

Off

Boolean value. Set to On to enable the use of the chmod command. The chmod command allows users to apply absolute changes to file and directory permission bits using octal numbers ranging from 000 to 777.

(Note: This parameter is not supported on the Linux platform.)

Syntax: chmod <000-777> <filename>

Note that CHMOD's UID is dependent on the server's UID/User. If AOLServer runs as super-user or root after start-up, then chmod allows users to change file and directory permission bits as root.

FtpAllowKeepAlive

Off

Boolean value. Set to on to allow FTP clients that support the NOOP command to keep the connection alive and avoid server timeouts.

FtpAnonRootDir

your virtual server page root

The directory that you want to be the anonymous FTP root directory. Specify the directory relative to your to your virtual server's page root directory.

This parameter is valid only if FtpAllowAnonymous is On and FtpRootDir is set to a directory inside your virtual server page root.

FtpClientTimeout

300

The number of seconds before an inactive client connection will timeout. The valid range is 0 - 2147483647. Setting this parameter to 0 disables timeouts, meaning that the server will wait indefinitely. Setting this parameter to a value under 120 results in a warning in the FTP log.

FtpDataConnTimeout

60

The number of seconds before timeout when attempting a data connection to the client. The valid range is 1- 2147483647. Setting this parameter to a value under 60 results in a warning in the FTP log.

FtpHostname

your hostname (e.g., henry.yourserver.com)

This is used for multiple interfaces (multi-homing)

FtpMaxAnonUsers

25

The maximum number of simultaneous FTP logins by anonymous users (if anonymous users have been enabled by FtpAllowAnonymous). The acceptable range of this parameter is 1 - 65535.

FtpMaxSysUsers

25

The maximum number of simultaneous FTP logins by system users. The acceptable range of this parameter is 1 - 65535.

FtpPasvCloseLinger

30

The number of seconds in which to close sockets, which may be more or less than the kernel default settings. The acceptable range of values for this parameter is 1 - 2147483647.

FtpPasvPortMax

65535

The maximum PASV port range for firewalls. The acceptable range of values is 1 - 65535.

FtpPasvPortMin

1

The minimum PASV port range for firewalls. The acceptable range of values is 1 - 65535.

FtpPort

21

The port number for your FTP server.

FtpRootDir

your virtual server page root

The directory you want to be the FTP root directory. If you choose a directory other than the virtual server's page root, you must be the FtpSystemUser to connect to the server, since all permission records become irrelevant.

FtpRunServerTraces

Off

Boolean value. Set to On to enable traces to be run on FTP requests (e.g., accesslog type logging). For example, an entry in access.log may look like this:

henry.yourserver.com -

eric [23/May/1997:14:38:22-0400]

"PUT /markd.txt FTP" 200 0 -

"FTP (DELE markd.txt)"

Full text indexes will be automatically updated if you have full text archiving and indexing enabled for the nstext module (with the Archive and Index parameters, respectively).

FtpSysLog

On

Boolean value. Set to on to enable a syslog for the ftp server. The syslog file logs start-up, login, timeout, and dropped connection information. The syslog file is: <AOLserver-root>/servers/<server-name> /modules/nsftp/nsftp.log.

FtpSystemUser

nsadmin

The name of the system user for the virtual server.

FtpTcpWrappers

Off

Boolean value. Set to On to enable hosts.allow and hosts.deny lookups authentication. For example, if a host isn't allowed with hosts.allow, then the control connection is closed immediately.

FtpTmpDir

The directory you want to be the FTP temporary directory.

The default temporary directory is your virtual server nsftp module directory. If you choose a different directory, it must be an absolute path.

FtpXferLog

On

Boolean value. Set to On to enable a file transfer log for the ftp server. The file transfer log is: <AOLserver-root>/servers/<server-name> /modules/nsftp/nsxfer.log.

See the Xferlog man page for detailed information on the contents and format of the file.

[ns/server/server-name/module/nslog]

This section configures the nslog module for a virtual server. There should be one of these sections for each virtual server that includes an nslog module if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

EnableHostnameLookup

off

Boolean value. Select on to convert IP addresses into host names before logging entries in the access log file. Setting this parameter on will slow down the server, potentially to the point at which all threads are waiting for DNS response instead of servicing connections. Consider increasing the virtual server MaxThreads in this case.

ExtendedHeaders

Header information to be written to the access log. Specify a comma-separated list of headers or "*" to have all header information written to the access log. The possible headers are: ACCEPT, FROM, IF-MODIFIED-SINCE, REFERER, and USER-AGENT.

File

access.log

The name of the file where the access log is to be stored. If no directory is specified, the file will be created in the /servers/server-name/modules/nslog directory. If you specify only an absolute or relative directory and no filename, the file access.log will be created in that directory.

Accesses are logged in CERN Common Logfile Format.

LogCombined

off

Boolean value. If set to on, logs will be generated in the NCSA combined log format. The NCSA combined log format will include the referring URL and the user agent (so you can turn off LogRefer and LogUserAgent), and it will not surround them with double quotes.

LogRefer

off

Boolean value. If set to on, the referring URL for each access will be logged, letting you track the sources of hits to your site. Note that this information is appended to each log line, and some log analysis tools may require its removal. Use the LogCombined parameter to generate logs in the NCSA combined log format.

LogUserAgent

off

Boolean value. If set to on, the user-agent of each access will be logged, letting you track which browsers are being used to access your site. Note that this information is appended to each log line, and some log analysis tools may require its removal. Use the LogCombined parameter to generate logs in the NCSA combined log format.

MaxBackup

5

The maximum number of access logs that will be saved. This amount includes the current access log. For example, a value of 5 means the current access log plus 4 backup logs.

RollDay

*

The day of the week on which to roll the access log, or "*" to roll the access log every day of the week. The day must be specified with at least the first three letters of its name, e.g., "Mon", "Mond", "Monda", or "Monday". The access log will be rolled at 12:01 a.m. on the specified day or days.

The file name of the access log will be access.log.yymmdd, where yy is the year, mm is the month number, and dd is the day of the month.

RollFmt

%Y-%m-%d

The format for the date and time to be appended to the log file name. Formats must be specified using the same format options as the strftime C library function.

The complete log file name will be Fname.datetime, where Fname is determined by the File parameter, and datetime is determined by the RollFmt parameter.

RollHour

0 (midnight)

The hour at which the access log will be rolled on the day or days specified by the RollDay parameter. The hour must be specifed as an integer from 0 to 23 representing the hour in military time.

RollLog

on

Boolean value. If set to On, the access log is rolled according to the settings for the RollDay and RollHour parameters. If set to Off, log entries will be written to the same access log indefinitely. However, the access log can still be rolled on SIGHUP if the RollOnSignal parameter is set to On (the default).

RollOnSignal

on

Boolean value. The default, "on", specifies that the access log will be rolled when a SIGHUP signal is sent to the process id of the running server. The process id can be found in the file specified by the PidFile parameter, or if PidFile is not specified, in the file:

/serverhome/log/nspid.setup-server-port

For example, if the setup server port is 9876, the process id is in the file nspid.9876 in the log subdirectory of the server home directory.

If set to "off", the access log will not be rolled when a signal is sent.

[ns/server/server-name/module/nsnlog]

This section configures the nsnlog module for a virtual server, which configures network logging. The nsnlog module allows one or more AOLservers to log to another AOLserver. The advantage of doing this is that the single AOLserver receiving the log information will multiplex the log entries from the remote AOLservers into a single log file. This can be very useful to a busy web site that mirrors content on several identical servers, because they can all log to a single logging server.

There should be one of these sections for each virtual server that includes an nsnlog module.

Parameter

Default Value

Description

Address

IP address to listen for remote connect requests on. If this parameter is not set, AOLserver will listen on all interfaces.

Directory

The default directory to store log files which aren't absolute. The default is for the remote server to request the file specified with the nslog File parameter. If the File parameter is missing, nslog will send the virtual server name as the File and the nsnlog logging server will store the file in this directory.

MaxBackup

10

The maximum number of access logs that will be saved. This amount includes the current access log. For example, a value of 5 means the current access log plus 4 backup logs.

Port

Port to listen for remote connect requests on.

RollOnSignal

on

Boolean value. The default, "on", specifies that all access logs will be rolled when a SIGHUP signal is sent to the process id of the running server. The process id can be found in the file specified by the PidFile parameter, or if PidFile is not specified, in the file:

/serverhome/log/nspid.setup-server-port

For example, if the setup server port is 9876, the process id is in the file nspid.9876 in the log subdirectory of the server home directory.

If set to "off", the access logs will not be rolled when a signal is sent.

For example, suppose an AOLserver, called server1, has three virtual servers called vs1, vs2, and vs3. Each of the virtual servers has the nslog module loaded. vs1 and vs2 set the nslog File parameter to "/logs/abc.log", and vs3 doesn't set the nslog File parameter at all. The nslog Address parameter is set to the name of the second AOLserver (server2).

A second AOLserver, called server2, has an nsnlog module loaded for a virtual server called myvs. The nsnlog Port and Address parameters are set to listen for vs1, vs2, and vs3 on server1. The nsnlog Directory parameter is left unset and defaults to "servers/myvs/modules/nsnlog". The port specified in the Port parameter for the nsnlog module for the myvs virtual server must be the same as the port specified in the Port parameter in the nslog modules for the vs1, vs2, and vs3 virtual servers.

The log files created on the server2 machine are:

/logs/abc.log

contains multiplexed logs from vs1 and vs2

servers/myvs/modules/nsnlog/vs3

contains logs for vs3

The nsnlog module creates a new thread for each remote nslog connect request. In the example above, nsnlog would create three new threads and access to the abc.log file would be multiplexed between the log entries sent from vs1 and vs2.

[ns/server/server-name/module/nsperm]

This section configures the nsperm module for a virtual server. There should be one of these sections for each virtual server that includes an nsperm module if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Directory

/servers/server/modules/perm

Directory where access control data files are stored. Each virtual server must have a different permissions directory.

EnableHostnameLookup

on

Boolean value. Select off to turn off DNS lookup of IP addresses into host names. This can increase the performance of the permissions module, but you cannot restrict access based on host name. You will still be able to restrict access based on numeric IP addresses.

Model

Small

Can be either Large or Small. By default, the Small model is chosen and you can pick users and groups from a selection box on the access control forms. Specify a Large model if you have a very large number of users and groups and you would rather type in comma-delimited lists of users and groups than select them from such a large selection box.

UserDir

users

The directory under the server's pageroot where user home directories are located by default.

[ns/server/server-name/module/nsservlet]

This section configures support for the Java Servlet API. See page 131 for complete configuration instructions.

Parameter

Default Value

Description

JavaClassPath

<JavaHome>/classes

An absolute path to java classes directory.

If you provide a directory with ServletClassPath and don't provide a JavaClassPath, the module appends /classes to that directory to make the class path.

JavaHome

/opt/java

An absolute path to home directory for the Java Development Kit (JDK).

NcgiClassPath

<ServletAPIHome> /lib/sun/servlet/apache

An absolute path to the directory that contains the NcgiServletGate class (i.e., NcgiServletGate.class file).

If you provide a directory with ServletAPIHome and don't provide an NcgiClassPath, the module appends /lib/sun/servlet/apache to that directory.

NcgiEnvPath

/opt/java:/opt/java/bin: /opt/jsdk

A colon delimited list of absolute paths to use in the environment variable PATH when <JavaHome>/bin/java needs to be started.

At startup the module attempts to connect to the NCGI server. If a connection is not established, it then attempts to bootstrap the Java Virtual Machine with various arguments to initialize the NCGI server.

NcgiHost

localhost

The hostname that the NCGI server uses to listen for incoming servlet requests from AOLserver.

NcgiPort

31461

The port that the NCGI server uses to listen for remote connect requests on.

NcgiTimeout

300

The timeout value in seconds for connections to the NCGI server and for data transfers.

ServletAPIClassPath

<ServletAPIHome>/lib

An absolute path to the class directory for the Servlet API  classes.

If you provide a directory with ServletAPIHome and don't provide a ServletAPIClassPath, the module appends /lib to  that directory to make the class path.

ServletAPIHome

/opt/jsdk

An absolute path to the home directory for the Java Servlet Development Kit (JSDK).

ServletConfigFile

<server>/modules/nsservlet/ servlet.properties

An absolute path to the servlets configuration file.

ServletHome

<server>/modules/nsservlet

An absolute path to the home directory for the your servlets.

ServletPermsFile

<server>/modules /nsservlet/perms.dat

An absolute path to the servlets permission file.

ServletUrl

/nsservlet

The URL to register for your HTTP requests.

ServletVerbose

Off

Boolean value. Set to on to enable verbose error messages.

Note: Setting ServletVerbose may result in a large amount of output in the server log file.

[ns/server/server-name/module/nssock]

This section configures the nssock module for a virtual server. Each virtual server must have either an nssock module or an nsssl module loaded. There should be one of these sections for each virtual server that includes an nssock module if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Address

IP Address where this virtual server listens for requests. If this parameter is not set, AOLserver will listen on all interfaces. This means that if one virtual server does not set an address, no other virtual server may use the same Port.

Debug

off

Boolean value. Set to on to enable debug message logging.

Hostname

AOLserver queries the DNS (Domain Name Service) for the host name.

Host name used in response to clients. This may be an alias for your site, such as www.avalon.com. Make sure the IP address of the Hostname you set is valid or users will be unable to process redirects from your site.

HttpKeepAliveTimeout

0

If this parameter is set to a value other than 0, a TCP "keep alive" feature is enabled that allows multiple requests to occur with only one TCP connection, which can produce a significant speed increase.

The value of this parameter is number of seconds to wait for a TCP request. If this parameter is set to 0, the "keep alive" feature is disabled.

KeepAlive

on

Boolean. If set to on, the periodic transmission of messages on a connected socket is enabled. If the client fails to respond to these messages, the connection is considered broken. Setting KeepAlive to off may result in several dead connections held open.

ListenBacklog

SOMAXCONN from <sys/socket.h>

Number of outstanding connections to be held by the operating system until AOLserver can accept them. Valid range is 1 to 255. Most Unix systems silently ignore this parameter and always use a backlog of 5.

Location

The URL that redirects come back to. This parameter is useful when the server machine is part of a group of machines responding to requests through a DNS rotor. By default, the server will use http://hostname as the location.

LogBusyRequests

off

Boolean value. If this parameter is set to On, requests to which the server responds with a 503 error (server busy) will be added to the access log. The log entry will look something like this:

    something.aol.com - - 
    [16/Jun/1997:15:01:55 -0400] "BUSY 
/" 503 200

The path that appears in the access log for busy requests will always be "/".

Port

80

Port number where this virtual server listens for requests. If two virtual servers use the same port, they must use different Addresses.

If you are using virtual hosting (see page 127), you can set the Port to 0, which means this virtual server will not listen on any port and can only be accessed through the "master" virtual server.

ReceiveBufferSize

8K

TCP/IP socket receive buffer size.Valid range is 512 to 65535. A higher buffer size may increase performance.

SendBufferSize

8K

TCP/IP socket send buffer size. Valid range is 512 to 65535. A higher buffer size may increase performance.

SendMaxSize

0

The maximum number of bytes to send over the TCP/IP socket. If set to 0 (the default), there is no limit. Setting this to a value other than zero may be helpful if your server is located on a very slow Internet connection.

TcpWrappers

off

Boolean value. Set to On to enable hosts.allow and hosts.deny lookups authentication. For example, if a host isn't allowed with hosts.allow, then the control connection is closed immediately.

About Tcp wrapper functions: The nssock module supports Tcp wrapper functions that authorize clients based on conventional hosts.allow/hosts.deny access control. The TcpWrappers parameter enables this support. The module uses the daemon name (nsd), client IP address, and client hostname to perform the client authorization. To view the documentation for hosts.allow/hosts.deny access control syntax, download the tcp_wrapper package from:

http://wuarchive.wustl.edu/packages/ security/tcp_wrappers

TimeOut

0

The maximum number of seconds to wait on a pending socket recv() or send(). A value of 0 (zero) indicates an infinite wait. Setting TimeOut to a value other than zero may be helpful in quickly detecting dead clients. However, the server must perform additional steps to implement the TimeOut which may reduce performance.

[ns/server/server-name/module/nsssl]

This section configures the SSL module for a virtual server. Each virtual server must have either an nssock module or an nsssl module loaded. There should be one of these sections for each virtual server that includes an SSL module if you want to change any of the default settings for the parameters. Many of these parameters are shared with the nssock module.

Parameter

Default Value

Description

Address

IP Address where this virtual server listens for requests. If this parameter is not set, AOLserver will listen on all interfaces. This means that if one virtual server does not set an address, no other virtual server may use the same Port.

CertFile

The file containing the signed certificate for this virtual server. The certificate contains information about the virtual server and your company that has been confirmed by a trusted third party (a Certification Authority). Note: You can put the private key in the same file if you want to.

Debug

off

Boolean value. Set to on to enable debug message logging.

Hostname

AOLserver queries the DNS (Domain Name Service) for the host name.

Host name used in response to clients. This may be an alias for your site, such as www.avalon.com. Make sure the IP address of the Hostname you set is valid or users will be unable to process redirects from your site.

KeepAlive

on

Boolean. If set to on, the periodic transmission of messages on a connected socket is enabled. If the client fails to respond to these messages, the connection is considered broken.

KeyFile

The full path and filename of the file that contains the virtual server's private key. Note: This parameter defaults to the contents of CertFile.

ListenBacklog

SOMAXCONN from <sys/socket.h>

Number of outstanding connections to be held by the operating system until AOLserver can accept them. Valid range is 1 to 255.

Port

443

Port number where this virtual server listens for requests. If two virtual servers use the same port, they must use different Addresses.

ReceiveBufferSize

32K

TCP/IP socket receive buffer size. Valid range is 512 to 65535.

SendBufferSize

32K

TCP/IP socket send buffer size. Valid range is 512 to 65535.

[ns/server/server-name/module/nstext]

This section configures the full-text module for a virtual server. There should be one of these sections for each virtual server that includes a full-text module if you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Archive

off

Boolean value. Set to on if you want pages archived, allowing you to retrieve deleted versions of pages through the Tools Administer Page Versions AOLpress menu item.

DbPool

pool-name

The name of the pool (see the [ns/db/pools] section) in which to store full-text information for pages. The pool must be a pool which connects to an Illustra database with the Text Datablade installed.

Index

off

Boolean value. Set to on if you want pages indexed. You must set this parameter to on if you want to be able to perform full-text searches on your pages. Then set the Searchable parameter according to whether you want users to be able to perform searches.

Searchable

off

Boolean value. Set to on to allow users to search this virtual server from the AOLpress Search Server menu option. (The nsadmin user will allways be able to search the virtual server from the Administration page if the Index parameter is on.)

[ns/server/server-name/module/tclstate]

This section configures Tcl to maintain state data, stored in a Tcl ns_set structure, across connections and server reboots for a specified amount of time. To enable Tcl to maintain state data, you must also load a Tcl-only module called "tclstate".

Parameter

Default Value

Description

TimeOut

The length of time (in minutes) state data is maintained.

[ns/server/server-name/module/nsvhost]

Specify one line for each virtual server whose content will be hosted by this master virtual server. You must also add the [ns/server/server-name/module/nsvhost/vserver-name] subsection, below, for each virtual server See page 127 for configuration instructions for virtual hosting..

Parameter

Default Value

Description

hostname

server-name

For example, if the virtual server "bar" is going to have its content hosted by this master server, you would specify its hostname like this:

    www.bar.com = bar

Or, if this master server is not listening on port 80, specify the master server's port number too:

    www.bar.com:1850 = bar

[ns/server/server-name/module/nsvhost/vserver-name]

Specify the server name and driver for this virtual server whose content will be hosted by the master virtual server. See page 127 for configuration instructions for virtual hosting..

Parameter

Default Value

Description

Server

server-name

The name of the server whose content will be hosted by the master virtual server.

Driver

nssock

The driver to be used for this virtual server. The driver must be nssock for virtual hosting.

Database Drivers and Pools

[ns/db/drivers]

This section lists the available database drivers to be used with the database pools. The name of the driver can be any name you choose, but it must then be referenced as the driver name in the appropriate [ns/db/driver/driver-name] section. Note that the driver parameter in the [ns/db/pool/pool-name] section must also reference the driver name to associate a database driver with a particular database pool.

The file specified as the usual value for each parameter exists in the bin directory under the AOLserver home directory by default. If it resides somewhere else, include an absolute path specification along with the file.

Parameter

Usual Value

Description

illustra

nsill.so

If present, enables the Illustra database driver. Configure the Illustra driver in the [ns/db/driver/illustra] section.

solid

nssolid.so

If present, enables the SOLID database driver. No configuration is necessary for the SOLID driver.

extname

nsext.so

The external database driver name. There can be multiple (uniquely-named) instances of this parameter, one for each proxy daemon interface. By convention, the external driver names are prepended with "ext". For example: extIll or extSyb.

[ns/db/driver/illustra]

This section configures the Illustra database driver. There should be one of these sections in your configuration file if the Illustra driver is listed in the [ns/db/drivers] section and you want to change any of the default settings for the parameters.

Parameter

Default Value

Description

Asynchronous

on

Boolean. If set to on, AOLserver will run asynchronously with respect to the Illustra libmi calls which can increase performance.

MiParams

MiParams file in the miadmin user's home directory.

The filename of the Illustra MiParams configuration file. It specifies various Illustra startup parameters and is used by AOLserver to locate the Illustra server.

This parameter is overridden by the MI_SYSPARAMS environment variable, and if neither are set, AOLserver will look for an MiParams file in the user miadmin's home directory.

UseAppLicenseKeys

on

Boolean. If set to on, the AOLserver will connect to Illustra as an AOLserver application and request AOLserver license key feature numbers. Set to off to use standard Illustra license keys.

[ns/db/driver/extname]

This section configures an external database driver. There should be one of these sections in your configuration file if an external driver is listed in the [ns/db/drivers] section and you want to change any of the default settings for the parameters

Parameter

Usual Value

Description

LocalDaemon

Illustra: nsillpd

Sybase: nssybpd

The local database proxy daemon.

Use this parameter only for local database proxy daemons.

RemoteHost

A remote host name. Use this parameter only for remote database proxy daemons.

RemotePort

A remote port number. Use this parameter only for remote database proxy daemons.

Param

/usr/local/miadmin/MiParams

For Illustra, the location of the MiParams file. For Sybase, the value of the SYBASE environment variable.

TrimData

off

Boolean value. For Sybase. If set to On, the external driver will trim from the right the data returned by the Sybase server. This parameter is useful when, for example, you don't want all the empty whitespace from a 32-character char or when "empty" varchars are returning a non-empty 2-byte value.

Note that this will probably corrupt image types that are holding binary data in a BLOB (the "text" type in Sybase), so it is recommended that you leave this parameter Off if you're working with BLOBs.

[ns/db/pools]

This section lists (and names) each of the available database pools for AOLserver.

Parameter

Default Value

Description

pool-name

pool description

The name (user-defined) of a database pool, which is actually a collection of connections accessible to AOLserver to the associated database. The database connection itself is configured in the [ns/db/pool/pool-name] section.

The pool description can be any user-specified comments about the pool.

[ns/db/pool/pool-name]

This section configures a database pool. There should be one of these sections for each database pool listed in the [ns/db/pools] section.

Parameter

Default Value

Description

Connections

2

The maximum number of connections that can be established at any one time. The server automatically makes connections as needed up to this maximum number. If additional connections are requested during processing, the requests must wait.

Note: Some databases do not handle multiple connections very well. In this case, you should set Connections to 1 (one).

Datasource

Illustra: default:nsdb

Postgres: host:port:database

Solid: TCP/IP hostname port

For Illustra, the database server and the database name separated by a colon (:). The database server is specified in the Illustra parameters file. Note: The database server is not, in general, the same as the hostname on which the Illustra server runs. In a typical installation with AOLserver and Illustra running on the same host, the server name would be "default".

Driver

Value can be any driver named in the [ns/db/drivers] section: illustra (for Illustra), solid (for SOLID), or an external database driver.

ExtendedTableInfo

off

Boolean value. Set to on to store extended table information in the ns_tables and ns_columns tables in this database pool. If the ns_tables and ns_columns tables do not already exist in this database pool, they will be created.

LogSQLErrors

off

Boolean value. If set to On, SQL errors are written to the server log along with the offending SQL statement(s). If set to Off and Verbose is also Off, SQL errors are not written to the server log.

MaxIdle

600

The maximum length of time in seconds that a database connection within this pool can remain open and idle.

The default setting causes connections that are idle for 10 minutes to be closed. Note that MaxIdle will not have an effect if it is equal to MaxOpen.

Setting MaxIdle to 0 makes it impossible for database handles to become stale, unless the MaxOpen time expires.

MaxOpen

3600

The maximum length of time in seconds that a database connection within this pool can remain open. It is recommended that MaxOpen be a multiple of MaxIdle; otherwise, MaxOpen may be off by as much as (MaxOpen mod MaxIdle).

The default setting causes all connections to be closed after one hour, regardless of activity level. Database pool connections will then be opened again as needed up to the value of the Connections parameter.

Setting MaxOpen to 0 makes it impossible for database handles to become stale when they are not idle.

Password

Password to log into the database.

Note: In the case of Illustra, this is the passsword of the database user as stored in the Illustra "users" system table which is not necessarily the same as the password of the miadmin Unix user.

User

Illustra: miadmin

Username to log into the database.

Note: In the case of Illustra, this is the database username as stored in the Illustra "users" system table, not the user under which Illustra or the AOLserver runs.

Verbose

off

Boolean value. If set to On, all SQL statements executed against this pool are written to the server log. Errors, connects, and disconnects are also logged. If set to Off, SQL statements are not written to the server log.

At no point is the same SQL statement written to the log twice, even if Verbose=On, LogSQLErrors=On, and the statement causes an error.

Note: Setting Verbose may result in a large amount of output in the server log file.

CGI Interpreters and Environment

[ns/interps/interps-name]

This section allows you to configure an interps section that can be used by CGI modules loaded into any of the virtual servers..

Parameter

Default Value

Description

file-extension

program(environment)

A CGI interpreter definition used by a CGI module. The environment is optional and specifies a section of environment variables to set in addition to the CGI variables before executing the interpreter program. For example:

    .pl=c:\perl\bin\perl.exe
    .sh=c:\mks\mksnt\sh.exe(MKSenv)

In this case, Perl will be invoked to interpret CGI scripts which end in .pl; the variables in the [ns/environment/mksenv] section will be set before the MKS Bourne shell is invoked to interpret CGI scripts which end in .sh.

To enable this section to be used by a specific CGI module, use the Interps parameter of the CGI module.

[ns/environment/environment-name]

This section allows you to configure an environment section that can be used by CGI modules loaded into any of the virtual servers..

Parameter

Default Value

Description

variable

definition

An environment variable definition used by a CGI module. To enable this section to be used by a specific CGI module, use the Environment parameter of the CGI module or add the optional environment name in the definition of a CGI interpreter.

SGI IRIX Sproc-Based Threads

[ns/threads]

This section allows you to configure sproc-based threads available on IRIX 5.3 or 6.2 (not the pthreads-based approach available on IRIX 6.2).

Note that these parameters are provided for advanced IRIX users who need to fine-tune their system. They are not accessible through the setup server; you must set them directly in the configuration file.

Parameter

Default Value

Description

ArenaFile

If ArenaSwapFile is on, the default is: /dev/zero

Otherwise, the default is ArenaMktemp

An arena file.

ArenaMktemp

/var/tmp/nsArenaXXXXXX

A temporary file for the arena, used only if ArenaSwapFile is off.

ArenaSwapFile

on

Boolean value. Set to on to use the swap device for the arena.

AutoGrow

on

Boolean value. If set to off, the underlying file of the newly-created arena will be grown to its maximum size (InitSize) before the file is mmap'ed. If set to on, the underlying file of the arena will be mmap'ed with the MAP_AUTOGROW option (see mmap(2)). Note that the default case (on) can cause unexpected failures when the file system fills up.

AutoResv

off

Boolean value. If both AutoGrow and ArenaSwapFile are on, the underlying file of the arena will be mmap'ed with the MAP_AUTORESV option (see mmap(2)).

InitSize

SizePerUser * InitUsers

The arena size in bytes (minimum is 32768).

InitUsers

The maximum of either (10 + the number of virtual servers) or 1500

The maximum number of users for the arena (miminum is 10; maximum is 1500).

SizePerUser

16384

The number of bytes per user.

Top of Page

[ Previous ] [ Contents ] [ Index ] [ Next ]
Copyright © 1996 America Online, Inc.