unfortunately I see the same issues with this driver as I see with 510.06 if I try to run under WSL2 the call to cuInit() returns CUDA_ERROR_OUT_OF_MEMORY. Running the same app under windows 11 I have no issues. The system have 32GB of ram.
I’m also getting the same issue with driver 497.29 as I stated here even after I followed this advice i.e. to download and install the driver from this link. Namely, the following hello world CUDA code compiles but does not print from the kernel if on WSL:
I just tried CUDA 11.6 with the new driver it comes with on wsl2. But unfortunately I still get the same error on cuInit(0). At the time I run this test there were more than 10GB ram available - I hope this would be OK?
I run Windows 11 and VS2022 with all updates. I have WSL2 - Ubuntu 18.04LTS. I installed cuda 11.6 for windows with the driver that comes with the package. Then I installed cuda for linux ( CUDA Toolkit 11.6 Downloads | NVIDIA Developer) - following the guides step-by-step. No issues during install - neither on windows nor on linux. All went fine.
We could not reproduce the issue at our end. The cuda samples run to completion on WSL2.
May be you are already doing this, but to be sure -specifically, please pick up the CUDA 11.6 toolkit installation provided for WSL2. As stated in the guide, by default the toolkit will override the underlying windows driver which is exported into WSL2 environment, hence clobbering your setup.