LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop
User Name
Password
Linux - Desktop This forum is for the discussion of all Linux Software used in a desktop context.

Notices


Reply
  Search this Thread
Old 12-03-2018, 08:26 PM   #1
stampede
LQ Newbie
 
Registered: Dec 2018
Posts: 18

Rep: Reputation: Disabled
Ubuntu Studio 18.04 GPU config


Hi all,

I had this working on a previous install of Ubuntu 17.10, same laptop, I was able to enable and disable my laptop's GPU via the following:

Code:
Enable built in CPU/GPU.
sudo prime-select intel
Enable video card.
sudo prime-select nvidia
Digging into this I noticed this command didn't present my GPU.

Code:
#lspci -k | grep -A 2 -i "VGA"
00:02.0 VGA compatible controller: Intel Corporation Haswell-ULT Integrated Graphics Controller (rev 09)
	Subsystem: ASUSTeK Computer Inc. Haswell-ULT Integrated Graphics Controller
	Kernel driver in use: i915
So knowns are this is isolated to Ubuntu Studio. I really like Ubuntu Studio, so I rather not just reformat. It's actually quite fast on this laptop. The boot speed is ridiculously fast.
My thought is this could be a missing Kernel module? I'm a little out of my zone with kernel modules so any help would be appreciated!

Last edited by stampede; 12-03-2018 at 08:28 PM.
 
Old 12-03-2018, 10:53 PM   #2
mrmazda
LQ Guru
 
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, others
Posts: 5,813
Blog Entries: 1

Rep: Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068
You have Optimus hardware (dual GPU), so you need to complete a more complicated installation process that accounts for the dual GPU. Bumblebee is the generic description of the instructions you need to follow to have a working prime-select command. It's not specific to Studio. Any Bumblebee instruction set for Debian, *buntu* or Mint should be able to get you where you need to go.

When lspci doesn't show what you're looking for, try inxi instead (with -Gxx expressly for video info).

NVidia/Prime driver installation instructions should handle kernel modules without you needing to get directly involved with them.
 
Old 12-04-2018, 01:45 AM   #3
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
try this command to see what you have:
Code:
lspci -k | grep -iEA5 'vga|3d|display'
 
Old 12-06-2018, 07:56 PM   #4
stampede
LQ Newbie
 
Registered: Dec 2018
Posts: 18

Original Poster
Rep: Reputation: Disabled
Thanks,

Here are the two outputs I got.

Code:
#lspci -k | grep -iEA5 'vga|3d|display'
00:02.0 VGA compatible controller: Intel Corporation Haswell-ULT Integrated Graphics Controller (rev 09)
	Subsystem: ASUSTeK Computer Inc. Haswell-ULT Integrated Graphics Controller
	Kernel driver in use: i915
	Kernel modules: i915
00:03.0 Audio device: Intel Corporation Haswell-ULT HD Audio Controller (rev 09)
	Subsystem: Intel Corporation Haswell-ULT HD Audio Controller
--
04:00.0 3D controller: NVIDIA Corporation GK107M [GeForce GT 745M] (rev a1)
	Subsystem: ASUSTeK Computer Inc. GK107M [GeForce GT 745M]
	Kernel driver in use: nouveau
	Kernel modules: nvidiafb, nouveau
And then inxi (Great tool never knew about this)

Code:
#inxi -Gxx
Graphics:  Card-1: Intel Haswell-ULT Integrated Graphics Controller
           bus-ID: 00:02.0 chip-ID: 8086:0a16
           Card-2: NVIDIA GK107M [GeForce GT 745M]
           bus-ID: 04:00.0 chip-ID: 10de:0fe3
           Display Server: x11 (X.Org 1.19.6 )
           drivers: modesetting,nouveau (unloaded: fbdev,vesa)
           Resolution: 1920x1080@59.97hz
           OpenGL: renderer: Mesa DRI Intel Haswell Mobile
           version: 4.5 Mesa 18.0.5 (compat-v: 3.0) Direct Render: Yes
MrMazda, what do you think is the best way forward? I followed the process for installing NVidea compatibility in Ubuntu and for both recommended drivers things haven't worked.

At first I thought it was Wayland // X Windows compatibility issues, because I'm pretty sure the NVidea drivers only work on X-windows systems. I have the Cinnamon desktop installed on my Ubuntu Studio 18.04 install. But checking for X windows, and trying the included XFCE desktop yielded no solutions.

Code:
# loginctl show-session c1 -p Type
Type=x11
 
Old 12-06-2018, 11:29 PM   #5
mrmazda
LQ Guru
 
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, others
Posts: 5,813
Blog Entries: 1

Rep: Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068
Quote:
Originally Posted by stampede View Post
I followed the process for installing NVidea compatibility in Ubuntu and for both recommended drivers things haven't worked.
Followed what process exactly? There is more than one path that can be taken with Optimus. What exactly does "haven't worked" mean? If you found and followed Optimus instruction for Studio, *buntu, Debian and/or Mint and couldn't get it working to your satisfaction, maybe you should try the highly praised Archlinux instructions. I can't follow them, or tell whether they or some other might be best, because I don't have the special hardware combination you have. Maybe if you stated which model laptop you have, someone who has one like it could offer more useful help. Maybe the best plan would be go back to 17.10, then do a do-release-upgrade or apt dist-upgrade, which is how I would have proceeded. Fresh installs are fine for those who like cleaning house, but I'm not one of them. I like to take maximum advantage of my already invested effort.
 
Old 12-07-2018, 02:05 AM   #6
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
https://www.startpage.com/do/dsearch...vidia+graphics

you should start with ubuntu's own instructions if possible (help.ubuntu.com i think).
 
Old 12-17-2018, 05:01 AM   #7
stampede
LQ Newbie
 
Registered: Dec 2018
Posts: 18

Original Poster
Rep: Reputation: Disabled
Reviewing the Optimus installation methods, I think I've fallen into a dependency loop.

Code:
The following packages have unmet dependencies:
 libnvidia-ifr1-390 : Depends: libnvidia-gl-390 but it is not installed
 libnvidia-ifr1-390:i386 : Depends: libnvidia-gl-390:i386 but it is not installed
 nvidia-driver-390 : Depends: libnvidia-gl-390 (= 390.77-0ubuntu0.18.04.1) but it is not installed
                     Recommends: libnvidia-gl-390:i386 (= 390.77-0ubuntu0.18.04.1)
E: Unmet dependencies. Try 'apt --fix-broken install' with no packages (or specify a solution).
MrM, your right I should have done a dist-upgrade rather than re-install. It's a bad habit. While I like the current UbuntuStudio installation. Maybe it's best to go back to vanilla Ubuntu and try again from there. Weighing what's more important GPU vs Low Latency Kernel, I'd say GPU probably wins out.
 
Old 12-18-2018, 01:13 AM   #8
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
from that output, i would try
Code:
apt --fix-broken install libnvidia-gl-390
or simply
Code:
apt install libnvidia-gl-390
 
Old 12-18-2018, 08:01 PM   #9
stampede
LQ Newbie
 
Registered: Dec 2018
Posts: 18

Original Poster
Rep: Reputation: Disabled
Hey ondoho,

I tried those commands and it comes back with an error. Previously when I ran #sudo ubuntu-drivers devices it recommended the nvidia-340 driver which I installed, after installing it didn't work. I re-ran the command and 390 was recommended. It looks like it's unable to fully clean up the nvidia-340 install.

I've also tried a few purge commands I found, but no luck. At best it brings me back to the dependency message I posted earlier.

Code:
# sudo apt --fix-broken install
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Correcting dependencies... Done
The following additional packages will be installed:
  libnvidia-gl-390 libnvidia-gl-390:i386
The following NEW packages will be installed:
  libnvidia-gl-390 libnvidia-gl-390:i386
0 upgraded, 2 newly installed, 0 to remove and 4 not upgraded.
58 not fully installed or removed.
Need to get 0 B/29.2 MB of archives.
After this operation, 147 MB of additional disk space will be used.
Do you want to continue? [Y/n] y
(Reading database ... 351554 files and directories currently installed.)
Preparing to unpack .../libnvidia-gl-390_390.77-0ubuntu0.18.04.1_amd64.deb ...
diversion of /usr/lib/x86_64-linux-gnu/libGL.so.1 to /usr/lib/x86_64-linux-gnu/libGL.so.1.distrib by nvidia-340
dpkg-divert: error: mismatch on package
  when removing 'diversion of /usr/lib/x86_64-linux-gnu/libGL.so.1 by libnvidia-gl-390'
  found 'diversion of /usr/lib/x86_64-linux-gnu/libGL.so.1 to /usr/lib/x86_64-linux-gnu/libGL.so.1.distrib by nvidia-340'
dpkg: error processing archive /var/cache/apt/archives/libnvidia-gl-390_390.77-0ubuntu0.18.04.1_amd64.deb (--unpack):
 new libnvidia-gl-390:amd64 package pre-installation script subprocess returned error exit status 2
Preparing to unpack .../libnvidia-gl-390_390.77-0ubuntu0.18.04.1_i386.deb ...
diversion of /usr/lib/i386-linux-gnu/libGL.so.1 to /usr/lib/i386-linux-gnu/libGL.so.1.distrib by nvidia-340
dpkg-divert: error: mismatch on package
  when removing 'diversion of /usr/lib/i386-linux-gnu/libGL.so.1 by libnvidia-gl-390'
  found 'diversion of /usr/lib/i386-linux-gnu/libGL.so.1 to /usr/lib/i386-linux-gnu/libGL.so.1.distrib by nvidia-340'
dpkg: error processing archive /var/cache/apt/archives/libnvidia-gl-390_390.77-0ubuntu0.18.04.1_i386.deb (--unpack):
 new libnvidia-gl-390:i386 package pre-installation script subprocess returned error exit status 2
Errors were encountered while processing:
 /var/cache/apt/archives/libnvidia-gl-390_390.77-0ubuntu0.18.04.1_amd64.deb
 /var/cache/apt/archives/libnvidia-gl-390_390.77-0ubuntu0.18.04.1_i386.deb
E: Sub-process /usr/bin/dpkg returned an error code (1)

Code:
# apt-cache search nvidia | grep driver
nvidia-settings - Tool for configuring the NVIDIA graphics driver
ubuntu-drivers-common - Detect and install additional Ubuntu driver packages
vdpau-driver-all - Video Decode and Presentation API for Unix (driver metapackage)
xserver-xorg-video-nouveau - X.Org X server -- Nouveau display driver
nvidia-340-dev - NVIDIA binary Xorg driver development files
nvidia-384 - Transitional package for nvidia-driver-390
nvidia-384-dev - Transitional package for nvidia-driver-390
nvidia-driver-390 - NVIDIA driver metapackage
nvidia-utils-390 - NVIDIA driver support binaries
xserver-xorg-video-nvidia-390 - NVIDIA binary Xorg driver
bumblebee-nvidia - NVIDIA Optimus support using the proprietary NVIDIA driver
kubuntu-driver-manager - Driver Manager for Kubuntu
kubuntu-driver-manager-dbg - Driver Manager for Kubuntu -- debug symbols
nvidia-common - transitional package for ubuntu-drivers-common
nvidia-340 - NVIDIA binary driver - version 340.107

Code:
# dpkg -l | grep -i nvidia
iU  libnvidia-cfg1-390:amd64                      390.77-0ubuntu0.18.04.1                      amd64        NVIDIA binary OpenGL/GLX configuration library
iU  libnvidia-common-390                          390.77-0ubuntu0.18.04.1                      all          Shared files used by the NVIDIA libraries
iU  libnvidia-compute-390:amd64                   390.77-0ubuntu0.18.04.1                      amd64        NVIDIA libcompute package
iU  libnvidia-compute-390:i386                    390.77-0ubuntu0.18.04.1                      i386         NVIDIA libcompute package
iU  libnvidia-decode-390:amd64                    390.77-0ubuntu0.18.04.1                      amd64        NVIDIA Video Decoding runtime libraries
iU  libnvidia-decode-390:i386                     390.77-0ubuntu0.18.04.1                      i386         NVIDIA Video Decoding runtime libraries
iU  libnvidia-encode-390:amd64                    390.77-0ubuntu0.18.04.1                      amd64        NVENC Video Encoding runtime library
iU  libnvidia-encode-390:i386                     390.77-0ubuntu0.18.04.1                      i386         NVENC Video Encoding runtime library
iU  libnvidia-fbc1-390:amd64                      390.77-0ubuntu0.18.04.1                      amd64        NVIDIA OpenGL-based Framebuffer Capture runtime library
iU  libnvidia-fbc1-390:i386                       390.77-0ubuntu0.18.04.1                      i386         NVIDIA OpenGL-based Framebuffer Capture runtime library
iU  libnvidia-ifr1-390:amd64                      390.77-0ubuntu0.18.04.1                      amd64        NVIDIA OpenGL-based Inband Frame Readback runtime library
iU  libnvidia-ifr1-390:i386                       390.77-0ubuntu0.18.04.1                      i386         NVIDIA OpenGL-based Inband Frame Readback runtime library
iU  nvidia-compute-utils-390                      390.77-0ubuntu0.18.04.1                      amd64        NVIDIA compute utilities
iU  nvidia-dkms-390                               390.77-0ubuntu0.18.04.1                      amd64        NVIDIA DKMS package
iU  nvidia-driver-390                             390.77-0ubuntu0.18.04.1                      amd64        NVIDIA driver metapackage
iU  nvidia-kernel-common-390                      390.77-0ubuntu0.18.04.1                      amd64        Shared files used with the kernel module
iU  nvidia-kernel-source-390                      390.77-0ubuntu0.18.04.1                      amd64        NVIDIA kernel source package
rc  nvidia-opencl-icd-340                         340.107-0ubuntu0.18.04.1                     amd64        NVIDIA OpenCL ICD
iU  nvidia-prime                                  0.8.8.2                                      all          Tools to enable NVIDIA's Prime
ii  nvidia-settings                               390.77-0ubuntu0.18.04.1                      amd64        Tool for configuring the NVIDIA graphics driver
iU  nvidia-utils-390                              390.77-0ubuntu0.18.04.1                      amd64        NVIDIA driver support binaries
iU  xserver-xorg-video-nvidia-390                 390.77-0ubuntu0.18.04.1                      amd64        NVIDIA binary Xorg driver

Last edited by stampede; 12-18-2018 at 09:32 PM.
 
Old 12-21-2018, 12:56 AM   #10
ondoho
LQ Addict
 
Registered: Dec 2013
Posts: 19,872
Blog Entries: 12

Rep: Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053Reputation: 6053
my guess would be that you need to uninstall -340 first.

in any case, i recommend to make an effort to find out which is the proper nvidia driver for you.

i also searched your dpkg error, and lo and behold: 2nd search result seems to directly pertain to your problem! seems to, i didn't check.
lesson learned: always search before posting.
 
Old 12-27-2018, 09:17 PM   #11
stampede
LQ Newbie
 
Registered: Dec 2018
Posts: 18

Original Poster
Rep: Reputation: Disabled
Thanks for your help ondoho, I did run through a number of ways to uninstall 340 but kept hitting roadblocks. None worked.
While this was all going on I kept getting pop-ups stating system-error. Well, one morning I go to start my PC and it doesn't start... the best I managed to get it is to the grub menu.

I should have taken that moment to practice solving issues in grub, but I took the easy way out and backed up what was on the disk and installed a new O.S. Ubuntu Studio, it's been great but it's me. not you. ..

Anyone stumbling across these posts, sorry there is no solution, Ubuntu 18.04 works great just be careful which version of the nvidia driver you install. I'm going to try my luck with OpenSuse Tumbleweed. I have been running it on VM's for sometime, and it's proved nothing but stable also. Interested in seeing what the desktop experience is like.

Last edited by stampede; 12-27-2018 at 09:18 PM.
 
Old 12-27-2018, 09:39 PM   #12
mrmazda
LQ Guru
 
Registered: Aug 2016
Location: SE USA
Distribution: openSUSE 24/7; Debian, Knoppix, Mageia, Fedora, others
Posts: 5,813
Blog Entries: 1

Rep: Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068Reputation: 2068
Quote:
Originally Posted by stampede View Post
I'm going to try my luck with OpenSuse Tumbleweed. I have been running it on VM's for sometime, and it's proved nothing but stable also. Interested in seeing what the desktop experience is like.
You shouldn't expect much detectable difference between VM and hardware with TW (unless you install to BTRFS with snapshotting fully enabled, which I don't do). Also, openSUSE doesn't have a "the desktop experience". It has Gnome(3) and KDE/Plasma to choose from on the main desktop installation screen, but also offers Mate, KDE3, XFCE, LXQt, LXDE, Enlightenment and more as easily additional or alternative options when enabling additional repos either during or subsequent to completing installation.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[ubuntu studio 17.10] Easiest way to view Lotus Notes databases in Ubuntu Studio 17 mjwraw Linux - Software 1 06-28-2018 10:40 AM
Tried to swap GPU in HP workstation. GPU not working good. LexMK Linux - Hardware 1 06-21-2013 06:59 PM
[SOLVED] Video - Studio 13.37 vs KXStudio, AV Linux, Dream Studio, and Ubuntu Studio l0wt3ch Studio 13.37 1 12-05-2012 07:45 PM
Studio to studio or studio to transmitter stable open source solution MATRIX_q Linux - Server 0 08-25-2011 03:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Desktop

All times are GMT -5. The time now is 01:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration