Instalando o driver de vídeo da Nvidia + Cuda no Rocky9

 
echo instalando os kernels necessarios
sudo dnf update
sudo dnf install kernel-devel kernel-headers
 
echo adicionando os repositorios necessarios
sudo dnf config-manager --add-repo https://developer.download.nvidia.com/compute/cuda/repos/rhel9/x86_64/cuda-rhel9.repo
sudo dnf config-manager --set-enabled crb
sudo yum install epel-release
 
echo instalando o driver nvidia
sudo dnf module install nvidia-driver:latest-dkms
 
echo reiniciando
reboot

echo testando o driver nvidia
nvidia-smi

echo instalando o cuda
#sudo dnf install cuda-driver
sudo dnf install cuda-toolkit

Compilando/Instalando o Gromacs



echo instalacao do gromacs no rocky 9
dnf install gcc-toolset-12 cmake
wget https://ftp.gromacs.org/gromacs/gromacs-2024.3.tar.gz
tar xfz gromacs-2024.3.tar.gz
cd gromacs-2024.3
mkdir build
cd build
cmake .. -DGMX_BUILD_OWN_FFTW=ON -DREGRESSIONTEST_DOWNLOAD=ON -DGMX_GPU=CUDA -DGMX_MPI=OFF -DGMX_USE_RDTSCP=OFF -DCMAKE_CUDA_COMPILER:PATH=/usr/local/cuda/bin/nvcc
make
make check
sudo make install

echo no ubuntu foi com este comando:
cmake .. -DGMX_BUILD_OWN_FFTW=ON -DREGRESSIONTEST_DOWNLOAD=ON -DGMX_GPU=CUDA -DGMX_MPI=OFF -DCMAKE_C_COMPILER=/usr/bin/gcc-12 -DCMAKE_CXX_COMPILER=/usr/bin/g++-12 -DGMX_USE_RDTSCP=OFF