Hello,
I have just installed Manjaro over the past week or so and I’m hitting this as a major issue in terms of usability, unfortunately. I have went on the freenode #manjaro channel so that is logged in case I miss any details. My dedicated GPU is a NVIDIA 2060 Super, the integrated GPU is an Intel UHD 630. Manjaro, at the time of writing, has been updated today. From the about screen:
Operating System: Manjaro Linux
KDE Plasma Version: 5.22.4
KDE Frameworks Version: 5.84.0
Qt Version: 5.15.2
Kernel Version: 5.13.8-1-MANJARO (64-bit)
Graphics Platform: X11
Processors: 16 × Intel® Core™ i7-10700K CPU @ 3.80GHz
Memory: 31.2 GiB of RAM
Graphics Processor: Mesa Intel® UHD Graphics 630
Firefox under about:support says it’s utilizing the Intel card. No big deal. But when I need or want to use something more intensive, in my case Retroarch, I can tell the NVIDIA card is not in use as the program lags badly. First instinct was to open nvidia-settings and try to switch the dedicated GPU. I should mention I’ve used Ubuntu for some time and with the PPA drivers as of recently I was able to change the dedicated GPU. Here, I see no options under any section of the application to change between on demand, power saving (integrated), and performance (NVIDIA). I also saw no way to override per application. I have attempted to remove the automatically configured proprietary NVIDIA drivers and replace them with the ones from NVIDIA’s website. Unfortunately this resulted in a black screen and I had to remove that and reinstall the ones that are bundled in. So I’m at a loss to as what to do to switch GPUs. Also, I have tried optimus-manager and it crashed on starting. It also isn’t meant for this type of NVIDIA card. So any suggestions are appreciated.
Thanks. Any way to make it permanent per application when necessary? EDIT: Figured out how to make it run with a flatpak. Overthought the command. Another thing is I tried editing it via right clicking the entry in the KDE application launcher and when I put prime-run before the command box in the application tab, it says “insufficient write access”.
So prime-run then the flatpak command works via terminal, but I followed the instructions for the marked solution by searching Duckduckgo and typing in “Could not save properties due to insufficient write access to: .local/share/applications/” without quotes (sorry I cannot post links yet) and clicking the first result. Now even with that workaround, it still runs with the integrated GPU. Weird.
But it is,optimus-manager is the equivalent of switching GPUs as in Ubuntu.
Make sure you install optimus manager and do this
Manjaro ships with a default configuration for SDDM (the default login manager for KDE) which overrides some keys needed by optimus-manager. To use optimus-manager, you need to edit the file /etc/sddm.conf and simply put a # before the line starting with DisplayCommand and the one starting with DisplayStopCommand .
I don’t know how flatpak works,but I know Retroarch from the official repositories can detect the nvidia card automatically,you only need to tell retroarch to use it instead of the iGPU,no need to do prime-run
Is in Video > Output > GPU Index,change to your nvidia card,also select Video to Vulkan,restart retroarch and it should run your nvidia card,you can tell by typing the command
nvidia-smi
In there,there should be a retroarch process.
❯ nvidia-smi
Sun Aug 15 21:04:36 2021
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 470.63.01 Driver Version: 470.63.01 CUDA Version: 11.4 |
|-------------------------------+----------------------+----------------------+
| GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|===============================+======================+======================|
| 0 NVIDIA GeForce ... Off | 00000000:01:00.0 Off | N/A |
| N/A 49C P0 N/A / N/A | 85MiB / 4040MiB | 3% Default |
| | | N/A |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=============================================================================|
| 0 N/A N/A 159976 C+G retroarch 82MiB |
+-----------------------------------------------------------------------------+
Well I figured out optimus-manager by your instructions and my own reading of the --help output. Thanks. And I was concerned about switching to vulkan as on Ubuntu it crashed RetroArch. Here it doesn’t. Thank you!