Please, could you help me. I’m absolute newbie. I came into Linux due to its support for older machines to get my Asus UL80VT G210M working. I can’t upgrade it, nor throw it away. And I need working descrete card. No other distro users seemed to be able to launch nvidia340 or cared trying, not to mention Manjaro’s great community.
I installed Manjaro GNOME 21.2rc1, disabled Wayland to get past black screen, installed 5.4 kernel and removed 5.15. Then I followed these instructions:
and got white screen with an error.
Then I tried sudo nvidia-xconfig and was able to get into the text mode. My /etc/modprobe.d/ was empty and /etc/modules-load.d/ did not contain nvidia.conf. So i created them manually and also added the said commands to the modules.cong in /etc/modprobe.d/ with no visible effect.
Then i found a thread and added Option “IgnoreABI” to Section “ServerFlags” to generated xorg.conf and my keyboard or a text mode stopped working.
Wow! I didn’t expect someone would address my question that fast Thank you!
With every attempt I do clean reinstall. This time I installed kernel 5.10, followed the instructions and generated xorg.conf. Didn’t reboot so I could stay in a graphical mode.
So, actually, both are working. The iGPU Intel is there as Main and the dGPU as Sink.
Both are working KMS:
[ 40.950] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[ 40.950] (II) modeset(0): using drv /dev/dri/card0
[ 40.951] (II) modeset(G0): using drv /dev/dri/card1
GLX should be switchable with:
glxinfo | grep "OpenGL renderer"
DRI_PRIME=1 glxinfo | grep "OpenGL renderer"
If your really need this driver then…
install the driver again like described…
Add the config to blacklist the nouveau driver for the nvidia card:
File: /etc/modprobe.d/blacklist.conf
blacklist nouveau
blacklist ttm
blacklist drm_kms_helper
blacklist drm
Reboot now. It should load the driver on the next boot. Before rebooting, keep sure there is no xorg config set for nvidia like this here:
sudo rm -f /etc/X11/xorg.conf
It would try to load the nvidia driver, but could possibly crash.
So now the driver should be loaded. You should see now nvidia as driver instead of nouveau in inxi. Check it with:
inxi -Gazy
I am not sure, but I guess 340xx also should be able to offload GLX to the nvidia gpu with:
glxinfo | grep "OpenGL renderer"
prime-run glxinfo | grep "OpenGL renderer"
(install it, if not done: pamac install nvidia-prime mesa-utils )
To enable the GPU output for a second screen, a special xorg config is needed for the nvidia driver. But don’t know what you expect. So GPU offloading should be working this way, without a xorg config.
Well, I groundlessly beleived this driver would help me run certain applications. I’m in a text mode again. Probably I should give up on nvidia after days of trying. Thank you for your help.
Also: Stay on Kernel 5.4 for this driver… but possibly the nvidia driver does not support the X-Server at this Version. Idk Thats the reason, why I said to skip the xorg.conf of nvidia and stay with the intel opensource driver as main. So no xorg configs.
I removed /etc/X11/xorg.conf
but where to should I add these lines
to /etc/X11/mhwd.d/nvidia.conf ?
If there is no such file should I create it?
Should it be the only contents of this file?
Should the value be “1” or “true”?
mhwd -li -d # to list basic information of all the drivers currently installed on your system
sudo mhwd -r [pci or usb] [name of driver] # to remove an installed driver
Example sudo mhwd -r pci video-nvidia to remove nvidia driver.
Or if its not problem to you, you could reinstall the system and we can start from beginning. I found an old tutorial that might help you, not sure though
To build the driver use pamac GUI. Hit ‘edit build files’ clear the PKGBUILD from the AUR and replace with:
and change line 9 pkgrel=1 to the appropriate version, currently 26.
Whenever there is a big update check if nvidia-340xx-dkms is part of it and do that first, then do the rest (with possible kernel updates) with pamac upgrade -a.
Stay on Kernel 5.4 for this driver
As you can see around line 20 there are patches for 5.7 -5.10, so the 5.10 is probably the only kernel you should try this with (The original PKGBUILD differs by offering patches up to 5.15. As soon as I’m back from hols I’ll try to build the driver using this adapted version of philm’s file; if that works I’ll try installing 5.15, if not don’t laugh, I’m no coder but I like trying things out… :
I know your hardware is different but if i can help with more info on this just ask.
I also would like to thank all the people who came up with this solution, you have saved a lot of perfectly working hardware from the ever growing electronics scrap heap (I live in Nairobi, 5km from: dandora dump electronic at DuckDuckGo ).
As an afterthought; I’d recon package maintainers who keep old hardware alive would be eligible for funding through one of the environmental grants that most ‘western’ governments increasingly offer, I wonder if someone has ever tried applying, I’m a photographer and happy to provide high impact images from Dandora dump site for an application.
except for compiling packages, which I did as mentioned by you:
I found option to turn on AUR in a pamac manager preferences and to edit pkgbuild.
I built it on a 5.10 kernel.
Then I made some adjustments as was mentioned by @megavolt and you
but again I was only able to run Manjaro in a text mode
Ok, so start from scratch. Reinstall the system with free drivers option.
Make sure you are on kernel 5.4 LTS or 5.10 LTS.
Follow this tutorial.
On step 1 of the tutorial uninstall the free drivers via mhwd DO NOT REBOOT!
On step 2 install the nvidia drivers via
git clone https://gitlab.manjaro.org/packages/extra/nvidia-340xx-utils.git
git clone https://gitlab.manjaro.org/packages/multilib/lib32-nvidia-340xx-utils.git
git clone https://github.com/philmmanjaro/nvidia-340xx-dkms.git
cd nvidia-340xx-utils && makepkg -si
cd ../lib32-nvidia-340xx-utils && makepkg -si
cd ../nvidia-340xx-dkms && makepkg -si
Or via pamac AUR if you wish to be on kernel 5.10 LTS.(You mentioned you know how to do that)
DO NOT REBOOT!
3. Follow the rest of the tutorial as it says.
On step 5 where it says For GDM you will do only that, not the others. Since you mentioned you are on GNOME.
Again DO NOT REBOOT!
If you finished the tutorial you will have this file /etc/X11/xorg.conf.d/optimus.conf
Open the file and add this at the bottom