Need to uninstall the baked in nvidia drives and install nvidia drivers from the run
file:
- Don't install the driver (that'll be wsl passthru), just everything else
Install cublas? After my install of the runfile i didn't actually have this installed, so had to do it manually.
sudo apt install libcublas11
pushd .
cd /usr/lib/wsl/lib
sudo rm libcuda.so libcuda.so.1
sudo ln -s libcuda.so.1.1 libcuda.so.1
sudo ln -s libcuda.so.1 libcuda.so
sudo ldconfig
popd
curl https://get.docker.com | sh \
&& sudo systemctl --now enable docker
https://docs.nvidia.com/datacenter/cloud-native/container-toolkit/install-guide.html
distribution=$(. /etc/os-release;echo $ID$VERSION_ID) \
&& curl -fsSL https://nvidia.github.io/libnvidia-container/gpgkey | sudo gpg --dearmor -o /usr/share/keyrings/nvidia-container-toolkit-keyring.gpg \
&& curl -s -L https://nvidia.github.io/libnvidia-container/$distribution/libnvidia-container.list | \
sed 's#deb https://#deb [signed-by=/usr/share/keyrings/nvidia-container-toolkit-keyring.gpg] https://#g' | \
sudo tee /etc/apt/sources.list.d/nvidia-container-toolkit.list
sudo apt-get update
sudo apt-get install -y nvidia-container-toolkit
sudo nvidia-ctk runtime configure --runtime=docker
sudo systemctl restart docker
sudo docker run --rm --runtime=nvidia --gpus all nvidia/cuda:12.2.0-runtime-ubuntu22.04 nvidia-smi
# If nvcc and build tools are needed, use nvidia/cuda:12.2.0-devel-ubuntu22.04
# Fix screen on wsl by adding this to .bashrc:
if [ ! -d "/run/screen" ]; then
sudo mkdir -p /run/screen
sudo chmod 777 /run/screen
fi