首页 > 解决方案 > 如何更新 NVIDIA 驱动程序,尤其是针对 Google Colab 上的 OpenCL?

问题描述

您可以在 Google Colaboratory 上使用 T4、P100(以及 K80)等 GPU。但是,默认的 OpenCL 驱动程序不支持半精度功能。我想使用它们。

最新的驱动程序是否启用了它们?以及如何在 Google Colaboratory 上更新 NVIDIA 驱动程序?

以下是我尝试过的。

我从 NVIDIA 网站下载了最新的驱动程序 (XXX.run),然后

!apt remove nvidia-*
# reboot by runtime menu
sh XXX.run

但我得到了

ERROR: An NVIDIA kernel module 'nvidia-uvm' appears to already be loaded in  
        your kernel.  This may be because it is in use (for example, by an X  
        server, a CUDA program, or the NVIDIA Persistence Daemon), but this   
        may also happen if your kernel was configured without support for     
        module unloading.  Please be sure to exit any programs that may be    
        using the GPU(s) before attempting to upgrade your driver.  If no     
        GPU-based programs are running, you know that your kernel supports    
        module unloading, and you still receive this message, then an error   
        may have occured that has corrupted an NVIDIA kernel module's usage   
        count, for which the simplest remedy is to reboot your computer.      

我也失败了rmmod nvidia-uvm

rmmod: ERROR: ../libkmod/libkmod.c:514 lookup_builtin_file() could not open builtin file '/lib/modules/4.14.137+/modules.builtin.bin'
rmmod: ERROR: ../libkmod/libkmod-module.c:793 kmod_module_remove_module() could not remove 'nvidia_uvm': Operation not permitted
rmmod: ERROR: could not remove module nvidia-uvm: Operation not permitted

标签: linuxnvidiagoogle-colaboratory

解决方案


推荐阅读