Difference between revisions of "apachectl"

from HTYP, the free directory anyone can edit if they can prove to me that they're not a spambot
Jump to navigation Jump to search
Line 4: Line 4:
 
* <code>apachectl -M</code> : shows loaded modules<ref name=sof />
 
* <code>apachectl -M</code> : shows loaded modules<ref name=sof />
 
* <code>apachectl -S</code> : dumps the entire config<ref name=sof /> (works in v2.4)
 
* <code>apachectl -S</code> : dumps the entire config<ref name=sof /> (works in v2.4)
 +
Default help dump:
 +
<pre>
 +
Usage: /usr/sbin/apache2 [-D name] [-d directory] [-f file]
 +
                        [-C "directive"] [-c "directive"]
 +
                        [-k start|restart|graceful|graceful-stop|stop]
 +
                        [-v] [-V] [-h] [-l] [-L] [-t] [-T] [-S] [-X]
 +
Options:
 +
  -D name            : define a name for use in <IfDefine name> directives
 +
  -d directory      : specify an alternate initial ServerRoot
 +
  -f file            : specify an alternate ServerConfigFile
 +
  -C "directive"    : process directive before reading config files
 +
  -c "directive"    : process directive after reading config files
 +
  -e level          : show startup errors of level (see LogLevel)
 +
  -E file            : log startup errors to file
 +
  -v                : show version number
 +
  -V                : show compile settings
 +
  -h                : list available command line options (this page)
 +
  -l                : list compiled in modules
 +
  -L                : list available configuration directives
 +
  -t -D DUMP_VHOSTS  : show parsed vhost settings
 +
  -t -D DUMP_RUN_CFG : show parsed run settings
 +
  -S                : a synonym for -t -D DUMP_VHOSTS -D DUMP_RUN_CFG
 +
  -t -D DUMP_MODULES : show all loaded modules
 +
  -M                : a synonym for -t -D DUMP_MODULES
 +
  -t -D DUMP_INCLUDES: show all included configuration files
 +
  -t                : run syntax check for config files
 +
  -T                : start without DocumentRoot(s) check
 +
  -X                : debug mode (only one worker, do not detach)
 +
</pre>
 
==Links==
 
==Links==
 
===Reference===
 
===Reference===

Revision as of 23:55, 11 September 2021

This page is a seed article. You can help HTYP water it: make a request to expand a given page and/or donate to help give us more writing-hours!

Options

  • apachectl configtest : tests the current configuration without trying to load it (which could result in Apache not running), and gives diagnostic information
  • apachectl -M : shows loaded modules[1]
  • apachectl -S : dumps the entire config[1] (works in v2.4)

Default help dump:

Usage: /usr/sbin/apache2 [-D name] [-d directory] [-f file]
                         [-C "directive"] [-c "directive"]
                         [-k start|restart|graceful|graceful-stop|stop]
                         [-v] [-V] [-h] [-l] [-L] [-t] [-T] [-S] [-X]
Options:
  -D name            : define a name for use in <IfDefine name> directives
  -d directory       : specify an alternate initial ServerRoot
  -f file            : specify an alternate ServerConfigFile
  -C "directive"     : process directive before reading config files
  -c "directive"     : process directive after reading config files
  -e level           : show startup errors of level (see LogLevel)
  -E file            : log startup errors to file
  -v                 : show version number
  -V                 : show compile settings
  -h                 : list available command line options (this page)
  -l                 : list compiled in modules
  -L                 : list available configuration directives
  -t -D DUMP_VHOSTS  : show parsed vhost settings
  -t -D DUMP_RUN_CFG : show parsed run settings
  -S                 : a synonym for -t -D DUMP_VHOSTS -D DUMP_RUN_CFG
  -t -D DUMP_MODULES : show all loaded modules 
  -M                 : a synonym for -t -D DUMP_MODULES
  -t -D DUMP_INCLUDES: show all included configuration files
  -t                 : run syntax check for config files
  -T                 : start without DocumentRoot(s) check
  -X                 : debug mode (only one worker, do not detach)

Links

Reference

Footnote