← Back to team overview

kernel-packages team mailing list archive

[Bug 1375441] Re: 'perf record' fails with "Perf session creation failed"

 

** Tags removed: targetmilestone-inin---
** Tags added: targetmilestone-inin1410

-- 
You received this bug notification because you are a member of Kernel
Packages, which is subscribed to linux in Ubuntu.
https://bugs.launchpad.net/bugs/1375441

Title:
  'perf record' fails with "Perf session creation failed"

Status in “linux” package in Ubuntu:
  Confirmed

Bug description:
  ---Problem Description---
  When run as normal user, 'perf record ls' fails with:

    Perf session creation failed.

  The command runs successfully when run as root.
    
  ---uname output---
  Linux ubuntu 3.16.0-16-generic #22-Ubuntu SMP Wed Sep 17 18:45:43 UTC 2014 ppc64le ppc64le ppc64le GNU/Linux
   
  Machine Type = POWER8E pvr 004b 0201 

  > Maynard,
  > 
  > Can you check if /proc/sys/kernel/kptr_restrict has 1 in it on your
  > system ? 

  Yes, the value is '1'.

  > 
  > On my system it does have 1 and I can repro. Following seems to
  > fix:
  >     echo 0 > /proc/sys/kernel/kptr_restrict

  Yes, changing it to '0' does "fix" it, although that shouldn't be
  necessary, as you know.  So something is broken.

  I am able to repro with 3.17.0-rc4 based mainline perf tool.

  I suspect that the change in behavior was introduced unintentionally by
  this upstream commit. machine__create_kernel_maps() now calls
   machine__get_kernel_start_addr() which checks the kptr_restrict state.

  ---

  commit a93f0e551af9e194db38bfe16001e17a3a1d189a
  Author: Simon Que <sque@xxxxxxxxxxxx>
  Date:   Mon Jun 16 11:32:09 2014 -0700

      perf symbols: Get kernel start address by symbol name

  This is being fixed by a recent upstream commit:

      https://lkml.org/lkml/2014/9/27/26

  Will Ubuntu pick that fix up automatically ?

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1375441/+subscriptions