[SERVER-14179] smoke.py leaves orphan processes when mongod startup times out Created: 05/Jun/14  Updated: 16/Jun/14  Resolved: 11/Jun/14

Status: Closed
Project: Core Server
Component/s: Build
Affects Version/s: 2.6.0
Fix Version/s: 2.7.2

Type: Bug Priority: Major - P3
Reporter: Matt Kangas Assignee: Matt Kangas
Resolution: Done Votes: 0
Labels: community-team
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Server 2.7.2
Participants:
Linked BF Score: 0

 Description   

smoke.py can leave orphan processes on failure, which causes MCI to wait two hours unnecessarily before it declares the task failed.

Given a dummy "sleep-forever" script:

#!/bin/sh
exec sleep 32768

Run smoke.py with --mongod=sleep-forever. Here I toggle on buildlogger for extra fun:

$ python ./buildscripts/smoke.py --mongod=/Users/kangas/bin/sleep-forever --buildlogger-builder=mattkangas --buildlogger-buildnum=1 --buildlogger-credentials=../buildlogger.creds --buildlogger-phase=junk jsCore

While running:

$ pstree -s python
-+= 00001 root /sbin/launchd
 \-+= 00143 kangas /sbin/launchd
   \-+= 00210 kangas /Applications/iTerm.app/Contents/MacOS/iTerm -psn_0_57358
     \-+= 02127 root login -fp kangas
       \-+= 02128 kangas -bash
         \-+= 05251 kangas python ./buildscripts/smoke.py --mongod=/Users/kangas/bin/sleep-forever --buildlogger-builder=mattkangas --buildlogger-buildnu
           \-+- 05253 kangas /usr/bin/python buildscripts/buildlogger.py -g /Users/kangas/bin/sleep-forever --port 27999 --dbpath /data/db/sconsTests/ --
             \--- 05254 kangas sleep 32768

After it times out:

$ pstree -s python
-+= 00001 root /sbin/launchd
 \-+- 05253 kangas /usr/bin/python buildscripts/buildlogger.py -g /Users/kangas/bin/sleep-forever --port 27999 --dbpath /data/db/sconsTests/ --setParamet
   \--- 05254 kangas sleep 32768

Orphans!



 Comments   
Comment by Githook User [ 11/Jun/14 ]

Author:

{u'username': u'kangas', u'name': u'Matt Kangas', u'email': u'matt.kangas@mongodb.com'}

Message: SERVER-14179 smoke.py leaves orphan mongod process
Branch: master
https://github.com/mongodb/mongo/commit/9a5f41d211fe3679aacd4a5191252a5c749fbe96

Comment by Matt Kangas [ 10/Jun/14 ]

Patch builds scheduled:

wide: https://mci.10gen.com/ui/version/53970ac13ff1225083000084_0
deep: https://mci.10gen.com/ui/version/53970aee3ff1225083000085_0

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