Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SHELL

check .conf file error apache

Syntax check
To check configuration files for syntax errors:

# Red Hat-based (Fedora, CentOS), Arch-based and OSX
httpd -t

# Debian-based (Ubuntu)
apache2ctl -t

# MacOS
apachectl -t

-------------------------------------------------------

List virtual hosts
To list all virtual hosts, and their locations:

# Red Hat-based (Fedora, CentOS), Arch-based and OSX
httpd -S

# Debian-based (Ubuntu)
apache2ctl -S

# MacOS
apachectl -S
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #check #file #error #apache
ADD COMMENT
Topic
Name
3+1 =