deviceQuery fails

I have a superserver 7047r-trt platform with GTX Titan X (Maxwell) installed. I did a fresh install of the RHEL 7.4 server and installed cuda driver and toolkit using procedure published by RedHat. I used the most recent version of *.run installer from Nvidia. The installer confirmed sucessful installation of the cuda driver. Now I compiled the samples and try run ./deviceQuery as root. The resulting message is following:

./deviceQuery Starting…

CUDA Device Query (Runtime API) version (CUDART static linking)

cudaGetDeviceCount returned 30
-> unknown error
Result = FAIL

What goes wrong. Maybe someone has had a similar problem.

you might need to reboot.

perhaps you did not remove the nouveau driver correctly.

Beyond that, I have no idea what the “procedure published by RedHat” is. You should follow the procedure published by NVIDIA. If you want to follow the procedures published by Redhat, then ask Redhat for help when they do not work.

I am facing the same error even though I rebooted and removed nouveau driver correctly.

Here are the steps I followed to remove nouveau driver:

vi /etc/modprobe.d/blacklist-nouveau.conf
Added the below…
blacklist nouveau
blacklist lbm-nouveau
options nouveau modeset=0
alias nouveau off
alias lbm-nouveau off

echo options nouveau modeset=0 | sudo tee -a /etc/modprobe.d/nouveau-kms.conf

update-initramfs -u


But no luck.