Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何检查我的 apache 服务器配置中的语法错误,而无需重新启动或重新加载规则?这最好从终端/命令行完成。
如果语法没问题:
sudo apache2ctl configtest
将回复:
Syntax OK
如果您没有 httpd,也可以使用它。
apachectl configtest
在 linux 上,你使用
/usr/sbin/httpd -t
在 Windows 上,您将使用与 httpd.exe 文件等效的命令