Asked 3 years, 1 month ago
you stated I have an NVIDIA driver installed however you did not describe how you installed it. Be aware the nvidia driver is a kernel module and it is often lost after doing a yum update
when a kernel update happens; the nvidia kernel module is not preserved (unless you have DKMS installed) so nvidia functionality will then cease.
However that does not explain why /usr/bin/nvidia-smi
says command not found which is another matter, but that is where nvidia-smi
should be and /usr/bin
should obviously be in your PATH. Simply reinstalling nvidia via the nvidia.run file will fix that...
Below is my preferred method for doing NVIDIA install (and cuda) under RHEL/CentOS 7.x which has served me well (for about the last 3 years)
- download
NVIDIA-Linux-x86_64-460.67.run
from nvidia {get the correct one for your graphics card} approx 150mb
- download
cuda_11.2.2_460.32.03_linux.run
from nvidia {whatever the latest version is, over 2gb}
su
to root; copy both to /root; chmod 700
on both;
systemctl set-default multi-user.target
reboot
or systemctl isolate multi-user.target
or init 3
- run /root/NVIDIA-Linux-x86_64-460.67.run {and observe the building kernel module part}
- after successful install,
/usr/bin/nvidia-smi
should be present and work;
- then do a
systemctl isolate graphical.target
or init 5
and if a graphical console works then log in, and set back to systemctl set-default graphical.target
if you prefer.
- ideally do one last reboot to validate everything is working
The CUDA install is basically the same process.
The bundled nvidia graphics driver within the cuda.run file is not always the latest.
The latest nvidia.run driver will (should) always work with whatever cuda version.
You are not required to install the bundled nvidia graphics driver within the cuda.run file, so my preference is to uncheck that when installing cuda.
find /usr -iname nvidia-smi
?