profiler - 我无法运行 "perf"命令。 Perf 是一个用于堆栈跟踪的 linux 分析器

标签 profiler perf

尝试使用性能分析器。我已经安装了 linux 通用工具,但没有成功。这是我收到的消息:


r@r-K55A:~$ perf
WARNING: perf not found for kernel 3.16.0-45

  You may need to install the following packages for this specific kernel:
    linux-tools-3.16.0-45-generic
    linux-cloud-tools-3.16.0-45-generic

  You may also want to install one of the following packages to keep up to date:
    linux-tools-generic
    linux-cloud-tools-generic

我已尝试安装上述软件包,但出现以下错误:


Unable to locate package linux-tools-3.16.0-45-generic
E: Couldn't find any package by regex 'linux-tools-3.16.0-45-generic'

最佳答案

您可以安全地使用此代码段:

sudo apt install linux-tools-common linux-tools-generic linux-tools-$(uname -r)

关于profiler - 我无法运行 "perf"命令。 Perf 是一个用于堆栈跟踪的 linux 分析器,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39456308/

相关文章:

java - 理解 perf.map

ruby-on-rails - 任何人都可以推荐在实时服务器环境中在乘客/nginx 组合下分析 Ruby on Rails 软件的最佳实践吗?

performance - 不同内核版本性能回归原因分析

linux - 使用 Linux 读取 ARMv8 中的 PMU 计数器

android - Linux perf stat 工具返回零指令计数。我在这里错过了什么?

linux - 性能不精确的调用图报告

linux - 无法使用 visualvm 和相同的 tempdir 分析本地 tomcat

sql - AnjLab SQL 分析器的持续时间使用的单位是什么

linux - 仅当线程运行时才向线程发送信号

intellij-idea - Intellij 中的配置文件