[英]is it possible to run linux perf tool inside docker container
I tried giving the below command from container and found the below issue, may be because of "-moby" kernel version.我尝试从容器中给出以下命令,发现以下问题,可能是因为“-moby”内核版本。 Can't we get a docker image without word "-moby" coming in linux kernel version.我们不能在 linux 内核版本中获得一个没有“-moby”字样的 docker 镜像。
I tried installing linux perf tool on VM having ubuntu and it worked.我尝试在具有 ubuntu 的 VM 上安装 linux perf 工具并且它工作正常。
#docker run -t -i ubuntu:14.04 /bin/bash
root@214daea94f4f:/# perf
WARNING: perf not found for kernel 4.9.41
You may need to install the following packages for this specific kernel:
linux-tools-4.9.41-moby
linux-cloud-tools-4.9.41-moby
You may also want to install one of the following packages to keep up to date:
linux-tools-moby-lts-<series>
linux-cloud-tools-moby-lts-<series>
just do就做
apt-get install linux-tools-generic
and make a symbolic link to /usr/bin/perf.并建立到 /usr/bin/perf 的符号链接。 (in my case): (在我的情况下):
ln -s /usr/lib/linux-tools/3.13.0-141-generic/perf /usr/bin/perf
it worked for me!它对我有用!
In debian buster-slim i used :在 debian buster-slim 中,我使用了:
apt-get install linux-perf
see: https://packages.debian.org/buster/linux-perf请参阅: https : //packages.debian.org/buster/linux-perf
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.