Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.

Bug 1033042

Summary: "systemctl stop <service>" doesn't kill services started from cmdline.
Product: Red Hat Enterprise Linux 7 Reporter: Kaushik Banerjee <kbanerje>
Component: doc-System_Administrators_GuideAssignee: Jaromir Hradilek <jhradile>
Status: CLOSED CURRENTRELEASE QA Contact: ecs-bugs
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 7.0CC: jhradile, lnykryn, systemd-maint-list
Target Milestone: rcKeywords: Documentation
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-06-11 14:25:47 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1052221    

Description Kaushik Banerjee 2013-11-21 13:16:04 UTC
Description of problem:
systemctl stop <service> doesn't kill daemons started from cmdline.

This is probably a feature in systemd. Logging this as a bug to see if this can be documented, since this is a change in behaviour from RHEL6.

Version-Release number of selected component (if applicable):
systemd-207-2.el7.x86_64

How reproducible:
Always

Steps to Reproduce:
1. sssd -d 9 -f -c /tmp/sssd.conf

2. # systemctl stop sssd.service
# ps ax | grep sssd
18140 ?        Ss     0:00 sssd -d 9 -f -c /tmp/sssd.conf
18141 ?        S      0:00 /usr/libexec/sssd/sssd_be --domain LDAPTEST -d 0x77f0 --debug-to-files
18142 ?        S      0:00 /usr/libexec/sssd/sssd_nss -d 0x77f0 --debug-to-files
18143 ?        S      0:00 /usr/libexec/sssd/sssd_pam -d 0x77f0 --debug-to-files

3. # systemctl restart sssd.service
# ps ax | grep sssd
18140 ?        Ss     0:00 sssd -d 9 -f -c /tmp/sssd.conf
18141 ?        S      0:00 /usr/libexec/sssd/sssd_be --domain LDAPTEST -d 0x77f0 --debug-to-files
18142 ?        S      0:00 /usr/libexec/sssd/sssd_nss -d 0x77f0 --debug-to-files
18143 ?        S      0:00 /usr/libexec/sssd/sssd_pam -d 0x77f0 --debug-to-files
18333 ?        Ss     0:00 /usr/sbin/sssd -D -f
18334 ?        S      0:00 /usr/libexec/sssd/sssd_be --domain LDAPTEST --debug-to-files
18335 ?        S      0:00 /usr/libexec/sssd/sssd_nss --debug-to-files
18336 ?        S      0:00 /usr/libexec/sssd/sssd_pam --debug-to-files

Actual results:


Expected results:


Additional info:

Comment 2 Michal Schmidt 2013-11-21 13:41:46 UTC
Daemons forked off from a user's shell (and hence running in the user's session cgroup) are not "services" as such. See also bug 1021565, bug 990039.

Comment 3 Lukáš Nykrýn 2013-11-25 12:29:49 UTC
Maybe this could be mentioned in documentation in differences between service in rhel6 and systemctl in rhel7. (But please note that service in rhel7 is just calling systemctl)

Comment 5 Jaromir Hradilek 2013-11-28 15:23:13 UTC
Thank you, I will document this in the chapter about systemd.