CUDA for video: How to figure out the right PATH to make it work?

ive been trying to figure out how to make cuda be detected properly and work in manjaro without luck. I have also read similar threads, having found little useful information.

So far, from what ive read (in threads of guys trying to make cuda work with Mathematica and Davinci Resolve), i think that maybe i need to create symlinks, or set the PATH in the ".bashrc" file, so cuda is recognized. I ignore which is the right way to do this (what i need to write or change). The main reason i want to be able to use cuda is to work with Davinci Resolve, Blender and any other program that could use it.

I originally had bumblebee drivers, but after asking I then switched to 390xx + optimus manager, and now im using 430.40. i installed, removed, reinstalled cuda each time, but nothing changed. I have been able to run steam games in both the linux client, and the windows client using lutris, so i will keep the 430 driver since its the most current.

This is information about my system ("inxi -Fxxxz"):

System:    Host: xxx Kernel: 4.19.66-1-MANJARO x86_64 bits: 64 compiler: gcc v: 9.1.0 Desktop: KDE Plasma 5.16.4 
           tk: Qt 5.13.0 wm: kwin_x11 dm: SDDM Distro: Manjaro Linux 
Machine:   Type: Laptop System: ASUSTeK product: N56VB v: 1.0 serial: <filter> 
           Mobo: ASUSTeK model: N56VB v: 1.0 serial: <filter> UEFI: American Megatrends v: N56VB.202 date: 01/21/2013 
Battery:   ID-1: BAT0 charge: 18.0 Wh condition: 19.8/57.7 Wh (34%) volts: 11.1/11.1 model: ASUSTeK N56--52 type: Li-ion 
           serial: <filter> status: Unknown cycles: 577 
CPU:       Topology: Quad Core model: Intel Core i7-3630QM bits: 64 type: MT MCP arch: Ivy Bridge rev: 9 L2 cache: 6144 KiB 
           flags: avx lm nx pae sse sse2 sse3 sse4_1 sse4_2 ssse3 vmx bogomips: 38333 
           Speed: 1426 MHz min/max: 1200/3400 MHz Core speeds (MHz): 1: 1426 2: 1407 3: 1397 4: 1265 5: 1258 6: 1649 7: 2282 
           8: 1368 
Graphics:  Device-1: Intel 3rd Gen Core processor Graphics vendor: ASUSTeK driver: i915 v: kernel bus ID: 00:02.0 
           chip ID: 8086:0166 
           Device-2: NVIDIA GK107M [GeForce GT 740M] vendor: ASUSTeK driver: nvidia v: 430.40 bus ID: 01:00.0 
           chip ID: 10de:0fdf 
           Display: x11 server: X.Org 1.20.5 driver: modesetting,nvidia compositor: kwin_x11 resolution: 1920x1080~60Hz 
           OpenGL: renderer: GeForce GT 740M/PCIe/SSE2 v: 4.6.0 NVIDIA 430.40 direct render: Yes 
Audio:     Device-1: Intel 7 Series/C216 Family High Definition Audio vendor: ASUSTeK N56VZ driver: snd_hda_intel v: kernel 
           bus ID: 00:1b.0 chip ID: 8086:1e20 
           Sound Server: ALSA v: k4.19.66-1-MANJARO 
Network:   Device-1: Intel Centrino Wireless-N 2230 driver: iwlwifi v: kernel port: e000 bus ID: 03:00.0 chip ID: 8086:0887 
           IF: wlp3s0 state: down mac: <filter> 
           Device-2: Qualcomm Atheros AR8161 Gigabit Ethernet vendor: ASUSTeK N56VZ driver: alx v: kernel port: d000 
           bus ID: 04:00.0 chip ID: 1969:1091 
           IF: enp4s0 state: up speed: 100 Mbps duplex: full mac: <filter> 
Drives:    Local Storage: total: 1.03 TiB used: 316.15 GiB (30.1%) 
           ID-1: /dev/sda vendor: Corsair model: Neutron SSD size: 119.24 GiB speed: 6.0 Gb/s serial: <filter> rev: M306 
           scheme: GPT 
           ID-2: /dev/sdb vendor: HGST (Hitachi) model: HTS541010A9E680 size: 931.51 GiB speed: 3.0 Gb/s rotation: 5400 rpm 
           serial: <filter> rev: A560 scheme: GPT 
Partition: ID-1: / size: 116.58 GiB used: 83.97 GiB (72.0%) fs: ext4 dev: /dev/sda2 
Sensors:   System Temperatures: cpu: 60.0 C mobo: N/A gpu: nvidia temp: 56 C 
           Fan Speeds (RPM): cpu: 2500 
Info:      Processes: 351 Uptime: 2d 21h 57m Memory: 15.55 GiB used: 11.29 GiB (72.6%) Init: systemd v: 242 Compilers: 
           gcc: 9.1.0 alt: 8 clang: 8.0.1 Shell: bash v: 5.0.7 running in: konsole inxi: 3.0.35 

nvidia stuff:

lspci
00:00.0 Host bridge: Intel Corporation 3rd Gen Core processor DRAM Controller (rev 09)
00:01.0 PCI bridge: Intel Corporation Xeon E3-1200 v2/3rd Gen Core processor PCI Express Root Port (rev 09)
00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor Graphics Controller (rev 09)
00:14.0 USB controller: Intel Corporation 7 Series/C210 Series Chipset Family USB xHCI Host Controller (rev 04)
00:16.0 Communication controller: Intel Corporation 7 Series/C216 Chipset Family MEI Controller #1 (rev 04)
00:1a.0 USB controller: Intel Corporation 7 Series/C216 Chipset Family USB Enhanced Host Controller #2 (rev 04)
00:1b.0 Audio device: Intel Corporation 7 Series/C216 Chipset Family High Definition Audio Controller (rev 04)
00:1c.0 PCI bridge: Intel Corporation 7 Series/C216 Chipset Family PCI Express Root Port 1 (rev c4)
00:1c.1 PCI bridge: Intel Corporation 7 Series/C210 Series Chipset Family PCI Express Root Port 2 (rev c4)
00:1c.3 PCI bridge: Intel Corporation 7 Series/C216 Chipset Family PCI Express Root Port 4 (rev c4)
00:1d.0 USB controller: Intel Corporation 7 Series/C216 Chipset Family USB Enhanced Host Controller #1 (rev 04)
00:1f.0 ISA bridge: Intel Corporation HM76 Express Chipset LPC Controller (rev 04)
00:1f.2 SATA controller: Intel Corporation 7 Series Chipset Family 6-port SATA Controller [AHCI mode] (rev 04)
00:1f.3 SMBus: Intel Corporation 7 Series/C216 Chipset Family SMBus Controller (rev 04)
01:00.0 3D controller: NVIDIA Corporation GK107M [GeForce GT 740M] (rev a1)
03:00.0 Network controller: Intel Corporation Centrino Wireless-N 2230 (rev c4)
04:00.0 Ethernet controller: Qualcomm Atheros AR8161 Gigabit Ethernet (rev 10)
$ lspci -k | grep -A 2 -i "VGA"
00:02.0 VGA compatible controller: Intel Corporation 3rd Gen Core processor Graphics Controller (rev 09)
        Subsystem: ASUSTeK Computer Inc. 3rd Gen Core processor Graphics Controller
        Kernel driver in use: i915
$ modinfo nvidia
filename:       /lib/modules/4.19.66-1-MANJARO/extramodules/nvidia.ko.gz
alias:          char-major-195-*
version:        430.40
supported:      external
license:        NVIDIA
srcversion:     B9960A7E9AD113F15C3277E
alias:          pci:v000010DEd00000E00sv*sd*bc04sc80i00*
alias:          pci:v000010DEd*sv*sd*bc03sc02i00*
alias:          pci:v000010DEd*sv*sd*bc03sc00i00*
depends:        ipmi_msghandler
retpoline:      Y
name:           nvidia
vermagic:       4.19.66-1-MANJARO SMP preempt mod_unload modversions 
parm:           NvSwitchRegDwords:NvSwitch regkey (charp)
parm:           NVreg_Mobile:int
parm:           NVreg_ResmanDebugLevel:int
parm:           NVreg_RmLogonRC:int
parm:           NVreg_ModifyDeviceFiles:int
parm:           NVreg_DeviceFileUID:int
parm:           NVreg_DeviceFileGID:int
parm:           NVreg_DeviceFileMode:int
parm:           NVreg_InitializeSystemMemoryAllocations:int
parm:           NVreg_UsePageAttributeTable:int
parm:           NVreg_MapRegistersEarly:int
parm:           NVreg_RegisterForACPIEvents:int
parm:           NVreg_EnablePCIeGen3:int
parm:           NVreg_EnableMSI:int
parm:           NVreg_TCEBypassMode:int
parm:           NVreg_EnableStreamMemOPs:int
parm:           NVreg_EnableBacklightHandler:int
parm:           NVreg_RestrictProfilingToAdminUsers:int
parm:           NVreg_PreserveVideoMemoryAllocations:int
parm:           NVreg_DynamicPowerManagement:int
parm:           NVreg_EnableUserNUMAManagement:int
parm:           NVreg_MemoryPoolSize:int
parm:           NVreg_KMallocHeapMaxSize:int
parm:           NVreg_VMallocHeapMaxSize:int
parm:           NVreg_IgnoreMMIOCheck:int
parm:           NVreg_NvLinkDisable:int
parm:           NVreg_RegistryDwords:charp
parm:           NVreg_RegistryDwordsPerDevice:charp
parm:           NVreg_RmMsg:charp
parm:           NVreg_GpuBlacklist:charp
parm:           NVreg_TemporaryFilePath:charp
parm:           NVreg_AssignGpus:charp

incomplete information when running "nvidia-smi" (any ideas why this happens and what i means?):

+-----------------------------------------------------------------------------+
| NVIDIA-SMI 430.40       Driver Version: 430.40       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GT 740M     Off  | 00000000:01:00.0 N/A |                  N/A |
| N/A   56C    P0    N/A /  N/A |    461MiB /  2002MiB |     N/A      Default |
+-------------------------------+----------------------+----------------------+
                                                                               
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID   Type   Process name                             Usage      |
|=============================================================================|
|    0                    Not Supported                                       |
+-----------------------------------------------------------------------------+

gcc version (i read in the wiki pages about cuda that its important to check it):

$ gcc --version
gcc (GCC) 9.1.0
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

This is what happens when i try to install cuda-z:

$ yay-S cuda-z
...
==> Sources are ready.
==> Making package: cuda-z 0.10-1 (Wed 21 Aug 2019 05:37:47 PM CDT)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> WARNING: Using existing $srcdir/ tree
==> Starting build()...
Info: creating stash file /home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10/.qmake.stash
perl /home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10/bld/bin/make_build_svn.pl /home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10/src/build.h /home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10
svn: E155007: '/home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10' is not a working copy
/usr/bin/uic ui/czdialog.ui -o bld/ui/ui_czdialog.h
nvcc -Xcompiler -pipe,-frtti,-Wall,-W -gencode=arch=compute_20,code=sm_20 -gencode=arch=compute_20,code=compute_20 -gencode=arch=compute_30,code=sm_30 -gencode=arch=compute_30,code=compute_30 -gencode arch=compute_32,code=sm_32 -gencode arch=compute_32,code=compute_32 -gencode=arch=compute_35,code=sm_35 -gencode=arch=compute_35,code=compute_35 -gencode=arch=compute_37,code=sm_37 -gencode=arch=compute_37,code=compute_37 -gencode arch=compute_50,code=sm_50 -gencode arch=compute_50,code=compute_50 -gencode arch=compute_52,code=sm_52 -gencode arch=compute_52,code=compute_52 -DQT_NO_DEBUG -DQT_WIDGETS_LIB -DQT_GUI_LIB -DQT_NETWORK_LIB -DQT_CORE_LIB -c -o /home/xxx/.cache/yay/cuda-z/src/cuda-z-0.10/bld/o/cudainfo.o src/cudainfo.cu
nvcc fatal   : Unsupported gpu architecture 'compute_20'
make: *** [Makefile:960: bld/o/cudainfo.o] Error 1
==> ERROR: A failure occurred in build().
    Aborting...
Error making: cuda-z

So, long story short: how can i check which is the PATH expected by each program to find all cuda related files, and how i should create the symlinks or update PATH so everything works without issues?

1 Like

please dont post terminal output as screenshots, they are not searchable and harder to read.

2 Likes

i'm not too familiar with cuda, but the make is failing because the architecture doesnt match yours. you should be able to edit the makefile.config to correct it.


"The 'compute_20', 'sm_20', and 'sm_21' architectures are deprecated in CUDA 8 & 9"

if you search the error your getting you should find what you need

Could you guide me a bit to do that? i guess that could solve the problem with installing cuda-z, but i still need to find out how to check which is the address davinci resolve is expecting for the cuda files and how i should fix it.

as i wrote earlier, the only ideas i currently think may help is to either point the address in ".bashrc" in relation to a similar issue in a thread about "cuda not working in mathematica", and making symlink to the files (sometimes programs seem to be looking for cuda in an addresses that are common in ubuntu, but that are different in manjaro and arch).

maybe someone else more familiar than myself with cuda (which is just about anyone). you should be able to find what you need with some searching here or the arch wiki .

https://wiki.archlinux.org/index.php/DaVinci_Resolve

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.

Forum kindly sponsored by