问题
尝试安装perf监控程序资源开销,安装后报错
WARNING: perf not found for kernel 4.15.0-39
You may need to install the following packages for this specific kernel:
linux-tools-4.15.0-39-generic
linux-cloud-tools-4.15.0-39-generic
You may also want to install one of the following packages to keep up to date:
linux-tools-generic
linux-cloud-tools-generic
安装对应版本的linux-tools-4.15.0-39-generic
无法找到package
解决
其实perf已经内置在linux-tools-generic
里面,所以安装后创建perf软链接即可
sudo apt install linux-tools-generic
sudo ln -s ln -s /usr/lib/linux-tools/4.15.0-162-generic/perf /usr/bin/perf
其中4.15.0-162-generic
字段酌情替换