Bug 31845 - After installing Nvidia driver 470 for GTX660, Mageia always changes back to nouveau
Summary: After installing Nvidia driver 470 for GTX660, Mageia always changes back to ...
Status: RESOLVED FIXED
Alias: None
Product: Mageia
Classification: Unclassified
Component: RPM Packages (show other bugs)
Version: Cauldron
Hardware: x86_64 Linux
Priority: Normal normal
Target Milestone: ---
Assignee: Kernel and Drivers maintainers
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-04-27 15:59 CEST by Uli Selle
Modified: 2023-05-25 23:16 CEST (History)
4 users (show)

See Also:
Source RPM: drakxtools
CVE:
Status comment:


Attachments

Description Uli Selle 2023-04-27 15:59:54 CEST
Description of problem:
After upgrading Mageia8 to Mageia 9Beta the X11 Nvidia Driver had changed to nouveau.
With drakx11 i installed the nvidia driver again (NVIDIA GeForce 635 to GeForce 920 / 470.182.03-2.mga9.nonfree). This seems to sccseed, but requires a reboot.
After reboot there is nouveau installed and activated again.

Version-Release number of selected component (if applicable):
470.182.03-2.mga9.nonfree
Im using KDE Plasma

How reproducible:
After every reboot

Steps to Reproduce:
1. Start mageia and log in to Plasma
2. Now Nouveau is active
3. Logout to SDDM and change with (Strg+Alt+F2) to a shell
4. In the shell login as root
5. Start drakx11
6. Choose "NVIDIA GeForce 635 to GeForce 920" as driver for graphic card
7. After ok the system tells you that there is a proprietary driver with 3d acceleration
8. Choose this driver, Mageia installs it and requires a reboot
9. After rebooting and logging in to Plasma, the nouveau driver is active again...
Comment 1 sturmvogel 2023-04-27 16:16:26 CEST
(In reply to Uli Selle from comment #0)
> 3. Logout to SDDM and change with (Strg+Alt+F2) to a shell
> 4. In the shell login as root
> 5. Start drakx11
> 6. Choose "NVIDIA GeForce 635 to GeForce 920" as driver for graphic card

Why do you go this way? Did you try to start MCC from your noveau session (as your user) and configure the graphic card via this way...
Comment 2 sturmvogel 2023-04-27 16:19:00 CEST
Other questions:
- which upgrade method did you chose: offline from DVD, online via dnf, online via urpmi, nonfree sources activated, online sources activated at all...
Comment 3 Uli Selle 2023-04-27 18:31:23 CEST
I used "online via urpmi":
1.i deleted all mga8 repositories, then
2. urpmi.addmedia --distrib --mirrorlist http://mirrors.mageia.org/api/mageia.9.x86_64.list
3. urpmi --replacefiles --auto-update --auto --download-all

In this way i updated 4 computers, only this one here had problems.
Activated Core, Nonfree and Tainted sources.

Changing the driver from Plasma/MMC i tried also, with the same effect.
On another computer the graphic card is Geforce 1050Ti the NVIDIA driver is 570.xx.

The older GTX660 on this device here is only supported by the older 470.xx driver.

I choosed the described way for changing the driver because so i succeedet using the nvidia proprietary driver. After change of it, i didn't reboot but logged in as user on the shell an made "startx".
Plasma started with activated nvidia 470.xx.
When rebooting the nouveau is active again :-(
Comment 4 Lewis Smith 2023-04-27 21:05:00 CEST
The problem seems well defined. The upgrade looks correct: "i updated 4 computers, only this one here had problems".

> On another computer the graphic card is Geforce 1050Ti
> the NVIDIA driver is 570.xx
Does this one work correctly? Did it default to nouveau, did you have to re-configure the video driver? Or did it upgrade to the correct Nvidia driver?

(In reply to Uli Selle from comment #3)
> I choosed the described way for changing the driver because so i succeedet
> using the nvidia proprietary driver. After change of it, i didn't reboot but
> logged in as user on the shell an made "startx".
> Plasma started with activated nvidia 470.xx.
> When rebooting the nouveau is active again :-(
To pursue this, please try:
1. Start with the nouveau driver in use.
2. Post the output of:
 $ inxi -Gxx          [with nouveau]
3. Change the video driver to nVidia 470.
4. Logout, do 'startx', login. You say this then uses the nVidia 470 driver.
5. Post the output of:
 $ inxi -Gxx          [with nvidia 470]
6. Reboot
7. Attach to this bug a compressed journal:
 # journalctl --no-hostname -B | xz > journal.txt.xz

CC: (none) => lewyssmith
Summary: After installing Nvidia driver, Mageia always changes back to nouveau => After installing Nvidia driver 470 for GTX660, Mageia always changes back to nouveau

Comment 5 Uli Selle 2023-04-28 04:12:04 CEST
1. Started with the nouveau driver in use.
2. Post the output of:
$ inxi -Gxx          [with nouveau]
-----
Nouveau:
Graphics:
inxi -Gxx
  Device-1: NVIDIA GK106 [GeForce GTX 660] vendor: Micro-Star MSI
    driver: nouveau v: kernel arch: Kepler pcie: speed: 2.5 GT/s lanes: 16
    ports: active: DVI-I-1 empty: DP-1,DVI-D-1,HDMI-A-1 bus-ID: 06:00.0
    chip-ID: 10de:11c0 temp: 26.0 C
  Display: x11 server: X.org v: 1.21.1.8 with: Xwayland v: 22.1.9
    compositor: kwin_x11 driver: X: loaded: nouveau,v4l dri: nouveau
    gpu: nouveau display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1200 s-dpi: 96
  Monitor-1: DVI-I-1 model: LG (GoldStar) 24EB23 res: 1920x1200 dpi: 94
    diag: 616mm (24.2")
  API: OpenGL v: 4.3 Mesa 23.0.3 renderer: NVE6 direct-render: Yes
-----
Then Logged out. But could not log in again, because of the message:
"NVRM: The nvidia probe routine was not called for 1 device(s)."
This message was permanently rerun so that i could not login any more.
Had to restart.
Booting was interrupted by the message:
"The system has to be restarted because of changing the display-driver"
Again restart- this time the system started to sddm.

Logged in, driver is again "nouveau".

Via MCC installed "Nvidia 470" again, then direct deinstalled the "x11-driver-video-nouveau"

Resart again.

Boot to sddm: In front of sddm there is a window with the message: "The display-driver has been automatically changed to 'nvidia'.
Reason: The proprietary kernel-driver could not be found for the 'nvidia' x.org-driver.
Logged in: The message appeared again. I clicked i away, then made:

inxi -Gxx:
Graphics:
  Device-1: NVIDIA GK106 [GeForce GTX 660] vendor: Micro-Star MSI
    driver: nvidia v: 470.182.03 arch: Kepler pcie: speed: 2.5 GT/s lanes: 16
    bus-ID: 06:00.0 chip-ID: 10de:11c0
  Display: x11 server: X.org v: 1.21.1.8 with: Xwayland v: 22.1.9
    compositor: kwin_x11 driver: X: loaded: nvidia,v4l gpu: nvidia
    display-ID: :0 screens: 1
  Screen-1: 0 s-res: 1920x1200 s-dpi: 93
  Monitor-1: DVI-I-1 res: 1920x1200 dpi: 94 diag: 616mm (24.25")
  API: OpenGL v: 4.6.0 NVIDIA 470.182.03 renderer: NVIDIA GeForce GTX
    660/PCIe/SSE2 direct-render: Yes

Now the nvidia 470.xx is active, but i'm afraid it will be changed to nouveau with the next restart...
Comment 6 Uli Selle 2023-04-28 04:19:27 CEST
Sorry, forgot:
- journalctl --no-hostname -B | xz > journal.txt.xz
- journalctl: Ungültige Option -- B
Comment 7 Dave Hodgins 2023-04-28 06:00:40 CEST
Try adding the kernel parameter xdriver=nvidia

CC: (none) => davidwhodgins

Comment 8 Martin Whitaker 2023-04-28 11:29:15 CEST
I believe this bug is occurring because the list of nvidia kernel modules in service_harddrake hasn't been updated to include nvidia470. Please test with harddrake-18.61 when it reaches the mirrors.

Source RPM: (none) => drakxtools
CC: (none) => mageia

Comment 9 Uli Selle 2023-04-28 18:20:44 CEST
After reboot the nvidia 470.xx still was active!
But the message:
"The display-driver has been automatically changed to 'nvidia'.
Reason: The proprietary kernel-driver could not be found for the 'nvidia' x.org-driver." appeared again.

It seems, the system wants to install the nouveau driver although the nvidia is installed and functioning well...
Comment 10 Lewis Smith 2023-04-28 20:57:20 CEST
(In reply to Uli Selle from comment #6)
> - journalctl --no-hostname -B | xz > journal.txt.xz
> - journalctl: Ungültige Option -- B
Apologies, my bad: it should be -b

Please give feedback for comment 8 when you see the updated package. Mine is still at harddrake-18.60-2.mga9 on an up-to-date Cauldron system.
Comment 11 Charly Pammer 2023-05-09 18:36:26 CEST
I had the same issue with a Geforce G640 card which requires the nvidia470 driver. I upgraded from MGA8 using urpmi on a shell.

The message "The display-driver has been automatically changed to 'nvidia'." on X start drive me nuts :-).

It took me a while to sort this out. These steps finally did the trick for me:

1. configure X to use the nvidia driver using XFdrake.

2. enable nvidia DRM in file /etc/modprobe.d/display-driver.conf by removing the comment ("#") from line 
#options nvidia-drm modeset=1

3. Reboot

4. add a kernel option that hinders nouveau from taking over during boot (At first reboot I added it manually in grub for testing and later permanently using "drakboot"):
options nouveau modeset=0



I did all these steps in a tty terminal and also had stopped the display manager beforehand. This was mostly due to the fact that my system tended to freeze sporadicly using nouveau (I already knew this "phenomenon" from MGA8) and I did not want it to freeze while DKMS or urpmi did stuff.

In step 1 I also deactivated the graphical login on boot, but started X using startx from a tty after logging.

When all worked well I wanted to re-enable the graphical login using XFdrake. I noticed that "Disable HW acceleration" was always checked. Even when I unchecked it, it was checked again when I opened the options dialog again.
In the end I unchecked it, checked the "graphical login" and exited XFdrake and just exited XFdrake.  I did not expect a graphical login on reboot, but there it was. And HW acceleration still seems to be there as well (during my experiments earlier I had ended up withou HW accel which made anything from using a browser to playing a video in VLC pretty tedious).

Hope this helps a bit

CC: (none) => kcpammer

Comment 12 Lewis Smith 2023-05-10 20:42:11 CEST
Thank you Charly for your very helpful input.
In the light of which, assigning this to drivers.

Assignee: bugsquad => kernel
CC: lewyssmith => (none)

Comment 13 Giuseppe Ghibò 2023-05-10 21:04:07 CEST
what is the output of:

lspcidrake -v | grep NVIDIA

?

Usually the fallback to nouveau happens when the nvidia driver for some reason fails to start (for a discrete nvidia card it might happens also if you remove the 'nokmsboot' string from GRUB_CMDLINE_LINUX_DEFAULT line in /etc/default/grub).

CC: (none) => ghibomgx

Comment 14 Charly Pammer 2023-05-10 21:15:34 CEST
> what is the output of:
> lspcidrake -v | grep NVIDIA

snd_hda_intel   : NVIDIA Corporation|GK107 HDMI Audio Controller [MULTIMEDIA_AUDIO_DEV] (vendor:10de device:0e1b subv:10b0 subd:0fc1) (rev: a1)
Card:NVIDIA GeForce 635 to GeForce 920: NVIDIA Corporation|GK107 [GeForce GT 640] [DISPLAY_VGA] (vendor:10de device:0fc1 subv:10b0 subd:0fc1) (rev: a1)

'nokmsboot' is set:

grep nokmsboot /etc/default/grub
GRUB_CMDLINE_LINUX_DEFAULT="noiswmd nokmsboot resume=UUID=a1817529-3c87-4386-8306-8a49e41edbd1 audit=0 options nouveau modeset=0"
Comment 15 Giuseppe Ghibò 2023-05-10 21:29:29 CEST
AFAIK the string "options nouveau modeset=0" is meaningless when placed into GRU_CMDLINE_LINUX_DEFAULT. At most should be in modprobe.conf (but it's not read at that point) or the entry you wanted to add should have been "nouveau.modeset=0" (it would prevent nouveau module from loading), which is however not strictly required since there is "nokmsboot".
Comment 16 Charly Pammer 2023-05-11 06:57:35 CEST
No idea, really :-). At least it works for me: nouveau is not loaded according to lsmod.

I do not use a grahical boot splash, but want to see the text output when services are started during boot.

Without the option the text mode changed to a higher resolution at some point during boot and nouveau appeared in the output. The graphical login did not start and I got a message that said something like "system has to be restarted due to graphic driver changes" and after reboot my system was back running X using nouveau.

With the aforementioned option the whole boot process is running in the very basic text mode and nouveau is nowhere to be seen.

(I am not very keen on trying to remove the option to see what happens as the whole thing seems to be fragile enough as it is. I want to keep on running my system to see if the freezes really go away - on MGA8 they were gone, when I changed from nouveau to the nvidia driver)
Comment 17 Uli Selle 2023-05-18 09:14:32 CEST
(In reply to Martin Whitaker from comment #8)
> I believe this bug is occurring because the list of nvidia kernel modules in
> service_harddrake hasn't been updated to include nvidia470. Please test with
> harddrake-18.61 when it reaches the mirrors.

Now "harddrake-18.61-1.mga9-x86_64" is installed and all seems fine.
No error- message and the nvidia 470 driver is installed.
No falling back to nouveau.
Comment 18 Dave Hodgins 2023-05-25 23:16:10 CEST
Thanks for the update. Closing.

Resolution: (none) => FIXED
Status: NEW => RESOLVED


Note You need to log in before you can comment on or make changes to this bug.