Giter VIP home page Giter VIP logo

Comments (3)

schoettl avatar schoettl commented on August 14, 2024 1

You might need to tune perf_event_paranoid (source):

Thanks! That's it. Calling my program with sudo also works, but I prefer your suggestion.

Maybe you want to add this information to the your well-written README.

from prof.

cyrus-and avatar cyrus-and commented on August 14, 2024

Thanks!

You might need to tune perf_event_paranoid (source):

perf_event_paranoid:

Controls use of the performance events system by unprivileged
users (without CAP_SYS_ADMIN).  The default value is 2.

 -1: Allow use of (almost) all events by all users
     Ignore mlock limit after perf_event_mlock_kb without CAP_IPC_LOCK
>=0: Disallow ftrace function tracepoint by users without CAP_SYS_ADMIN
     Disallow raw tracepoint access by users without CAP_SYS_ADMIN
>=1: Disallow CPU event access by users without CAP_SYS_ADMIN
>=2: Disallow kernel profiling by users without CAP_SYS_ADMIN

For example with:

$ echo -1 | sudo tee /proc/sys/kernel/perf_event_paranoid

You can make it permanent with:

$ echo 'kernel.perf_event_paranoid=-1' | sudo tee /etc/sysctl.d/local.conf

Use the most appropriate value for your use case instead of -1.

from prof.

cyrus-and avatar cyrus-and commented on August 14, 2024

Maybe you want to add this information to the your well-written README.

Good idea, the value of that setting changed in Linux 4.6 so now it's an important thing to know.

from prof.

Related Issues (1)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.