Error when trying to install Julia on Google Colaboratory

I am trying to install Julia on Google Colaboratory and getting the following error

Updating `~/.julia/environments/v1.0/Project.toml`
  [3a865a2d] + CuArrays v0.9.1
  Updating `~/.julia/environments/v1.0/Manifest.toml`
  [621f4979] + AbstractFFTs v0.3.2
  [79e6a3ab] + Adapt v0.4.2
  [9e28174c] + BinDeps v0.8.10
  [3895d2a7] + CUDAapi v0.6.0
  [c5f51814] + CUDAdrv v1.0.1
  [be33ccc6] + CUDAnative v1.0.1
  [bbf7d656] + CommonSubexpressions v0.2.0
  [3a865a2d] + CuArrays v0.9.1
  [163ba53b] + DiffResults v0.0.4
  [b552c78f] + DiffRules v0.0.10
  [7a1cc6ca] + FFTW v0.2.4
  [1a297f60] + FillArrays v0.4.0
  [f6369f11] + ForwardDiff v0.10.3
  [0c68f7d7] + GPUArrays v0.6.1
  [929cbde3] + LLVM v1.0.0
  [1914dd2f] + MacroTools v0.4.5
  [872c559c] + NNlib v0.4.3
  [77ba4419] + NaNMath v0.3.2
  [189a3867] + Reexport v0.2.0
  [ae029012] + Requires v0.5.2
  [276daf66] + SpecialFunctions v0.7.2
  [90137ffa] + StaticArrays v0.10.3
  [30578b45] + URIParser v0.4.0
  Building SpecialFunctions β†’ `~/.julia/packages/SpecialFunctions/fvheQ/deps/build.log`
  Building CUDAdrv ─────────→ `~/.julia/packages/CUDAdrv/JWljj/deps/build.log`
  Building LLVM ────────────→ `~/.julia/packages/LLVM/tPWXv/deps/build.log`
  Building CUDAnative ──────→ `~/.julia/packages/CUDAnative/Mdd3w/deps/build.log`
β”Œ Error: Error building `CUDAnative`: 
β”‚ CUDA 10.1 is not supported by
β”‚ your driver (which supports up to 10.0).
β”‚ 
β”‚ This is not a fatal error, but GPU functionality will be unavailable.
β”‚ If you expected this to work, please open a thread on
β”‚ https://discourse.julialang.org/c/domain/gpu
β”” @ Pkg.Operations /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Operations.jl:1068
  Building FFTW ────────────→ `~/.julia/packages/FFTW/p7sLQ/deps/build.log`
  Building CuArrays ────────→ `~/.julia/packages/CuArrays/PD3UJ/deps/build.log`
β”Œ Error: Error building `CuArrays`: 
β”‚ Dependent package CUDAnative.jl has not been built successfully
β”” @ Pkg.Operations /buildworker/worker/package_linux64/build/usr/share/julia/stdlib/v1.0/Pkg/src/Operations.jl:1068 
...

Is there a way to overcome this issue?
Thank you

CUDAapi.jl needs to be updated for CUDA 10.1: Updates for CUDA 10.1 by maleadt Β· Pull Request #67 Β· JuliaGPU/CUDAapi.jl Β· GitHub

1 Like

Great! Thank you very much.

@maleadt would it be possible to add the likely next version changes (the present case being likely from 10.1 to 10.2 or 11.0) since I believe that the CUDA versions available are hardcoded in CUDAapi.jl and it is difficult to change this approach?

Other information, such as the supported devices and PTX ISAs, or the supported host compilers, also change with every CUDA version so it’s probably not worth doing so.

Im having this problem again. Just 6 hours ago this worked fine.

Precompiling CuArrays
ERROR: LoadError: CUDA 10.2 is not supported by
your driver (which supports up to 10.1)
Stacktrace:
 [1] error(::String) at ./error.jl:33
 [2] cuda_support(::VersionNumber, ::VersionNumber) at /root/.julia/packages/CUDAnative/Lr0yj/src/CUDAnative.jl:53
 [3] top-level scope at /root/.julia/packages/CUDAnative/Lr0yj/src/CUDAnative.jl:93
 [4] include at ./boot.jl:328 [inlined]
 [5] include_relative(::Module, ::String) at ./loading.jl:1094
 [6] include(::Module, ::String) at ./Base.jl:31
 [7] top-level scope at none:2
 [8] eval at ./boot.jl:330 [inlined]
 [9] eval(::Expr) at ./client.jl:432
 [10] top-level scope at ./none:3
in expression starting at /root/.julia/packages/CUDAnative/Lr0yj/src/CUDAnative.jl:72
ERROR: LoadError: Failed to precompile CUDAnative [be33ccc6-a3ff-5ff2-a52e-74243cff1e17] to /root/.julia/compiled/v1.2/CUDAnative/4Zu2W.ji.
Stacktrace:
 [1] error(::String) at ./error.jl:33
 [2] compilecache(::Base.PkgId, ::String) at ./loading.jl:1253
 [3] _require(::Base.PkgId) at ./loading.jl:1013
 [4] require(::Base.PkgId) at ./loading.jl:911
 [5] require(::Module, ::Symbol) at ./loading.jl:906
 [6] include at ./boot.jl:328 [inlined]
 [7] include_relative(::Module, ::String) at ./loading.jl:1094
 [8] include(::Module, ::String) at ./Base.jl:31
 [9] top-level scope at none:2
 [10] eval at ./boot.jl:330 [inlined]
 [11] eval(::Expr) at ./client.jl:432
 [12] top-level scope at ./none:3
in expression starting at /root/.julia/packages/CuArrays/PwSdF/src/CuArrays.jl:5

You probably upgraded your CUDA toolkit without upgrading your driver. This is generally not a supported situation. That said, I’ve demoted the error to a warning on the latest CUDAnative, so try upgrading your packages.

I am also having the same problem can you just help me with the code for doing so?

There is no code to fix your system, upgrading your CUDA driver depends on your operating system. Furthermore, on the latest version of CUDAnative this should not be a fatal error anymore, just a warning. You can also try out Request for testing: CUDA from BinaryBuilder where a matching CUDA toolkit will be installed automatically.