[SERVER-2501] stopMongod may return while mongod process is still running Created: 09/Feb/11  Updated: 12/Jul/16  Resolved: 17/Mar/11

Status: Closed
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: 1.9.0

Type: Bug Priority: Major - P3
Reporter: Aaron Staple Assignee: Eliot Horowitz (Inactive)
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Participants:

 Description   

Quoting myself from some earlier emails - not sure if there have been any code changes since these emails:

> I think the implementation is supposed to be synchronous, but it looks like on windows it might not be. Were you seeing async behavior on windows only?
> In particular according to the GetExitCodeProcess doc it looks like GetExitCodeProcess may return true before the process has stopped.

...

> Should be easy to fix by checking if the status returned by GetExitCodeProcess is STILL_ACTIVE or not and only returning true in wait_for_pid if it is not.
> <http://msdn.microsoft.com/en-us/library/ms683189(v=vs.85).aspx>
> I can try to fix if you want, but I don't have windows so will have to debug any failures by looking at buildbot.



 Comments   
Comment by Eliot Horowitz (Inactive) [ 17/Mar/11 ]

believe my change worked

Comment by auto [ 10/Feb/11 ]

Author:

{u'login': u'erh', u'name': u'Eliot Horowitz', u'email': u'eliot@10gen.com'}

Message: try to fix SERVER-2501
https://github.com/mongodb/mongo/commit/1041ffd623cfa2d2ad6b5dc0fad16eda54924905

Comment by auto [ 09/Feb/11 ]

Author:

{u'login': u'astaple', u'name': u'Aaron', u'email': u'aaron@10gen.com'}

Message: add sleep in dumprestore2 to handle SERVER-2501
https://github.com/mongodb/mongo/commit/2194e18a93cf3ebaca4e74647be8467d3f7bdd20

Generated at Thu Feb 08 03:00:12 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.