Skip to content

Commit 49084e2

Browse files
committed
suggest -1 for perf_event_paranoid
1 parent a2bc4a4 commit 49084e2

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ samply record ./my-application my-arguments
1313
On Linux, samply uses perf events. You can grant temporary access by running:
1414

1515
```sh
16-
echo '1' | sudo tee /proc/sys/kernel/perf_event_paranoid
16+
echo '-1' | sudo tee /proc/sys/kernel/perf_event_paranoid
1717
```
1818

1919
## Installation

samply/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ samply record ./my-application my-arguments
1313
On Linux, samply uses perf events. You can grant temporary access by running:
1414

1515
```sh
16-
echo '1' | sudo tee /proc/sys/kernel/perf_event_paranoid
16+
echo '-1' | sudo tee /proc/sys/kernel/perf_event_paranoid
1717
```
1818

1919
Visit [the git repository](https://github.com/mstange/samply/) for more information.

samply/src/linux/profiler.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -405,7 +405,7 @@ fn init_profiler(
405405
eprintln!("In order for samply to work with a non-root user, this level needs");
406406
eprintln!("to be set to 1 or lower.");
407407
eprintln!("You can execute the following command and then try again:");
408-
eprintln!(" echo '1' | sudo tee /proc/sys/kernel/perf_event_paranoid");
408+
eprintln!(" echo '-1' | sudo tee /proc/sys/kernel/perf_event_paranoid");
409409
eprintln!();
410410
std::process::exit(1);
411411
}

0 commit comments

Comments
 (0)