Closed nasyxx closed 3 years ago
Hi,
This is likely a problem related to ldconfig (shared library runtime binding).
You can check with ldconfig -p | grep libnvidia-ml
If the output is empty this means that you need to add the /usr/lib/x86_64-linux-gnu/
directory to the config under /etc/ld.so.conf
or a in a new file under /etc/ld.so.conf.d
depending on your distribution.
Hi,
This is likely a problem related to ldconfig (shared library runtime binding). You can check with
ldconfig -p | grep libnvidia-ml
If the output is empty this means that you need to add the/usr/lib/x86_64-linux-gnu/
directory to the config under/etc/ld.so.conf
or a in a new file under/etc/ld.so.conf.d
depending on your distribution.
Hi,
I use nix-shell -p cmake ncurses
to install the nvtop, which does not support ldconfig -p
(nix does not support it). Thus, I now manually install it outside nix. And fixed it. Thanks!
# In nix-shell:
> ldconfig -p
ldconfig: Can't open cache file /nix/store/73k2knwhv4zzizsjr1g1dqjvzkamx8bd-glibc-2.33-49/etc/ld.so.cache
: No such file or directory
# But
> /sbin/ldconfig -p | grep libnvidia-ml
libnvidia-ml.so.1 (libc6,x86-64) => /usr/lib/x86_64-linux-gnu/libnvidia-ml.so.1
Thanks!
@nasyxx I had the same problem on NixOS and the solution was to do
hardware.opengl.enable = true;
which populates /run/opengl-driver/lib
$ objdump -x ./result/bin/nvtop | grep RUNPATH
RUNPATH /run/opengl-driver/lib:/nix/store/jzjqfff4cldlm2wpld313a2s1v6r3ycb-ncurses-6.2/lib:/nix/store/mij848h2x5wiqkwhg027byvmf9x3gx7y-glibc-2.33-50/lib
Hi, I successfully build the nvtop but it cannot find my GPUs.
I'm not sure which part should I provide here.
cmake .. && make -j
src/nvtop
nvidia-smi works fine: