Bug 438449
| Summary: | /etc/rc.d/init.d/killall is racing with other "stops" | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Fedora] Fedora | Reporter: | Michal Jaegermann <michal> | ||||
| Component: | openssh | Assignee: | Tomas Mraz <tmraz> | ||||
| Status: | CLOSED RAWHIDE | QA Contact: | Fedora Extras Quality Assurance <extras-qa> | ||||
| Severity: | low | Docs Contact: | |||||
| Priority: | low | ||||||
| Version: | rawhide | CC: | archimerged, notting | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | All | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | openssh-5.0p1-1.fc9 | Doc Type: | Bug Fix | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2008-04-08 07:13:19 UTC | Type: | --- | ||||
| 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: | 235706 | ||||||
| Attachments: |
|
||||||
|
Description
Michal Jaegermann
2008-03-20 23:15:33 UTC
Created attachment 301544 [details]
Fixes this bug. /etc/init.d/sshd kills itself via killall sshd.
Add trap '' TERM before the killall and trap TERM after.
component should be changed to openssh > component should be changed to openssh
Is this truly the whole problem or you found (thanks!) one instance
where right now this is causing hiccups? 'killall' really used to
run as a final check and this does not seem to be the case anymore.
I put set -xv at front of /etc/init.d/killall and found that this is the script that causes all of the "stopping <subsys> ... [ OK ]" messages on the console. /usr/bin/killall is a completely different thing but it was related -- /etc/init.d/sshd wanted to kill /usr/sbin/sshd, but /usr/bin/killall kills the script as well as any extra sshd's. Seems to me I remember a bug just like this circa Solaris 2.5 ... The error message is somewhat misleading. It wasn't line 16, but line 16 is the beginning of the compound statement where the 'terminated' status code came back, and /etc/init.d/$subsys stop was the text of the line which got the bad status. When I changed that to bash -xv /etc/init.d/$subsys, the problem confusingly went away (since the process named bash, not sshd). > /usr/bin/killall is a completely different thing ...
Yes, I know. Maybe I should be more carefull but I thought that
from the context it was clear that we are talking about killall in
/etc/init.d/. See also a title for this bug report.
The comment about "there shouldn't be any" at the top of /etc/init.d/killall is no longer accurate and should be revised. That script is part of the initscripts rpm. (Or else if things were supposed to have been stopped by the Knn links in /etc/init.d/rc6.d/ then there is a bug in upstart or something like that. /etc/init.d/rc6.d/S00killall used to run after the Knn scripts IIRC.) Actually, it does sound like there is a bug, because killall kills subsystems in alphabetical order, not in the order specified by the Knn symbolic links. Probably need a new bug for that... I have patched the sshd init script in rawhide. |