Ubuntu 20.04 nvtop 编译安装

Ubuntu 20.04 nvtop 编译安装

nvidia-smi

# nvidia-smi
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 460.56       Driver Version: 460.56       CUDA Version: 11.2     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|                               |                      |               MIG M. |
|===============================+======================+======================|
|   0  GeForce RTX 3090    Off  | 00000000:45:00.0 Off |                  N/A |
| 30%   24C    P8     5W / 350W |      2MiB / 24268MiB |      0%      Default |
|                               |                      |                  N/A |
+-------------------------------+----------------------+----------------------+

+-----------------------------------------------------------------------------+
| Processes:                                                                  |
|  GPU   GI   CI        PID   Type   Process name                  GPU Memory |
|        ID   ID                                                   Usage      |
|=============================================================================|
|  No running processes found                                                 |
+-----------------------------------------------------------------------------+

安装nvtop

# apt install -y nvtop
Reading package lists... Done
Building dependency tree
Reading state information... Done
You might want to run 'apt --fix-broken install' to correct these.
The following packages have unmet dependencies:
 linux-image-generic : Depends: linux-image-5.4.0-72-generic but it is not going to be installed
 linux-modules-extra-5.4.0-72-generic : Depends: linux-image-5.4.0-72-generic but it is not going to be installed or
                                                 linux-image-unsigned-5.4.0-72-generic but it is not going to be installed
 nvtop : Depends: libnvidia-compute-418 but it is not going to be installed
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).

编译安装nvtop

apt install cmake libncurses5-dev libncursesw5-dev git -y 
git clone https://github.com/Syllo/nvtop.git
mkdir -p nvtop/build && cd nvtop/build
cmake ..
make install
# sudo make install
Scanning dependencies of target nvtop
[ 12%] Building C object src/CMakeFiles/nvtop.dir/nvtop.c.o
[ 25%] Building C object src/CMakeFiles/nvtop.dir/interface.c.o
[ 37%] Building C object src/CMakeFiles/nvtop.dir/interface_layout_selection.c.o
[ 50%] Building C object src/CMakeFiles/nvtop.dir/get_process_info_linux.c.o
[ 62%] Building C object src/CMakeFiles/nvtop.dir/extract_gpuinfo.c.o
[ 75%] Building C object src/CMakeFiles/nvtop.dir/time.c.o
[ 87%] Building C object src/CMakeFiles/nvtop.dir/plot.c.o
[100%] Linking C executable nvtop
[100%] Built target nvtop
Install the project...
-- Install configuration: "Release"
-- Installing: /usr/local/share/man/man1/nvtop.1
-- Installing: /usr/local/bin/nvtop
-- Set runtime path of "/usr/local/bin/nvtop" to "/usr/local/lib"

在这里插入图片描述


参考:

  1. nvtop
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值