[systemd-devel] systemctl can't execute stop actually, when service is started by other way

清辰 624001899 at qq.com
Tue Jun 27 05:48:47 UTC 2017


for example: service nscd
1.execute: systemctl stop nscd.service
  stop nscd process actually
2.execute: /usr/bin/nscd
  start nscd by shell command
3.execute: systemctl status nscd.service
  inactive(dead)
  systemctl can't know nscd is running
4.excute: systemctl stop nscd.service
  nscd process still exist, it seems that systemctl does not execute stop actually


How can I stop nscd.service by systemctl when it is started not by systemctl?


Why I need stop nscd.service by systemctl? 
Because when linux reboot or shut down, linux will auto stop service by 'systemctl stop nscd.service'.
If 'systemctl stop nscd.service' does not stop service actually, my service will exit abnormally. That may lead data loss in my service.


Thank you very much
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/systemd-devel/attachments/20170627/88463c3e/attachment.html>


More information about the systemd-devel mailing list