我有一个新的Debian不稳定的基于apache2的发行版。 Apache本身工作正常。 如果我使用
sudo service apache2 start
它出现,一切顺利。
但是它的服务无法启动每一次启动。
如何在这里跟踪错误?
等/日志/的Apache2 / error.log中:
[Sun Jan 15 14:51:06.685936 2017] [mpm_prefork:notice] [pid 2208] AH00169: caught SIGTERM, shutting down [Sun Jan 15 14:51:47.842447 2017] [mpm_prefork:notice] [pid 2200] AH00163: Apache/2.4.23 (Debian) configured -- resuming normal operations [Sun Jan 15 14:51:48.145808 2017] [core:notice] [pid 2200] AH00094: Command line: '/usr/sbin/apache2' [Sun Jan 15 14:55:25.766188 2017] [mpm_prefork:notice] [pid 3257] AH00163: Apache/2.4.23 (Debian) configured -- resuming normal operations [Sun Jan 15 14:55:25.801736 2017] [core:notice] [pid 3257] AH00094: Command line: '/usr/sbin/apache2' [Sun Jan 15 16:08:15.031691 2017] [mpm_prefork:notice] [pid 2316] AH00163: Apache/2.4.23 (Debian) configured -- resuming normal operations [Sun Jan 15 16:08:15.043756 2017] [core:notice] [pid 2316] AH00094: Command line: '/usr/sbin/apache2' [Mon Jan 16 11:26:33.007967 2017] [mpm_prefork:notice] [pid 2278] AH00163: Apache/2.4.23 (Debian) configured -- resuming normal operations [Mon Jan 16 11:26:33.013972 2017] [core:notice] [pid 2278] AH00094: Command line: '/usr/sbin/apache2' [Tue Jan 17 08:07:35.149382 2017] [mpm_prefork:notice] [pid 3517] AH00163: Apache/2.4.23 (Debian) configured -- resuming normal operations [Tue Jan 17 08:07:35.152372 2017] [core:notice] [pid 3517] AH00094: Command line: '/usr/sbin/apache2'
还有哪些其他文件可以帮助debugging服务失败?
系统按devise工作没有故障。 这听起来像你可能只需要启用该服务,所以它在启动时启动。
systemctl enable service
你可能想花一些时间用systemctl / systemd文件。
systemctl --no-page -t service -a | grep apache2 systemctl --no-page -t service -a | grep apache2 systemctl enable apache2 && systemctl start apache2 systemctl status apache2 journalctl --no-page -u apache2.service 注意 。 -f键与journalctl以及tail