我目前正在使用 Manjaro。
当我运行时hashcat
,出现以下错误:
clGetPlatformIDs(): CL_PLATFORM_NOT_FOUND_KHR
运行hashcat
withsudo
会出现相同的错误。
在 google 上搜索了该错误后,我发现这通常是 NVIDIA 显卡的驱动程序问题,因此我尝试了一些驱动程序问题。
这是我的 NVIDIA 信息:
$ lspci -v | grep -i nvidia
01:00.0 3D controller: NVIDIA Corporation GP107M [GeForce GTX 1050 Mobile] (rev a1)
Kernel driver in use: nvidia
Kernel modules: nouveau, nvidia_drm, nvidia
尝试使用安装驱动程序时mhwd
,出现以下错误:
$ sudo mhwd -a pci nonfree 0300
> Skipping already installed config 'video-hybrid-intel-nvidia-440xx-prime' for device: 0000:00:02.0 (0300:8086:591b) Display controller Intel Corporation HD Graphics 630
我检查了我安装的驱动程序并确认它已安装:
$ pacman -Qs nvidia
local/lib32-nvidia-440xx-utils 440.64-1
NVIDIA drivers utilities (32-bit)
local/libvdpau 1.3-1
Nvidia VDPAU library
local/linux54-nvidia-440xx 440.64-2 (linux54-extramodules)
NVIDIA drivers for linux.
local/mhwd-nvidia-340xx 340.108-1
MHWD module-ids for nvidia 340.108
local/mhwd-nvidia-390xx 390.132-1
MHWD module-ids for nvidia 390.132
local/mhwd-nvidia-418xx 418.113-1
MHWD module-ids for nvidia-418xx 418.113
local/mhwd-nvidia-430xx 430.64-1.0
MHWD module-ids for nvidia-430xx 430.64
local/mhwd-nvidia-435xx 435.21-1.0
MHWD module-ids for nvidia 435.21
local/mhwd-nvidia-440xx 440.64-1
MHWD module-ids for nvidia 440.64
local/nvidia-440xx-utils 440.64-1
NVIDIA drivers utilities
local/nvidia-prime 1.0-1
NVIDIA Prime Render Offload configuration and utilities
当我尝试卸载看似不必要的驱动程序时,出现依赖错误:
$ sudo pacman -Rns local/mhwd-nvidia-340xx local/mhwd-nvidia-390xx local/mhwd-nvidia-418xx local/mhwd-nvidia-430xx local/mhwd-nvidia-435xx
checking dependencies...
error: failed to prepare transaction (could not satisfy dependencies)
:: removing mhwd-nvidia-340xx breaks dependency 'mhwd-nvidia-340xx' required by mhwd-db
:: removing mhwd-nvidia-390xx breaks dependency 'mhwd-nvidia-390xx' required by mhwd-db
:: removing mhwd-nvidia-418xx breaks dependency 'mhwd-nvidia-418xx' required by mhwd-db
:: removing mhwd-nvidia-430xx breaks dependency 'mhwd-nvidia-430xx' required by mhwd-db
:: removing mhwd-nvidia-435xx breaks dependency 'mhwd-nvidia-435xx' required by mhwd-db
当然mhwd-db
是不能卸载的,因为mhwd
。
我查了一下nvidia-settings
,但不知道我到底应该在这里做什么。
我也看到过提到bumblebee
但我不确定是否应该使用它。
我该如何修复该错误clGetPlatformIDs(): CL_PLATFORM_NOT_FOUND_KHR
?
答案1
我知道这是一个很晚的答案,但我也遇到了同样的问题,而且我刚刚能够解决它。
要运行 hascat,您需要 OpenCL 和 CUDA(如果您的 GPU 支持)。我有一个 RTX 2070,安装 cuda 时:
sudo pacman -S cuda
我可以选择为我安装的驱动程序设计的 opencl 软件包。我安装了 455.x 版本的驱动程序,因此我选择了 opencl_nvidia-455xx 选项。
安装opencl和cuda后一切正常。