Can't switch to discrete GPU (NVIDIA)

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
fearsich

Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

Hello everyone,

First of all I am very new to Mint as well as Linux. I have been struggling to get the NVIDIA GPU to work the past days. Everytime I try to switch to the discrete GPU it returns an error pop-up with no text (Similar to this one: http://i.stack.imgur.com/ZbC0X.png). Afterwards the X Server switches back to the Intel card.
Now I know that there are several threads to this issue already, but none of the proposed suggestions seem to work for me. I have worked through all the threads and the links within the threads without any success. For the sake of simplicity I will list everything I've tried by now:

Code: Select all

sudo prime-select nvidia
sudo prime-switch nvidia
My Specs:
Laptop
Processor : 8x Intel(R) Core(TM) i7-4710MQ CPU @ 2.50GHz
Operating System : Linux Mint 17.2 Rafaela
Kernel : Linux 3.16.0-38-generic (x86_64)
3D controller : NVIDIA Corporation GM107M [GeForce GTX 850M] (rev ff) (prog-if ff)
VGA compatible controller : Intel Corporation 4th Gen Core Processor Integrated Graphics Controller (rev 06) (prog-if 00 [VGA controller])

Since it was asked for in another thread the following command:

Code: Select all

dmesg


Returned:

[ 3.977444] init: plymouth-upstart-bridge main process ended, respawning
[ 4.254040] bbswitch: module verification failed: signature and/or required key missing - tainting kernel
[ 4.254269] bbswitch: version 0.8
[ 4.254273] bbswitch: Found integrated VGA device 0000:00:02.0: \_SB_.PCI0.GFX0
[ 4.254278] bbswitch: Found discrete VGA device 0000:01:00.0: \_SB_.PCI0.PEG0.PEGP
[ 4.254287] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95)
[ 4.254353] bbswitch: detected an Optimus _DSM function
[ 4.254392] bbswitch: Succesfully loaded. Discrete card 0000:01:00.0 is on
[ 4.255821] bbswitch: disabling discrete graphics
[ 4.255831] ACPI Warning: \_SB_.PCI0.PEG0.PEGP._DSM: Argument #4 type mismatch - Found [Buffer], ACPI requires [Package] (20140424/nsarguments-95)
[ 4.321068] init: plymouth-stop pre-start process (1576) terminated with status 1
[ 5.487218] r8169 0000:04:00.2 eth0: link up
[ 5.487226] IPv6: ADDRCONF(NETDEV_CHANGE): eth0: link becomes ready

Please inform me if you need any further information.

Thank you all in advance!
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
Laurent85
Level 17
Level 17
Posts: 7081
Joined: Tue May 26, 2015 10:11 am

Re: Can't switch to discrete GPU (NVIDIA)

Post by Laurent85 »

Open a terminal and post back command output

Code: Select all

aptitude search "~i nvidia"
prime-select query
ls -l /usr/share/nvidia
update-alternatives --display x86_64-linux-gnu_gl_conf
Image
fearsich

Re: Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

Laurent85 wrote:Open a terminal and post back command output

Code: Select all

aptitude search "~i nvidia"
prime-select query
ls -l /usr/share/nvidia
update-alternatives --display x86_64-linux-gnu_gl_conf
Output:

Code: Select all

aptitude search "~i nvidia"
i nvidia-346 - NVIDIA binary driver - version 346.82
i nvidia-prime - Tools to enable NVIDIA's Prime
i nvidia-settings - Tool for configuring the NVIDIA graphics d

Code: Select all

prime-select query
unknown

Code: Select all

ls -l /usr/share/nvidia
total 0

Code: Select all

update-alternatives --display x86_64-linux-gnu_gl_conf
x86_64-linux-gnu_gl_conf - manual mode
link currently points to /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf
/usr/lib/nvidia-346-prime/ld.so.conf - priority 8603
slave x86_64-linux-gnu_grub_fb_blacklist: /usr/share/nvidia-346/nvidia-346.grub-gfxpayload
slave x86_64-linux-gnu_man_nvidiaxconfig.gz: /usr/share/man/man1/alt-nvidia-346-xconfig.1.gz
slave x86_64-linux-gnu_nvidia-debugdump: /usr/lib/nvidia-346/bin/nvidia-debugdump
slave x86_64-linux-gnu_nvidia-smi.1.gz: /usr/share/man/man1/alt-nvidia-346-smi.1.gz
slave x86_64-linux-gnu_nvidia_app_profile: /usr/share/nvidia-346/nvidia-application-profiles-346.72-rc
slave x86_64-linux-gnu_nvidia_app_profile_keys: /usr/share/nvidia-346/nvidia-application-profiles-346.72-key-documentation
slave x86_64-linux-gnu_nvidia_bug_report: /usr/lib/nvidia-346/bin/nvidia-bug-report.sh
slave x86_64-linux-gnu_nvidia_modconf: /lib/nvidia-346/modprobe.conf
slave x86_64-linux-gnu_nvidia_smi: /usr/lib/nvidia-346/bin/nvidia-smi
slave x86_64-linux-gnu_nvidia_xconfig: /usr/lib/nvidia-346/bin/nvidia-xconfig
/usr/lib/nvidia-346/ld.so.conf - priority 8604
slave x86_64-linux-gnu_grub_fb_blacklist: /usr/share/nvidia-346/nvidia-346.grub-gfxpayload
slave x86_64-linux-gnu_libvdpau_nvidia.so: /usr/lib/nvidia-346/vdpau/libvdpau_nvidia.so
slave x86_64-linux-gnu_libvdpau_nvidia.so.1: /usr/lib/nvidia-346/vdpau/libvdpau_nvidia.so.1
slave x86_64-linux-gnu_libvdpau_nvidia.so.1_lib32: /usr/lib32/nvidia-346/vdpau/libvdpau_nvidia.so.1
slave x86_64-linux-gnu_libvdpau_nvidia.so_lib32: /usr/lib32/nvidia-346/vdpau/libvdpau_nvidia.so
slave x86_64-linux-gnu_man_nvidiaxconfig.gz: /usr/share/man/man1/alt-nvidia-346-xconfig.1.gz
slave x86_64-linux-gnu_man_persistenced.gz: /usr/share/man/man1/alt-nvidia-346-persistenced.1.gz
slave x86_64-linux-gnu_nvidia-cuda-mps-control: /usr/lib/nvidia-346/bin/nvidia-cuda-mps-control
slave x86_64-linux-gnu_nvidia-cuda-mps-control.1.gz: /usr/share/man/man1/alt-nvidia-346-cuda-mps-control.1.gz
slave x86_64-linux-gnu_nvidia-cuda-mps-server: /usr/lib/nvidia-346/bin/nvidia-cuda-mps-server
slave x86_64-linux-gnu_nvidia-debugdump: /usr/lib/nvidia-346/bin/nvidia-debugdump
slave x86_64-linux-gnu_nvidia-smi.1.gz: /usr/share/man/man1/alt-nvidia-346-smi.1.gz
slave x86_64-linux-gnu_nvidia_app_profile: /usr/share/nvidia-346/nvidia-application-profiles-346.72-rc
slave x86_64-linux-gnu_nvidia_app_profile_keys: /usr/share/nvidia-346/nvidia-application-profiles-346.72-key-documentation
slave x86_64-linux-gnu_nvidia_bug_report: /usr/lib/nvidia-346/bin/nvidia-bug-report.sh
slave x86_64-linux-gnu_nvidia_drv: /usr/lib/nvidia-346/xorg/nvidia_drv.so
slave x86_64-linux-gnu_nvidia_modconf: /lib/nvidia-346/modprobe.conf
slave x86_64-linux-gnu_nvidia_persistenced: /usr/lib/nvidia-346/bin/nvidia-persistenced
slave x86_64-linux-gnu_nvidia_smi: /usr/lib/nvidia-346/bin/nvidia-smi
slave x86_64-linux-gnu_nvidia_xconfig: /usr/lib/nvidia-346/bin/nvidia-xconfig
slave x86_64-linux-gnu_xorg_extra_modules: /usr/lib/nvidia-346/xorg
/usr/lib/x86_64-linux-gnu/mesa/ld.so.conf - priority 500
slave x86_64-linux-gnu_xorg_extra_modules: /usr/lib/x86_64-linux-gnu/xorg/x11-extra-modules
Current 'best' version is '/usr/lib/nvidia-346/ld.so.conf'.
Laurent85
Level 17
Level 17
Posts: 7081
Joined: Tue May 26, 2015 10:11 am

Re: Can't switch to discrete GPU (NVIDIA)

Post by Laurent85 »

Open a terminal to fix settings, enter following command and select "0" at prompt request to select "auto mode".

Code: Select all

sudo update-alternatives --config  x86_64-linux-gnu_gl_conf
Then check "update-alternatives --config x86_64-linux-gnu_gl_conf" command settings output now reads :
There are 3 choices for the alternative x86_64-linux-gnu_gl_conf (providing /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf).

Selection Path Priority Status
------------------------------------------------------------
* 0 /usr/lib/nvidia-346/ld.so.conf 8604 auto mode
1 /usr/lib/nvidia-346-prime/ld.so.conf 8603 manual mode
2 /usr/lib/nvidia-346/ld.so.conf 8604 manual mode
3 /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf 500 manual mode

Press enter to keep the current choice[*], or type selection number:
Install prime applet

Code: Select all

apt install nvidia-prime-applet
Reboot, should work now.
Image
fearsich

Re: Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

I did all the steps you've described in your post without success. The output looked exactly like yours. Furthermore I tried it after a driver re-installation without success as well. :(
Laurent85
Level 17
Level 17
Posts: 7081
Joined: Tue May 26, 2015 10:11 am

Re: Can't switch to discrete GPU (NVIDIA)

Post by Laurent85 »

What about command output

Code: Select all

prime-select query
ls -l /usr/share/nvidia
update-alternatives --display x86_64-linux-gnu_gl_conf | grep -i currently 
Re-run "sudo update-alternatives --config x86_64-linux-gnu_gl_conf", this time select "1"
Re-run "sudo update-alternatives --config x86_64-linux-gnu_gl_conf", this time select "2"
This should populate /usr/share/nvidia with 2 links.
Still nothing in /usr/share/nvidia ?

Code: Select all

ls -l /usr/share/nvidia
Have you done anything else so far to try to fix broken settings that could lead to some clues ?
Image
fearsich

Re: Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

Sorry, I had no access to my computer on the weekend. I will check this as soon as I get home today!
Besides installing and trying Bumblebee (which did not work for me as well / I deleted it after) all I did is stated in my 1st post.

Thank you very much!
fearsich

Re: Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

Laurent85 wrote:What about command output

Code: Select all

prime-select query
ls -l /usr/share/nvidia
update-alternatives --display x86_64-linux-gnu_gl_conf | grep -i currently 
Re-run "sudo update-alternatives --config x86_64-linux-gnu_gl_conf", this time select "1"
Re-run "sudo update-alternatives --config x86_64-linux-gnu_gl_conf", this time select "2"
This should populate /usr/share/nvidia with 2 links.
Still nothing in /usr/share/nvidia ?

Code: Select all

ls -l /usr/share/nvidia
Have you done anything else so far to try to fix broken settings that could lead to some clues ?
I ended up with the following lines:

Code: Select all

~ # prime-select query
unknown
~ # ls -l /usr/share/nvidia
total 0
~ # update-alternatives --display x86_64-linux-gnu_gl_conf | grep -i currently 
  link currently points to /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf
~ # sudo update-alternatives --config x86_64-linux-gnu_gl_conf
There are 3 choices for the alternative x86_64-linux-gnu_gl_conf (providing /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf).

  Selection    Path                                       Priority   Status
------------------------------------------------------------
  0            /usr/lib/nvidia-346/ld.so.conf              8604      auto mode
  1            /usr/lib/nvidia-346-prime/ld.so.conf        8603      manual mode
  2            /usr/lib/nvidia-346/ld.so.conf              8604      manual mode
* 3            /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf   500       manual mode

Press enter to keep the current choice[*], or type selection number: 1
update-alternatives: using /usr/lib/nvidia-346-prime/ld.so.conf to provide /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf (x86_64-linux-gnu_gl_conf) in manual mode
andre ~ # ls -l /usr/share/nvidia
total 0
lrwxrwxrwx 1 root root 58 Sep 21 19:16 nvidia-application-profiles-346.72-key-documentation -> /etc/alternatives/x86_64-linux-gnu_nvidia_app_profile_keys
lrwxrwxrwx 1 root root 53 Sep 21 19:16 nvidia-application-profiles-346.72-rc -> /etc/alternatives/x86_64-linux-gnu_nvidia_app_profile
~ # sudo update-alternatives --config x86_64-linux-gnu_gl_conf
There are 3 choices for the alternative x86_64-linux-gnu_gl_conf (providing /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf).

  Selection    Path                                       Priority   Status
------------------------------------------------------------
  0            /usr/lib/nvidia-346/ld.so.conf              8604      auto mode
* 1            /usr/lib/nvidia-346-prime/ld.so.conf        8603      manual mode
  2            /usr/lib/nvidia-346/ld.so.conf              8604      manual mode
  3            /usr/lib/x86_64-linux-gnu/mesa/ld.so.conf   500       manual mode

Press enter to keep the current choice[*], or type selection number: 2
update-alternatives: using /usr/lib/nvidia-346/ld.so.conf to provide /etc/ld.so.conf.d/x86_64-linux-gnu_GL.conf (x86_64-linux-gnu_gl_conf) in manual mode
~ # ls -l /usr/share/nvidia
total 0
lrwxrwxrwx 1 root root 58 Sep 21 19:16 nvidia-application-profiles-346.72-key-documentation -> /etc/alternatives/x86_64-linux-gnu_nvidia_app_profile_keys
lrwxrwxrwx 1 root root 53 Sep 21 19:16 nvidia-application-profiles-346.72-rc -> /etc/alternatives/x86_64-linux-gnu_nvidia_app_profile
After changing the gl conf the "blank error" is now a message with text which reads "log out and back in again". However it changes back to intel after log out/in
Laurent85
Level 17
Level 17
Posts: 7081
Joined: Tue May 26, 2015 10:11 am

Re: Can't switch to discrete GPU (NVIDIA)

Post by Laurent85 »

After changing the gl conf the "blank error" is now a message with text which reads "log out and back in again". However it changes back to intel after log out/in
Reboot immediately instead after update-alternatives command instructions, do not use prime tool before a complete reboot.
Image
fearsich

Re: Can't switch to discrete GPU (NVIDIA)

Post by fearsich »

I rebooted after I've changed the gl conf still no success. I wiped and reinstalled mint now and tried the same still no success. The blank error pops up again now even after the gl conf change.

EDIT: If I choose option 0 and log out then it says upon logout "bbswitch: no suitable DSM call found" maybe this helps. :(
Laurent85
Level 17
Level 17
Posts: 7081
Joined: Tue May 26, 2015 10:11 am

Re: Can't switch to discrete GPU (NVIDIA)

Post by Laurent85 »

I would remove all ppa and use Software Sources Maintenance to clean installed packages. I would also purge nvidia* packages and any manually installed graphics packages. Using "apt purge <package-name>" command to remove configuration files is more secure than "apt remove <package-name>" since apt remove command leaves configuration files on drive. Also blacklist nouveau driver and update initrd before reboot so X will use intel graphics controller. Once the cleanup has been done I would reinstall nvidia driver through Driver Manager.
Image
Locked

Return to “Graphics Cards & Monitors”