archive-fr.com » FR » O » OBSPM.FR

Total: 155

Choose link from "Titles, links and description words view":

Or switch to "Titles and links view".
  • The Apache EBCDIC Port - Apache HTTP Server
    text or a binary file Porting Notes The relevant changes in the source are ifdef ed into two categories ifdef CHARSET EBCDIC Code which is needed for any EBCDIC based machine This includes character translations differences in contiguity of the two character sets flags which indicate which part of the HTTP protocol has to be converted and which part doesn t etc ifdef OSD POSIX Code which is needed for the SIEMENS BS2000 OSD mainframe platform only This deals with include file differences and socket implementation topics which are only required on the BS2000 OSD platform The possibility to translate between ASCII and EBCDIC at the socket level on BS2000 POSIX there is a socket option which supports this was intentionally not chosen because the byte stream at the HTTP protocol level consists of a mixture of protocol related strings and non protocol related raw file data HTTP protocol strings are always encoded in ASCII the GET request any Header lines the chunking information etc whereas the file transfer parts i e GIF images CGI output etc should usually be just passed through by the server This separation between protocol string and raw data is reflected in the server code by functions like bgets or rvputs for strings and functions like bwrite for binary data A global translation of everything would therefore be inadequate In the case of text files of course provisions must be made so that EBCDIC documents are always served in ASCII This port therefore features a built in protocol level conversion for the server internal strings which the compiler translated to EBCDIC strings and thus for all server generated documents The hard coded ASCII escapes 012 and 015 which are ubiquitous in the server code are an exception they are already the binary encoding of the ASCII n and r and must not be converted to ASCII a second time This exception is only relevant for server generated strings and external EBCDIC documents are not expected to contain ASCII newline characters By examining the call hierarchy for the BUFF management routines I added an ebcdic ascii conversion layer which would be crossed on every puts write get gets and a conversion flag which allowed enabling disabling the conversions on the fly Usually a document crosses this layer twice from its origin source a file or CGI output to its destination the requesting client file Apache and Apache client The server can now read the header lines of a CGI script output in EBCDIC format and then find out that the remainder of the script s output is in ASCII like in the case of the output of a WWW Counter program the document body contains a GIF image All header processing is done in the native EBCDIC format the server then determines based on the type of document being served whether the document body except for the chunking information of course is in ASCII already or must be converted from EBCDIC For Text documents MIME types

    Original URL path: http://ama09.obspm.fr/manual-2.0/platform/ebcdic.html (2015-11-16)
    Open archived version from archive


  • Developer Documentation for Apache 2.0 - Apache HTTP Server
    patient and point out any discrepancies or errors on the developer pages directly to the dev httpd apache org mailing list Topics External Resources Topics Apache 1 3 API Notes Apache 2 0 Hook Functions Request Processing in Apache 2 0 How filters work in Apache 2 0 Converting Modules from Apache 1 3 to Apache 2 0 Debugging Memory Allocation in APR Documenting Apache 2 0 Apache 2 0

    Original URL path: http://ama09.obspm.fr/manual-2.0/developer/ (2015-11-16)
    Open archived version from archive

  • Apache Miscellaneous Documentation - Apache HTTP Server
    HTTP Server Some of the information may still be relevant but please use it with care How to use XSSI and Negotiation for custom ErrorDocuments Describes a solution which uses XSSI and negotiation to custom tailor the Apache ErrorDocuments to taste adding the advantage of returning internationalized versions of the error messages depending on the client s language preferences File Descriptor use in Apache Describes how Apache uses file descriptors and talks about various limits imposed on the number of descriptors available by various operating systems FIN WAIT 2 A description of the causes of Apache processes going into the FIN WAIT 2 state and what you can do about it Known Client Problems A list of problems in HTTP clients which can be mitigated by Apache Performance Notes Apache Tuning Notes about how to run time and compile time configure Apache for highest performance Notes explaining why Apache does some things and why it doesn t do other things which make it slower faster Security Tips Some do s and don t s for keeping your Apache web site secure URL Rewriting Guide This document supplements the mod rewrite reference documentation It describes how one can use Apache s

    Original URL path: http://ama09.obspm.fr/manual-2.0/misc/ (2015-11-16)
    Open archived version from archive

  • core - Apache HTTP Server
    with a slash for local URLs or be a full URL which the client can resolve Alternatively a message can be provided to be displayed by the browser Examples ErrorDocument 500 http foo example com cgi bin tester ErrorDocument 404 cgi bin bad urls pl ErrorDocument 401 subscription info html ErrorDocument 403 Sorry can t allow you access today Note that when you specify an ErrorDocument that points to a remote URL ie anything with a method such as http in front of it Apache will send a redirect to the client to tell it where to find the document even if the document ends up being on the same server This has several implications the most important being that the client will not receive the original error status code but instead will receive a redirect status code This in turn can confuse web robots and other clients which try to determine if a URL is valid using the status code In addition if you use a remote URL in an ErrorDocument 401 the client will not know to prompt the user for a password since it will not receive the 401 status code Therefore if you use an ErrorDocument 401 directive then it must refer to a local document Microsoft Internet Explorer MSIE will by default ignore server generated error messages when they are too small and substitute its own friendly error messages The size threshold varies depending on the type of error but in general if you make your error document greater than 512 bytes then MSIE will show the server generated error rather than masking it More information is available in Microsoft Knowledgebase article Q294807 Prior to version 2 0 messages were indicated by prefixing them with a single unmatched double quote character See also documentation of customizable responses ErrorLog Directive Description Location where the server will log errors Syntax ErrorLog file path syslog facility Default ErrorLog logs error log Unix ErrorLog logs error log Windows and OS 2 Context server config virtual host Status Core Module core The ErrorLog directive sets the name of the file to which the server will log any errors it encounters If the file path is not absolute in general does not begin with a slash then it is assumed to be relative to the ServerRoot Example ErrorLog var log httpd error log If the file path begins with a pipe then it is assumed to be a command to spawn to handle the error log Example ErrorLog usr local bin httpd errors Using syslog instead of a filename enables logging via syslogd 8 if the system supports it The default is to use syslog facility local7 but you can override this by using the syslog facility syntax where facility can be one of the names usually documented in syslog 1 Example ErrorLog syslog user SECURITY See the security tips document for details on why your security could be compromised if the directory where logfiles are stored is writable by anyone other than the user that starts the server Note When entering a file path on non Unix platforms care should be taken to make sure that only forward slashed are used even though the platform may allow the use of back slashes In general it is a good idea to always use forward slashes throughout the configuration files See also LogLevel Apache Log Files FileETag Directive Description File attributes used to create the ETag HTTP response header Syntax FileETag component Default FileETag INode MTime Size Context server config virtual host directory htaccess Override FileInfo Status Core Module core The FileETag directive configures the file attributes that are used to create the ETag entity tag response header field when the document is based on a file The ETag value is used in cache management to save network bandwidth In Apache 1 3 22 and earlier the ETag value was always formed from the file s inode size and last modified time mtime The FileETag directive allows you to choose which of these if any should be used The recognized keywords are INode The file s i node number will be included in the calculation MTime The date and time the file was last modified will be included Size The number of bytes in the file will be included All All available fields will be used This is equivalent to FileETag INode MTime Size None If a document is file based no ETag field will be included in the response The INode MTime and Size keywords may be prefixed with either or which allow changes to be made to the default setting inherited from a broader scope Any keyword appearing without such a prefix immediately and completely cancels the inherited setting If a directory s configuration includes FileETag INode MTime Size and a subdirectory s includes FileETag INode the setting for that subdirectory which will be inherited by any sub subdirectories that don t override it will be equivalent to FileETag MTime Size Files Directive Description Contains directives that apply to matched filenames Syntax Files filename Files Context server config virtual host directory htaccess Override All Status Core Module core The Files directive limits the scope of the enclosed directives by filename It is comparable to the Directory and Location directives It should be matched with a Files directive The directives given within this section will be applied to any object with a basename last component of filename matching the specified filename Files sections are processed in the order they appear in the configuration file after the Directory sections and htaccess files are read but before Location sections Note that Files can be nested inside Directory sections to restrict the portion of the filesystem they apply to The filename argument should include a filename or a wild card string where matches any single character and matches any sequences of characters Extended regular expressions can also be used with the addition of the character For example Files gif jpe g png would match most common Internet graphics formats FilesMatch is preferred however Note that unlike Directory and Location sections Files sections can be used inside htaccess files This allows users to control access to their own files at a file by file level See also How Directory Location and Files sections work for an explanation of how these different sections are combined when a request is received FilesMatch Directive Description Contains directives that apply to regular expression matched filenames Syntax FilesMatch regex FilesMatch Context server config virtual host directory htaccess Override All Status Core Module core The FilesMatch directive limits the scope of the enclosed directives by filename just as the Files directive does However it accepts a regular expression For example FilesMatch gif jpe g png would match most common Internet graphics formats See also How Directory Location and Files sections work for an explanation of how these different sections are combined when a request is received ForceType Directive Description Forces all matching files to be served with the specified MIME content type Syntax ForceType MIME type None Context directory htaccess Override FileInfo Status Core Module core Compatibility Moved to the core in Apache 2 0 When placed into an htaccess file or a Directory or Location or Files section this directive forces all matching files to be served with the content type identification given by MIME type For example if you had a directory full of GIF files but did not want to label them all with png you might want to use ForceType image gif Note that unlike DefaultType this directive overrides all mime type associations including filename extensions that might identify the media type You can override any ForceType setting by using the value of None force all files to be image gif Location images ForceType image gif Location but normal mime type associations here Location images mixed ForceType None Location HostnameLookups Directive Description Enables DNS lookups on client IP addresses Syntax HostnameLookups On Off Double Default HostnameLookups Off Context server config virtual host directory Status Core Module core This directive enables DNS lookups so that host names can be logged and passed to CGIs SSIs in REMOTE HOST The value Double refers to doing double reverse DNS lookup That is after a reverse lookup is performed a forward lookup is then performed on that result At least one of the ip addresses in the forward lookup must match the original address In tcpwrappers terminology this is called PARANOID Regardless of the setting when mod access is used for controlling access by hostname a double reverse lookup will be performed This is necessary for security Note that the result of this double reverse isn t generally available unless you set HostnameLookups Double For example if only HostnameLookups On and a request is made to an object that is protected by hostname restrictions regardless of whether the double reverse fails or not CGIs will still be passed the single reverse result in REMOTE HOST The default is Off in order to save the network traffic for those sites that don t truly need the reverse lookups done It is also better for the end users because they don t have to suffer the extra latency that a lookup entails Heavily loaded sites should leave this directive Off since DNS lookups can take considerable amounts of time The utility logresolve compiled by default to the bin subdirectory of your installation directory can be used to look up host names from logged IP addresses offline IdentityCheck Directive Description Enables logging of the RFC1413 identity of the remote user Syntax IdentityCheck On Off Default IdentityCheck Off Context server config virtual host directory Status Core Module core This directive enables RFC1413 compliant logging of the remote user name for each connection where the client machine runs identd or something similar This information is logged in the access log The information should not be trusted in any way except for rudimentary usage tracking Note that this can cause serious latency problems accessing your server since every request requires one of these lookups to be performed When firewalls are involved each lookup might possibly fail and add 30 seconds of latency to each hit So in general this is not very useful on public servers accessible from the Internet IfDefine Directive Description Encloses directives that will be processed only if a test is true at startup Syntax IfDefine parameter name IfDefine Context server config virtual host directory htaccess Override All Status Core Module core The IfDefine test IfDefine section is used to mark directives that are conditional The directives within an IfDefine section are only processed if the test is true If test is false everything between the start and end markers is ignored The test in the IfDefine section directive can be one of two forms parameter name parameter name In the former case the directives between the start and end markers are only processed if the parameter named parameter name is defined The second format reverses the test and only processes the directives if parameter name is not defined The parameter name argument is a define as given on the httpd command line via D parameter at the time the server was started IfDefine sections are nest able which can be used to implement simple multiple parameter tests Example httpd DReverseProxy httpd conf IfDefine ReverseProxy LoadModule rewrite module modules mod rewrite so LoadModule proxy module modules libproxy so IfDefine IfModule Directive Description Encloses directives that are processed conditional on the presence or absence of a specific module Syntax IfModule module name IfModule Context server config virtual host directory htaccess Override All Status Core Module core The IfModule test IfModule section is used to mark directives that are conditional on the presence of a specific module The directives within an IfModule section are only processed if the test is true If test is false everything between the start and end markers is ignored The test in the IfModule section directive can be one of two forms module name module name In the former case the directives between the start and end markers are only processed if the module named module name is included in Apache either compiled in or dynamically loaded using LoadModule The second format reverses the test and only processes the directives if module name is not included The module name argument is the file name of the module at the time it was compiled For example mod rewrite c If a module consists of several source files use the name of the file containing the string STANDARD20 MODULE STUFF IfModule sections are nest able which can be used to implement simple multiple module tests This section should only be used if you need to have one configuration file that works whether or not a specific module is available In normal operation directives need not be placed in IfModule sections Include Directive Description Includes other configuration files from within the server configuration files Syntax Include file path directory path Context server config virtual host directory Status Core Module core Compatibility Wildcard matching available in 2 0 41 and later This directive allows inclusion of other configuration files from within the server configuration files Shell style fnmatch wildcard characters can be used to include several files at once in alphabetical order In addition if Include points to a directory rather than a file Apache will read all files in that directory and any subdirectory But including entire directories is not recommended because it is easy to accidentally leave temporary files in a directory that can cause httpd to fail The file path specified may be an absolute path i e starting with a slash or may be relative to the ServerRoot directory Examples Include usr local apache2 conf ssl conf Include usr local apache2 conf vhosts conf Or providing paths relative to your ServerRoot directory Include conf ssl conf Include conf vhosts conf Running apachectl configtest will give you a list of the files that are being processed during the configuration check root host apachectl configtest Processing config file usr local apache2 conf ssl conf Processing config file usr local apache2 conf vhosts vhost1 conf Processing config file usr local apache2 conf vhosts vhost2 conf Syntax OK See also apachectl KeepAlive Directive Description Enables HTTP persistent connections Syntax KeepAlive On Off Default KeepAlive On Context server config virtual host Status Core Module core The Keep Alive extension to HTTP 1 0 and the persistent connection feature of HTTP 1 1 provide long lived HTTP sessions which allow multiple requests to be sent over the same TCP connection In some cases this has been shown to result in an almost 50 speedup in latency times for HTML documents with many images To enable Keep Alive connections set KeepAlive On For HTTP 1 0 clients Keep Alive connections will only be used if they are specifically requested by a client In addition a Keep Alive connection with an HTTP 1 0 client can only be used when the length of the content is known in advance This implies that dynamic content such as CGI output SSI pages and server generated directory listings will generally not use Keep Alive connections to HTTP 1 0 clients For HTTP 1 1 clients persistent connections are the default unless otherwise specified If the client requests it chunked encoding will be used in order to send content of unknown length over persistent connections See also MaxKeepAliveRequests KeepAliveTimeout Directive Description Amount of time the server will wait for subsequent requests on a persistent connection Syntax KeepAliveTimeout seconds Default KeepAliveTimeout 15 Context server config virtual host Status Core Module core The number of seconds Apache will wait for a subsequent request before closing the connection Once a request has been received the timeout value specified by the Timeout directive applies Setting KeepAliveTimeout to a high value may cause performance problems in heavily loaded servers The higher the timeout the more server processes will be kept occupied waiting on connections with idle clients Limit Directive Description Restrict enclosed access controls to only certain HTTP methods Syntax Limit method method Limit Context server config virtual host directory htaccess Override All Status Core Module core Access controls are normally effective for all access methods and this is the usual desired behavior In the general case access control directives should not be placed within a Limit section The purpose of the Limit directive is to restrict the effect of the access controls to the nominated HTTP methods For all other methods the access restrictions that are enclosed in the Limit bracket will have no effect The following example applies the access control only to the methods POST PUT and DELETE leaving all other methods unprotected Limit POST PUT DELETE Require valid user Limit The method names listed can be one or more of GET POST PUT DELETE CONNECT OPTIONS PATCH PROPFIND PROPPATCH MKCOL COPY MOVE LOCK and UNLOCK The method name is case sensitive If GET is used it will also restrict HEAD requests The TRACE method cannot be limited A LimitExcept section should always be used in preference to a Limit section when restricting access since a LimitExcept section provides protection against arbitrary methods LimitExcept Directive Description Restrict access controls to all HTTP methods except the named ones Syntax LimitExcept method method LimitExcept Context server config virtual host directory htaccess Override All Status Core Module core LimitExcept and LimitExcept are used to enclose a group of access control directives which will then apply to any HTTP access method not listed in the arguments i e it is the opposite of a Limit section and can be used to control both standard and nonstandard unrecognized methods See the documentation for Limit for more details For example LimitExcept POST GET Require valid user LimitExcept LimitInternalRecursion Directive Description Determine maximum number of internal redirects and nested subrequests Syntax LimitInternalRecursion number number Default LimitInternalRecursion 10 Context server config virtual host Status Core Module core Compatibility Available in Apache 2 0 47 and later An internal redirect happens for example when using the Action directive which internally redirects the original request to a CGI script A subrequest is Apache s mechanism to find out what would happen for some URI if it were requested For example mod dir uses subrequests to look for the files listed in the DirectoryIndex directive LimitInternalRecursion prevents the server from crashing when entering an infinite loop of internal redirects or subrequests Such loops are usually caused by misconfigurations The directive stores two different limits which are evaluated on per request basis The first number is the maximum number of internal redirects that may follow each other The second number determines how deep subrequests may be nested If you specify only one number it will be assigned to both limits Example LimitInternalRecursion 5 LimitRequestBody Directive Description Restricts the total size of the HTTP request body sent from the client Syntax LimitRequestBody bytes Default LimitRequestBody 0 Context server config virtual host directory htaccess Override All Status Core Module core This directive specifies the number of bytes from 0 meaning unlimited to 2147483647 2GB that are allowed in a request body The LimitRequestBody directive allows the user to set a limit on the allowed size of an HTTP request message body within the context in which the directive is given server per directory per file or per location If the client request exceeds that limit the server will return an error response instead of servicing the request The size of a normal request message body will vary greatly depending on the nature of the resource and the methods allowed on that resource CGI scripts typically use the message body for retrieving form information Implementations of the PUT method will require a value at least as large as any representation that the server wishes to accept for that resource This directive gives the server administrator greater control over abnormal client request behavior which may be useful for avoiding some forms of denial of service attacks If for example you are permitting file upload to a particular location and wish to limit the size of the uploaded file to 100K you might use the following directive LimitRequestBody 102400 LimitRequestFields Directive Description Limits the number of HTTP request header fields that will be accepted from the client Syntax LimitRequestFields number Default LimitRequestFields 100 Context server config Status Core Module core Number is an integer from 0 meaning unlimited to 32767 The default value is defined by the compile time constant DEFAULT LIMIT REQUEST FIELDS 100 as distributed The LimitRequestFields directive allows the server administrator to modify the limit on the number of request header fields allowed in an HTTP request A server needs this value to be larger than the number of fields that a normal client request might include The number of request header fields used by a client rarely exceeds 20 but this may vary among different client implementations often depending upon the extent to which a user has configured their browser to support detailed content negotiation Optional HTTP extensions are often expressed using request header fields This directive gives the server administrator greater control over abnormal client request behavior which may be useful for avoiding some forms of denial of service attacks The value should be increased if normal clients see an error response from the server that indicates too many fields were sent in the request For example LimitRequestFields 50 LimitRequestFieldSize Directive Description Limits the size of the HTTP request header allowed from the client Syntax LimitRequestFieldsize bytes Default LimitRequestFieldsize 8190 Context server config Status Core Module core This directive specifies the number of bytes from 0 to the value of the compile time constant DEFAULT LIMIT REQUEST FIELDSIZE 8190 as distributed that will be allowed in an HTTP request header The LimitRequestFieldSize directive allows the server administrator to reduce the limit on the allowed size of an HTTP request header field below the normal input buffer size compiled with the server A server needs this value to be large enough to hold any one header field from a normal client request The size of a normal request header field will vary greatly among different client implementations often depending upon the extent to which a user has configured their browser to support detailed content negotiation This directive gives the server administrator greater control over abnormal client request behavior which may be useful for avoiding some forms of denial of service attacks For example LimitRequestFieldSize 4094 Under normal conditions the value should not be changed from the default LimitRequestLine Directive Description Limit the size of the HTTP request line that will be accepted from the client Syntax LimitRequestLine bytes Default LimitRequestLine 8190 Context server config Status Core Module core This directive sets the number of bytes from 0 to the value of the compile time constant DEFAULT LIMIT REQUEST LINE 8190 as distributed that will be allowed on the HTTP request line The LimitRequestLine directive allows the server administrator to reduce the limit on the allowed size of a client s HTTP request line below the normal input buffer size compiled with the server Since the request line consists of the HTTP method URI and protocol version the LimitRequestLine directive places a restriction on the length of a request URI allowed for a request on the server A server needs this value to be large enough to hold any of its resource names including any information that might be passed in the query part of a GET request This directive gives the server administrator greater control over abnormal client request behavior which may be useful for avoiding some forms of denial of service attacks For example LimitRequestLine 4094 Under normal conditions the value should not be changed from the default LimitXMLRequestBody Directive Description Limits the size of an XML based request body Syntax LimitXMLRequestBody bytes Default LimitXMLRequestBody 1000000 Context server config virtual host directory htaccess Override All Status Core Module core Limit in bytes on maximum size of an XML based request body A value of 0 will disable any checking Example LimitXMLRequestBody 0 Location Directive Description Applies the enclosed directives only to matching URLs Syntax Location URL path URL Location Context server config virtual host Status Core Module core The Location directive limits the scope of the enclosed directives by URL It is similar to the Directory directive and starts a subsection which is terminated with a Location directive Location sections are processed in the order they appear in the configuration file after the Directory sections and htaccess files are read and after the Files sections Location sections operate completely outside the filesystem This has several consequences Most importantly Location directives should not be used to control access to filesystem locations Since several different URLs may map to the same filesystem location such access controls may by circumvented When to use Location Use Location to apply directives to content that lives outside the filesystem For content that lives in the filesystem use Directory and Files An exception is Location which is an easy way to apply a configuration to the entire server For all origin non proxy requests the URL to be matched is a URL path of the form path No scheme hostname port or query string may be included For proxy requests the URL to be matched is of the form scheme servername path and you must include the prefix The URL may use wildcards In a wild card string matches any single character and matches any sequences of characters Extended regular expressions can also be used with the addition of the character For example Location extra special data would match URLs that contained the substring extra data or special data The directive LocationMatch behaves identical to the regex version of Location The Location functionality is especially useful when combined with the SetHandler directive For example to enable status requests but allow them only from browsers at foo com you might use Location status SetHandler server status Order Deny Allow Deny from all Allow from foo com Location Note about slash The slash character has special meaning depending on where in a URL it appears People may be used to its behavior in the filesystem where multiple adjacent slashes are frequently collapsed to a single slash i e home foo is the same as home foo In URL space this is not necessarily true The LocationMatch directive and the regex version of Location require you to explicitly specify multiple slashes if that is your intention For example LocationMatch abc would match the request URL abc but not the request URL abc The non regex Location directive behaves similarly when used for proxy requests But when non regex Location is used for non proxy requests it will implicitly match multiple slashes with a single slash For example if you specify Location abc def and the request is to abc def then it will match See also How Directory Location and Files sections work for an explanation of how these different sections are combined when a request is received LocationMatch Directive Description Applies the enclosed directives only to regular expression matching URLs Syntax LocationMatch regex LocationMatch Context server config virtual host Status Core Module core The LocationMatch directive limits the scope of the enclosed directives by URL in an identical manner to Location However it takes a regular expression as an argument instead of a simple string For example LocationMatch extra special data would match URLs that contained the substring extra data or special data See also How Directory Location and Files sections work for an explanation of how these different sections are combined when a request is received LogLevel Directive Description Controls the verbosity of the ErrorLog Syntax LogLevel level Default LogLevel warn Context server config virtual host Status Core Module core LogLevel adjusts the verbosity of the messages recorded in the error logs see ErrorLog directive The following level s are available in order of decreasing significance Level Description Example emerg Emergencies system is unusable Child cannot open lock file Exiting alert Action must be taken immediately getpwuid couldn t determine user name from uid crit Critical Conditions socket Failed to get a socket exiting child error Error conditions Premature end of script headers warn Warning conditions child process 1234 did not exit sending another SIGHUP notice Normal but significant condition httpd caught SIGBUS attempting to dump core in info Informational Server seems busy you may need to increase StartServers or Min MaxSpareServers debug Debug level messages Opening config file When a particular level is specified messages from all other levels of higher significance will be reported as well E g when LogLevel info is specified then messages with log levels of notice and warn will also be posted Using a level of at least crit is recommended For example LogLevel notice Note When logging to a regular file messages of the level notice cannot be suppressed and thus are always logged However this doesn t apply when logging is done using syslog MaxKeepAliveRequests Directive Description Number of requests allowed on a persistent connection Syntax MaxKeepAliveRequests number Default MaxKeepAliveRequests 100 Context server config virtual host Status Core Module core The MaxKeepAliveRequests directive limits the number of requests allowed per connection when KeepAlive is on If it is set to 0 unlimited requests will be allowed We recommend that this setting be kept to a high value for maximum server performance For example MaxKeepAliveRequests 500 NameVirtualHost Directive Description Designates an IP address for name virtual hosting Syntax NameVirtualHost addr port Context server config Status Core Module core The NameVirtualHost directive is a required directive if you want to configure name based virtual hosts Although addr can be hostname it is recommended that you always use an IP address e g NameVirtualHost 111 22 33 44 With the NameVirtualHost directive you specify the IP address on which the server will receive requests for the name based virtual hosts This will usually be the address to which your name based virtual host names resolve In cases where a firewall or other proxy receives the requests and forwards them on a different IP address to the server you must specify the IP address of the physical interface on the machine which will be servicing the requests If you have multiple name based hosts on multiple addresses repeat the directive for each address Note Note that the main server and any default servers will never be served for a request to a NameVirtualHost IP Address unless for some reason you specify NameVirtualHost but then don t define any VirtualHost s for that address Optionally you can specify a port number on which the name based virtual hosts should be used e g NameVirtualHost 111 22 33 44 8080 IPv6 addresses must be enclosed in square brackets as shown in the following example NameVirtualHost fe80 a00 20ff fea7 ccea 8080 To receive requests on all interfaces you can use an argument of NameVirtualHost Argument to VirtualHost directive Note that the argument to the VirtualHost directive must exactly match the argument to the NameVirtualHost directive NameVirtualHost 1 2 3 4 VirtualHost 1 2 3 4 VirtualHost See also Virtual Hosts documentation Options Directive Description Configures what features are available in a particular directory Syntax Options option option Default Options All Context server config virtual host directory htaccess Override Options Status Core Module core The Options directive controls which server features are available in a particular directory option can be set to None in which case none of the extra features are enabled or one or more of the following All All options except for MultiViews This is the default setting ExecCGI Execution of CGI scripts using mod cgi is permitted FollowSymLinks The server will follow symbolic links in this directory Even though the server follows the symlink it does not change the pathname used to match against Directory sections Note also that this option gets ignored if set inside a Location section Includes Server side includes provided by mod include are permitted IncludesNOEXEC Server side includes are permitted but the exec cmd and exec cgi are disabled It is still possible to include virtual CGI scripts from ScriptAlias ed directories Indexes If a URL which maps to a directory is requested and there is no DirectoryIndex e g index html in that directory then mod autoindex will return a formatted listing of the directory MultiViews Content negotiated MultiViews are allowed using mod negotiation SymLinksIfOwnerMatch The server will only follow symbolic links for which the target file or directory is owned by the same user id as the link Note This option gets ignored if set inside a Location section Normally if multiple Options could apply to a directory then the most specific one is used and others are ignored the options are not merged See how sections are merged However if all the options on the Options directive are preceded by a or symbol the options are merged Any options preceded by a are added to the options currently in force and any options preceded by a are removed from the options currently in force For example without any and symbols Directory web docs Options Indexes FollowSymLinks Directory Directory web docs spec Options Includes Directory then only Includes will be set for the web docs spec directory However if the second Options directive uses the and symbols Directory web docs Options Indexes FollowSymLinks Directory Directory web docs spec Options Includes Indexes Directory then the options FollowSymLinks and Includes are set for the web docs spec directory Note Using IncludesNOEXEC or Includes disables server side includes completely regardless of the previous setting The default in the absence of any other settings is All Require Directive Description Selects which authenticated users can access a resource Syntax Require entity name entity name Context directory htaccess Override AuthConfig Status Core Module core This directive selects which authenticated users can access a directory The allowed syntaxes are Require user userid userid Only the named users can access the resource Require group group name group name Only users in the named groups can access the resource Require valid user All valid users can access the resource Require must be accompanied by AuthName and AuthType directives and directives such as AuthUserFile and AuthGroupFile to define users and groups in order to work correctly Example AuthType Basic AuthName Restricted Directory AuthUserFile web users AuthGroupFile web groups Require group admin Access controls which are applied in this way are effective for all methods This is what is normally desired If you wish to apply access controls only to specific methods while leaving other methods unprotected then place the Require statement into a Limit section See also Satisfy mod access RLimitCPU Directive Description Limits the CPU consumption of processes launched by Apache children Syntax RLimitCPU seconds max seconds max Default Unset uses operating system defaults Context server config virtual host directory htaccess Override All Status Core Module core Takes 1 or 2 parameters The first parameter sets the soft resource limit for all processes and the second parameter sets the maximum resource limit Either parameter can be a number or max to indicate to the server that the limit should be set to the maximum allowed by the operating system configuration Raising the maximum resource limit requires that the server is running as root or in the initial startup phase This applies to processes forked off from Apache children servicing requests not the Apache children themselves This includes CGI scripts and SSI exec commands but not any processes forked off from the Apache parent such as piped logs CPU resource limits are expressed in seconds per process See also RLimitMEM RLimitNPROC RLimitMEM Directive Description Limits the memory consumption of processes launched by Apache children Syntax RLimitMEM bytes max bytes max Default Unset uses operating system defaults Context server config virtual host directory htaccess Override All Status Core Module core Takes 1 or 2 parameters The first parameter sets the soft resource limit for

    Original URL path: http://ama09.obspm.fr/manual-2.0/mod/core.html (2015-11-16)
    Open archived version from archive

  • mpm_common - Apache HTTP Server
    end of a different request the connection will then be serviced For non threaded servers i e prefork MaxClients translates into the maximum number of child processes that will be launched to serve requests The default value is 256 to increase it you must also raise ServerLimit For threaded and hybrid servers e g beos or worker MaxClients restricts the total number of threads that will be available to serve clients The default value for beos is 50 For hybrid MPMs the default value is 16 ServerLimit multiplied by the value of 25 ThreadsPerChild Therefore to increase MaxClients to a value that requires more than 16 processes you must also raise ServerLimit MaxMemFree Directive Description Maximum amount of memory that the main allocator is allowed to hold without calling free Syntax MaxMemFree KBytes Default MaxMemFree 0 Context server config Status MPM Module beos leader mpm netware prefork threadpool worker The MaxMemFree directive sets the maximum number of free Kbytes that the main allocator is allowed to hold without calling free When not set or when set to zero the threshold will be set to unlimited MaxRequestsPerChild Directive Description Limit on the number of requests that an individual child server will handle during its life Syntax MaxRequestsPerChild number Default MaxRequestsPerChild 10000 Context server config Status MPM Module leader mpm netware mpm winnt mpmt os2 perchild prefork threadpool worker The MaxRequestsPerChild directive sets the limit on the number of requests that an individual child server process will handle After MaxRequestsPerChild requests the child process will die If MaxRequestsPerChild is 0 then the process will never expire Different default values The default value for mpm netware and mpm winnt is 0 Setting MaxRequestsPerChild to a non zero limit has two beneficial effects it limits the amount of memory that process can consume by accidental memory leakage by giving processes a finite lifetime it helps reduce the number of processes when the server load reduces Note For KeepAlive requests only the first request is counted towards this limit In effect it changes the behavior to limit the number of connections per child MaxSpareThreads Directive Description Maximum number of idle threads Syntax MaxSpareThreads number Default See usage for details Context server config Status MPM Module beos leader mpm netware mpmt os2 perchild threadpool worker Maximum number of idle threads Different MPMs deal with this directive differently For perchild the default is MaxSpareThreads 10 This MPM monitors the number of idle threads on a per child basis If there are too many idle threads in that child the server will begin to kill threads within that child For worker leader and threadpool the default is MaxSpareThreads 250 These MPMs deal with idle threads on a server wide basis If there are too many idle threads in the server then child processes are killed until the number of idle threads is less than this number For mpm netware the default is MaxSpareThreads 100 Since this MPM runs a single process the spare thread count is also server wide beos and mpmt os2 work similar to mpm netware The default for beos is MaxSpareThreads 50 For mpmt os2 the default value is 10 Restrictions The range of the MaxSpareThreads value is restricted Apache will correct the given value automatically according to the following rules perchild requires MaxSpareThreads to be less or equal than ThreadLimit mpm netware wants the value to be greater than MinSpareThreads For leader threadpool and worker the value must be greater or equal than the sum of MinSpareThreads and ThreadsPerChild See also MinSpareThreads StartServers MinSpareThreads Directive Description Minimum number of idle threads available to handle request spikes Syntax MinSpareThreads number Default See usage for details Context server config Status MPM Module beos leader mpm netware mpmt os2 perchild threadpool worker Minimum number of idle threads to handle request spikes Different MPMs deal with this directive differently perchild uses a default of MinSpareThreads 5 and monitors the number of idle threads on a per child basis If there aren t enough idle threads in that child the server will begin to create new threads within that child Thus if you set NumServers to 10 and a MinSpareThreads value of 5 you ll have at least 50 idle threads on your system worker leader and threadpool use a default of MinSpareThreads 75 and deal with idle threads on a server wide basis If there aren t enough idle threads in the server then child processes are created until the number of idle threads is greater than number mpm netware uses a default of MinSpareThreads 10 and since it is a single process MPM tracks this on a server wide bases beos and mpmt os2 work similar to mpm netware The default for beos is MinSpareThreads 1 For mpmt os2 the default value is 5 See also MaxSpareThreads StartServers PidFile Directive Description File where the server records the process ID of the daemon Syntax PidFile filename Default PidFile logs httpd pid Context server config Status MPM Module beos leader mpm winnt mpmt os2 perchild prefork threadpool worker The PidFile directive sets the file to which the server records the process id of the daemon If the filename is not absolute then it is assumed to be relative to the ServerRoot Example PidFile var run apache pid It is often useful to be able to send the server a signal so that it closes and then re opens its ErrorLog and TransferLog and re reads its configuration files This is done by sending a SIGHUP kill 1 signal to the process id listed in the PidFile The PidFile is subject to the same warnings about log file placement and security Note As of Apache 2 it is recommended to use only the apachectl script for re starting or stopping the server ScoreBoardFile Directive Description Location of the file used to store coordination data for the child processes Syntax ScoreBoardFile file path Default ScoreBoardFile logs apache status Context server config Status MPM Module beos leader mpm winnt perchild prefork threadpool

    Original URL path: http://ama09.obspm.fr/manual-2.0/mod/mpm_common.html (2015-11-16)
    Open archived version from archive

  • beos - Apache HTTP Server
    and ports Apache uses MaxRequestsPerThread Directive Description Limit on the number of requests that an individual thread will handle during its life Syntax MaxRequestsPerThread number Default MaxRequestsPerThread 0 Context server config Status MPM Module beos The MaxRequestsPerThread directive sets the limit on the number of requests that an individual server thread will handle After MaxRequestsPerThread requests the thread will die If MaxRequestsPerThread is 0 then the thread will never expire

    Original URL path: http://ama09.obspm.fr/manual-2.0/mod/beos.html (2015-11-16)
    Open archived version from archive

  • leader - Apache HTTP Server
    to coordinate work among threads For more info see http deuce doc wustl edu doc pspdfs lf pdf To use the leader MPM add with mpm leader to the configure script s arguments when building the httpd This MPM depends on APR s atomic compare and swap operations for thread synchronization If you are compiling for an x86 target and you don t need to support 386s or you are

    Original URL path: http://ama09.obspm.fr/manual-2.0/mod/leader.html (2015-11-16)
    Open archived version from archive

  • worker - Apache HTTP Server
    each child process and MaxClients which controls the maximum total number of threads that may be launched Directives AcceptMutex CoreDumpDirectory Group Listen ListenBacklog LockFile MaxClients MaxMemFree MaxRequestsPerChild MaxSpareThreads MinSpareThreads PidFile ScoreBoardFile SendBufferSize ServerLimit StartServers ThreadLimit ThreadsPerChild User Topics How it Works See also Setting which addresses and ports Apache uses How it Works Each process has a fixed number of threads The server adjusts to handle load by increasing or decreasing the number of processes A single control process is responsible for launching child processes Each child process creates a fixed number of threads as specified in the ThreadsPerChild directive The individual threads then listen for connections and serve them when they arrive Apache always tries to maintain a pool of spare or idle server threads which stand ready to serve incoming requests In this way clients do not need to wait for a new threads or processes to be created before their requests can be served The number of processes that will initially launched is set by the StartServers directive Then during operation Apache assesses the total number of idle threads in all processes and forks or kills processes to keep this number within the boundaries specified by MinSpareThreads and MaxSpareThreads Since this process is very self regulating it is rarely necessary to modify these directives from their default values The maximum number of clients that may be served simultaneously i e the maximum total number of threads in all processes is determined by the MaxClients directive while the maximum number of processes that can be launched is set by the ServerLimit directive ServerLimit multiplied by ThreadsPerChild must be greater than or equal to MaxClients A typical configuration of the process thread controls in the worker MPM could look as follows StartServers 2 MaxClients 150 MinSpareThreads 25 MaxSpareThreads 75

    Original URL path: http://ama09.obspm.fr/manual-2.0/mod/worker.html (2015-11-16)
    Open archived version from archive



  •