ubuntu_lttng_smoke_test failed on A-hwe kernel

Bug #1727251 reported by Po-Hsu Lin
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
lttng-modules (Ubuntu)
Fix Released
Medium
Colin Ian King
Xenial
Fix Released
Undecided
Unassigned

Bug Description

[SRU lttng-modules-dkms XENIAL for 4.13 kernel support]

lttng fails to build because of API changes in 4.13.

[FIX]

Apply the following upstream lttng commits for 4.11, 4.12 compat fixes:

Fix-update-mm_vmscan-instrumentation-for-kernel-4.11.patch
Fix-update-btrfs-instrumentation-for-kernel-4.11.patch
Fix-changes-to-the-vm_op-fault-cb-prototype-in-libri.patch
Fix-update-scsi-instrumentation-for-kernel-4.11.patch
Fix-timers-cputime_t-arguments-replaced-by-ull-in-ke.patch
Fix-atomic_add_unless-returns-true-false-rather-than.patch
Fix-kref-changes-for-kernel-4.11.patch
Fix-update-sched-instrumentation-for-kernel-4.12.patch
Fix-update-ringbuffer-for-kernel-4.12.patch
Fix-update-block-instrumentation-for-kernel-4.12.patch
Fix-update-ftrace-probe-for-kernel-4.12.patch
Fix-Build-ftrace-probe-on-kernels-prior-to-4.12.patch
Fix-handle-missing-ftrace-header-on-v4.12.patch
Fix-section-mismatch-warning-caused-by-__exit-annota.patch
Fix-missing-ftrace-header-on-v4.11.patch

Also: Don't build ftrace lttng module for 4.11 upwards as this currently
requires the full kernel source and not just the headers anymore,
add kernel version check in lttng-modules-dkms.dkms.in

[TEST]
from kernel team autotests:

sudo autotest/client/autotest-local autotest/client/tests/ubuntu_lttng_smoke_test/control

Without the fixes, these will fail. With the fixes, the regression tests pass. Run this 4.4, 4.8 and 4.13-hwe kernels, must pass on all three kernel versions.

[REGRESSION POTENTIAL]
This affects just the lttng tools. Could break pre-4.13 older kernels, so needs regression checking on supported kernel versions.

-------------------------------

Kernel 4.13.0-16.19~16.04.3

4 tests failed for the ubuntu_lttng_smoke_test with amd64 / arm64 / i386 / ppc64le systems:
 == lttng smoke test of session create/destroy ==
 Session test-kernel-session created.
 Traces will be written in /tmp/lttng-kernel-trace-21869-session
 PASSED (lttng create)
 Session test-kernel-session destroyed
 PASSED (lttng destroy)

 == lttng smoke test list kernel events ==
 Error: Unable to list kernel events: Kernel tracer not available
 Error: Command error
 FAILED (lttng list --kernel)
 FAILED (lttng list --kernel more output expected)

 == lttng smoke test trace open/close system calls ==
 Session test-kernel-session created.
 Traces will be written in /tmp/lttng-kernel-trace-21869-session
 PASSED (lttng create)
 Error: Event open: Kernel tracer not available (channel channel0, session test-kernel-session)
 Error: Event openat: Kernel tracer not available (channel channel0, session test-kernel-session)
 Error: Event close: Kernel tracer not available (channel channel0, session test-kernel-session)
 FAILED (lttng enable-event)
 Session test-kernel-session destroyed

 == lttng smoke test trace context switches ==
 Session test-kernel-session created.
 Traces will be written in /tmp/lttng-kernel-trace-21869-session
 PASSED (lttng create)
 Error: Event sched_switch: Kernel tracer not available (channel channel0, session test-kernel-session)
 FAILED (lttng enable-event)

Po-Hsu Lin (cypressyew)
Changed in linux (Ubuntu):
assignee: nobody → Colin Ian King (colin-king)
Po-Hsu Lin (cypressyew)
description: updated
description: updated
description: updated
Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1727251

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

It looks like the azure 4.11 kernel is having the same issue.

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Incomplete → In Progress
Revision history for this message
Colin Ian King (colin-king) wrote :

I can't get any DKMS package to build and install with this kernel and headers. Can somebody else sanity check that DKMS is not working per se rather than lttng

description: updated
description: updated
Revision history for this message
Colin Ian King (colin-king) wrote :

Debdiff of fix

Revision history for this message
Colin Ian King (colin-king) wrote :
tags: added: patch
Revision history for this message
Po-Hsu Lin (cypressyew) wrote :

With Colin's PPA added, all tests in lttng-smoke-test have passed.

4.13.0-16-lowlatency #19~16.04.3-Ubuntu

06:17:05 INFO | == lttng smoke test of session create/destroy ==
06:17:05 INFO | Session test-kernel-session created.
06:17:05 INFO | Traces will be written in /tmp/lttng-kernel-trace-30134-session
06:17:05 INFO | PASSED (lttng create)
06:17:05 INFO | Session test-kernel-session destroyed
06:17:05 INFO | PASSED (lttng destroy)
06:17:05 INFO |
06:17:05 INFO | == lttng smoke test list kernel events ==
06:17:05 INFO | PASSED (lttng list --kernel)
06:17:05 INFO |
06:17:05 INFO | == lttng smoke test trace open/close system calls ==
06:17:05 INFO | Session test-kernel-session created.
06:17:05 INFO | Traces will be written in /tmp/lttng-kernel-trace-30134-session
06:17:05 INFO | PASSED (lttng create)
06:17:05 INFO | Kernel event open created in channel channel0
06:17:05 INFO | Kernel event openat created in channel channel0
06:17:05 INFO | Kernel event close created in channel channel0
06:17:05 INFO | PASSED (lttng enable-event)
06:17:05 INFO | Tracing started for session test-kernel-session
06:17:05 INFO | PASSED (lttng start)
06:17:05 INFO | Waiting for data availability.......
06:17:05 INFO | Tracing stopped for session test-kernel-session
06:17:05 INFO | PASSED (lttng stop)
06:17:05 INFO | Session test-kernel-session destroyed
06:17:05 INFO | PASSED (lttng destroy)
06:17:05 INFO | PASSED (simple system call tracing with babeltrace)
06:17:05 INFO |
06:17:05 INFO | == lttng smoke test trace context switches ==
06:17:05 INFO | Session test-kernel-session created.
06:17:05 INFO | Traces will be written in /tmp/lttng-kernel-trace-30134-session
06:17:05 INFO | PASSED (lttng create)
06:17:05 INFO | Kernel event sched_switch created in channel channel0
06:17:05 INFO | PASSED (lttng enable-event)
06:17:05 INFO | Tracing started for session test-kernel-session
06:17:05 INFO | PASSED (lttng start)
06:17:05 INFO | Waiting for data availability...
06:17:05 INFO | Tracing stopped for session test-kernel-session
06:17:05 INFO | PASSED (lttng stop)
06:17:05 INFO | Session test-kernel-session destroyed
06:17:05 INFO | PASSED (lttng destroy)
06:17:05 INFO | Found 22654 dd and 70653 context switches
06:17:05 INFO | PASSED (simple system call tracing with babeltrace)
06:17:05 INFO |
06:17:05 INFO | Summary: 13 passed, 0 failed

Revision history for this message
Brian Murray (brian-murray) wrote : Please test proposed package

Hello Po-Hsu, or anyone else affected,

Accepted lttng-modules into xenial-proposed. The package will build now and be available at https://launchpad.net/ubuntu/+source/lttng-modules/2.8.0-1ubuntu1~16.04.3 in a few hours, and then in the -proposed repository.

Please help us by testing this new package. See https://wiki.ubuntu.com/Testing/EnableProposed 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-xenial to verification-done-xenial. If it does not fix the bug for you, please add a comment stating that, and change the tag to verification-failed-xenial. In either case, details of your testing will help us make a better decision.

Further information regarding the verification process can be found at https://wiki.ubuntu.com/QATeam/PerformingSRUVerification . Thank you in advance!

tags: added: verification-needed verification-needed-xenial
affects: linux (Ubuntu) → lttng-modules (Ubuntu)
Changed in lttng-modules (Ubuntu Xenial):
status: New → Fix Committed
Changed in lttng-modules (Ubuntu):
status: In Progress → Fix Released
Revision history for this message
Colin Ian King (colin-king) wrote :

Tested with 4.13.0-16 HWE kernel and 4.4.0-100 kernel, builds and runs fine, passes the lttng kernel regression tests. Marking it as verified.

tags: added: verification-done verification-done-xenial
removed: verification-needed verification-needed-xenial
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package lttng-modules - 2.8.0-1ubuntu1~16.04.3

---------------
lttng-modules (2.8.0-1ubuntu1~16.04.3) xenial; urgency=medium

  * Fix builds on HWE 4.13 kernel (LP: #1727251)
    Apply the following upstream commits:
     0015-Fix-update-mm_vmscan-instrumentation-for-kernel-4.11.patch
     0016-Fix-update-btrfs-instrumentation-for-kernel-4.11.patch
     0017-Fix-changes-to-the-vm_op-fault-cb-prototype-in-libri.patch
     0018-Fix-update-scsi-instrumentation-for-kernel-4.11.patch
     0019-Fix-timers-cputime_t-arguments-replaced-by-ull-in-ke.patch
     0020-Fix-atomic_add_unless-returns-true-false-rather-than.patch
     0021-Fix-kref-changes-for-kernel-4.11.patch
     0022-Fix-update-sched-instrumentation-for-kernel-4.12.patch
     0023-Fix-update-ringbuffer-for-kernel-4.12.patch
     0024-Fix-update-block-instrumentation-for-kernel-4.12.patch
     0025-Fix-update-ftrace-probe-for-kernel-4.12.patch
     0026-Fix-Build-ftrace-probe-on-kernels-prior-to-4.12.patch
     0027-Fix-handle-missing-ftrace-header-on-v4.12.patch
     0028-Fix-section-mismatch-warning-caused-by-__exit-annota.patch
     0029-Fix-missing-ftrace-header-on-v4.11.patch
  * Don't build ftrace lttng module for 4.11 upwards as this currently
    requires the full kernel source and not just the headers anymore,
    add kernel version check in lttng-modules-dkms.dkms.in

 -- Colin Ian King <email address hidden> Thu, 26 Oct 2017 18:00:02 +0100

Changed in lttng-modules (Ubuntu Xenial):
status: Fix Committed → Fix Released
Revision history for this message
Chris Halse Rogers (raof) wrote : Update Released

The verification of the Stable Release Update for lttng-modules 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.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.