Arch Linux下的systemd httpd stop很慢

当我执行一个:

systemctl stop httpd 

Apache经常需要几分钟的时间来停止 命令:

 apachectl gracefully-stop 

总是立即停止。 任何人有任何想法可能会导致这个? 命令:

 systemctl start httpd 

 apachectl start 

都跑得很快。 不知何故,这是systemd和停止httpd相关(可能与Arch Linux相关)。

根据: https ://bugzilla.redhat.com/show_bug.cgi?id = 906321有缺省的systemd KillMode for Apache的问题。

一个临时的解决方法是将KillMode=none添加到/usr/lib/systemd/system/httpd.service

确保在进行更改后运行sudo systemctl --system daemon-reload