shutdown segv due to race w/ free_waiter threads
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
multipath-tools (Ubuntu) |
Fix Released
|
Low
|
Serge Hallyn | ||
Lucid |
Won't Fix
|
Low
|
Unassigned | ||
Maverick |
Won't Fix
|
Undecided
|
Unassigned |
Bug Description
Binary package hint: multipath-tools
=======
SRU Justification:
1. Impact: segv on multipathd shutdown
2. How bug was addressed: a patch was cherrypicked from upstream which fixes this
3. Minimal patch: see patch in attached bzr tree
4. TEST CASE: stop multipathd.
5. Regression potential: none, this patch was taken from upstream.
=======
I received a coredump from a customer (running a lucid-based system).
Analyzing the core from multipathd shows that we are crashing in waiter.
void free_waiter (void *data)
{
struct event_thread *wp = (struct event_thread *)data;
/*
* indicate in mpp that the wp is already freed storage
*/
lock(wp-
if (wp->mpp)
/*
* be careful, mpp may already be freed -- null if so
*/
wp->mpp->waiter = NULL;
else
condlog(3, "free_waiter, mpp freed before wp=%p,", wp);
unlock(
if (wp->dmt)
dm_task_
FREE(wp);
}
The lock is NULL:
(gdb) print wp->vecs->lock
$3 = (pthread_mutex_t *) 0x0
This appears to be the upstream issue fixed here:
http://
This fix is currently missing from all versions of multipath-tools in lucid->natty.
(The original customer issue was filed in the private bug #712875.)
Related branches
- Dustin Kirkland : Pending requested
-
Diff: 247 lines (+227/-0)3 files modifieddebian/changelog (+7/-0)
debian/patches/1004--race-condition-fix-with-free_waiter-threads-during-shutdown.patch (+219/-0)
debian/patches/series (+1/-0)
Changed in multipath-tools (Ubuntu): | |
status: | New → Confirmed |
assignee: | nobody → Serge Hallyn (serge-hallyn) |
importance: | Undecided → Low |
description: | updated |
tags: | added: testcase |
Thanks for the patch, Dann. I would ask you to hit 'propose for merge' from your lp tree, but I think it would be nice to have DEP-3 tags in the patch to help out future maintainers. So I'll add those to my own version and propose that for merge.