Segfault event notifier because of race condition

Bug #1640382 reported by Seyeong Kim on 2016-11-09
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Ubuntu Cloud Archive
qemu (Ubuntu)
Seyeong Kim

Bug Description


Sometimes instance get crashed with segfault on event notifier

gdb traceback is below[1]

trying to do SRU with below commits[2][3]


I can't provide the step to reproduce this issue

but provided gdb backtrace for this.

[Regeression Potential]

Above patch is merged on 2014, and it's quite simple patch.

[Other Info]

related link attached


[3];a=commit;h=df54f5efed9b3be7f40e14113cc1f13f5889e644 ( cherrypicked commit )

Seyeong Kim (xtrusia) on 2016-11-09
tags: added: openstack sts
Seyeong Kim (xtrusia) on 2016-11-09
Changed in qemu (Ubuntu Trusty):
status: New → In Progress
assignee: nobody → Seyeong Kim (xtrusia)
Seyeong Kim (xtrusia) on 2016-11-09
Changed in qemu (Ubuntu):
status: New → Invalid
Changed in qemu (Ubuntu Xenial):
status: New → Invalid
Seyeong Kim (xtrusia) on 2016-11-09
tags: added: sts-sponsor sts-sru
Seyeong Kim (xtrusia) wrote :

rebased and reuploaded

Changed in qemu (Ubuntu):
status: Invalid → Fix Released
importance: Undecided → Medium
Changed in qemu (Ubuntu Trusty):
importance: Undecided → Medium
no longer affects: qemu (Ubuntu Xenial)
Brian Murray (brian-murray) wrote :

Given that there is no test case in the description, an alternative way to verify the fix would be to find an crash report in the Error Tracker matching the same race condition and watching to ensure that the new package version does not appear in the bucket for that crash. Could you review crashes here to find one that matches? 14.04&package=qemu

You might try changing the period from day to month or year.

Seyeong Kim (xtrusia) wrote :

Hey Brian

I couldn't find any similar bug on

but I found LP bug which forwarded 1 step then this.

does it worth testing above LP bug for this issue as well? ( or mark duplicate after testing )

Need advice

Thanks a lot

Seyeong Kim (xtrusia) wrote :

It seems that [1] commit introduces [2] ( which is happened in 2.1 as amad ali said )

and patch [3] is fixing [2]

I think this needs combinded patch but not sure.


Seyeong Kim (xtrusia) wrote :
Sebastien Bacher (seb128) wrote :

seems there is already an upload in the SRU queue waiting for review

Per discussion with Seyeong Kim this should also apply to Ubuntu Cloud Archive Kilo.
This has the first but lacks the second fix.
He can work that out with the UCA Team.

Changed in cloud-archive:
status: New → Confirmed
Seyeong Kim (xtrusia) wrote :

Hello seb128

I asked SRU only one commit at first,

but I found this raises bug 1587039(after browsing this symptom), then now I'm asking to sponsor or sru new debdiff.

the patch in the queue needs to be NAck and be changed to latest one if is ok.

I asked cpaelzer guide this and he commented to about this.

Would you mind if you nack this and change patch?

Thanks a lot

Seyeong Kim (xtrusia) wrote :

oh and uca kilo has fixes.

uca icehouse needs this

Robie Basak (racb) wrote :

Rejected from the Trusty queue as requested. I don't see another upload to replace it though. Note for the future: you don't need to wait for a rejection before uploading a replacement; just make it clear to the SRU team which needs to be rejected and which you need to keep. See for the current queue.

Seyeong Kim (xtrusia) wrote :

Hello Seyeong, or anyone else affected,

Accepted qemu into trusty-proposed. The package will build now and be available at in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See for documentation on how to enable and use -proposed.Your feedback will aid us getting this update out to other Ubuntu users.

If this package fixes the bug for you, please add a comment to this bug, mentioning the version of the package you tested, and change the tag from verification-needed to verification-done. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at . Thank you in advance!

Changed in qemu (Ubuntu Trusty):
status: In Progress → Fix Committed
tags: added: verification-needed
Robie Basak (racb) wrote :

Unsubscribed ~ubuntu-sponsors.

Seyeong Kim (xtrusia) wrote :

ii qemu 2.0.0+dfsg-2ubuntu1.31 amd64 fast processor emulator
ii qemu-keymaps 2.0.0+dfsg-2ubuntu1.31 all QEMU keyboard maps
ii qemu-system 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries
ii qemu-system-arm 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (arm)
ii qemu-system-common 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (common files)
ii qemu-system-mips 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (mips)
ii qemu-system-misc 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (miscelaneous)
ii qemu-system-ppc 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (ppc)
ii qemu-system-sparc 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (sparc)
ii qemu-system-x86 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU full system emulation binaries (x86)
ii qemu-user 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU user mode emulation binaries
ii qemu-utils 2.0.0+dfsg-2ubuntu1.31 amd64 QEMU utilities

tags: added: verification-done
removed: verification-needed
Changed in cloud-archive:
status: Confirmed → Invalid
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package qemu - 2.0.0+dfsg-2ubuntu1.31

qemu (2.0.0+dfsg-2ubuntu1.31) trusty; urgency=medium

  * aio: fix qemu_bh_schedule() bh->ctx race condition (LP: #1640382)
    - d/p/0001-aio-fix-qemu_bh_schedule-bh-ctx-race-condition.patch
  * aio: strengthen memory barriers for bottom half scheduling
    (LP: #1587039)
    - d/p/0002-aio-strengthen-memory-barriers-for-bottom-half-sched.patch

 -- Seyeong Kim <email address hidden> Thu, 24 Nov 2016 10:44:55 +0100

Changed in qemu (Ubuntu Trusty):
status: Fix Committed → Fix Released

The verification of the Stable Release Update for qemu has completed successfully and the package has now been released to -updates. Subsequently, the Ubuntu Stable Release Updates Team is being unsubscribed and will not receive messages about this bug report. In the event that you encounter a regression using the package from -updates please report a new bug using ubuntu-bug and tag the bug report regression-update so we can easily find any regressions.

Louis Bouchard (louis) on 2017-03-22
tags: added: sts-sru-done
removed: sts-sru
Dan Streetman (ddstreet) on 2019-03-20
tags: removed: sts-sponsor
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers