LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 07-22-2019, 02:22 AM   #1
slac
Member
 
Registered: May 2019
Posts: 265

Rep: Reputation: Disabled
Question Why I cannot compile nvidia-bumblee?


I tried to install Nvidia Optimus (Bumblebee) in Slackware 14.2 and Slackware 14+current. I found the same errors during installation, I have been trying several things, and I have avoided some errors, anyway they keep appearing.

The error where I got stuck is the following one:

When I tried the automatic installation (https://docs.slackware.com/howtos:ha...nvidia_optimus) the script told to "reboot and enjoy your new driver". However nor primusrun nor optirun were working.

So I tried a manual a installation and I noticed that /root/Bumblebee-SlackBuilds/nvidia-bumblebee/nvidia-bumblebeed.SlackBuild never got compiled correctly thus it never got installed. The following output was shown:

Code:
nvidia-modprobe-410.73/modprobe-utils/pci-sysfs.h
install: will not overwrite just-created '/tmp/bbsb/package-nvidia-bumblebee/usr/lib64/nvidia-bumblebee/libGLX_nvidia.so.410.73' with 'libGLX_nvidia.so.410.73'
install: will not overwrite just-created '/tmp/bbsb/package-nvidia-bumblebee/usr/lib64/nvidia-bumblebee/libEGL_nvidia.so.410.73' with 'libEGL_nvidia.so.410.73'
I edited the file: nvidia-bumblebeed.SlackBuild and commented out the lines, around the lines 134-135:

Code:
    libGLX_nvidia.so.$VERSION \
    libEGL_nvidia.so.$VERSION \
I tried to execute nvidia-bumblebeed-SlackBuild again and the previous error disappeared but new ones appeared.

Code:
nvidia-modprobe-410.73/modprobe-utils/pci-sysfs.h
install: target 'libnvidia-ptxjitcompiler.so.410.73' is not a directory
and that error was where I got stuck, and I don't know what else to do... I tried commenting out some of the lines but that didn't work.
 
Old 07-22-2019, 03:21 AM   #2
Labinnah
Member
 
Registered: May 2014
Location: Łódź, Poland
Distribution: Slackware-current
Posts: 185

Rep: Reputation: 112Reputation: 112
Fist of all, I don't have such hardware, so I cannot tell that commenting something out is good solution.
However, I've look into script, and you probably do mistake in commenting out this lines see:
Code:
install -m 755 \
... some more lines...                                                                                                                                            
    libnvidia-opencl.so.$VERSION \
    libnvidia-ptxjitcompiler.so.$VERSION \
    libGLX_nvidia.so.$VERSION \
    libEGL_nvidia.so.$VERSION \
   $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM
If you do comment in this way:
Code:
install -m 755 \
... some more lines...                                                                                                                                            
    libnvidia-opencl.so.$VERSION \
    libnvidia-ptxjitcompiler.so.$VERSION \
#    libGLX_nvidia.so.$VERSION \
#    libEGL_nvidia.so.$VERSION \
   $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM
Resulting command is wrong. It end at first line with hash, so "libnvidia-ptxjitcompiler.so.$VERSION" is last "path" in it, and threat as destination. You should remove those lines entirely. Or move hashed in different place outside command

Last edited by Labinnah; 07-22-2019 at 03:30 AM. Reason: Error in aswer
 
1 members found this post helpful.
Old 07-22-2019, 04:55 PM   #3
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Unhappy I cannot run optirun or primusrun

Quote:
Originally Posted by Labinnah View Post
Fist of all, I don't have such hardware, so I cannot tell that commenting something out is good solution.
However, I've look into script, and you probably do mistake in commenting out this lines see:
Code:
install -m 755 \
... some more lines...                                                                                                                                            
    libnvidia-opencl.so.$VERSION \
    libnvidia-ptxjitcompiler.so.$VERSION \
    libGLX_nvidia.so.$VERSION \
    libEGL_nvidia.so.$VERSION \
   $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM
If you do comment in this way:
Code:
install -m 755 \
... some more lines...                                                                                                                                            
    libnvidia-opencl.so.$VERSION \
    libnvidia-ptxjitcompiler.so.$VERSION \
#    libGLX_nvidia.so.$VERSION \
#    libEGL_nvidia.so.$VERSION \
   $PKG/usr/lib${LIBDIRSUFFIX}/$PRGNAM
Resulting command is wrong. It end at first line with hash, so "libnvidia-ptxjitcompiler.so.$VERSION" is last "path" in it, and threat as destination. You should remove those lines entirely. Or move hashed in different place outside command
Ohh, I see.. now it's compiling correctly. Sadly for me.. there are still errors after installation. I made again the installation by hand (manual) or automatic installation, no fatal error was shown during installation in Slackware 14+current, nvidia-kernel.SlackBuild did not run correcly in Slackware 14.2 but I will leave that problem for later since this threads is for nvidia-bumblebee.

So in Slackware 14+current things have been installed correctly, but I cannot run optirun or primusrun.

I have the following output:

Code:
[root@comp ~]# optirun -status
[  599.812246] [ERROR]The Bumblebee daemon has not been started yet or the socket path tatus was incorrect.
[  599.812273] [ERROR]Could not connect to bumblebee daemon - is it running?
Code:
[root@comp ~]# primusrun glxgears
primus: fatal: Bumblebee daemon reported: error: [XORG] (EE)
I decided to stop the bumbleed proccess that starts at startup time, I start a new one manually to see the output:

Code:
[root@comp ~]# /usr/sbin/bumblebeed -vvv
[  751.456204] [DEBUG]Found card: 0a:00.0 (discrete)
[  751.456222] [DEBUG]Found card: 00:02.0 (integrated)
[  751.456231] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf
[  751.456351] [INFO]Configured driver: nvidia
[  751.456359] [DEBUG]Skipping auto-detection, using configured driver 'nvidia'
[  751.456472] [DEBUG]Process /sbin/modprobe started, PID 1803.
[  751.456518] [DEBUG]Hiding stderr for execution of /sbin/modprobe
[  751.457529] [DEBUG]SIGCHILD received, but wait failed with No child processes
[  751.457588] [DEBUG]bbswitch has been detected.
[  751.457594] [INFO]Switching method 'bbswitch' is available and will be used.
[  751.457600] [DEBUG]Active configuration:
[  751.457606] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf
[  751.457611] [DEBUG] X display: :8
[  751.457617] [DEBUG] LD_LIBRARY_PATH: /usr/lib64/nvidia-bumblebee:/usr/lib/nvidia-bumblebee
[  751.457623] [DEBUG] Socket path: /var/run/bumblebee.socket
[  751.457629] [DEBUG] pidfile: /var/run/bumblebeed.pid
[  751.457634] [DEBUG] xorg.conf file: /etc/bumblebee/xorg.conf.nvidia
[  751.457640] [DEBUG] xorg.conf.d dir: /etc/bumblebee/xorg.conf.d
[  751.457646] [DEBUG] ModulePath: /usr/lib64/nvidia-bumblebee/xorg/modules,/usr/lib64/xorg/modules
[  751.457651] [DEBUG] GID name: bumblebee
[  751.457657] [DEBUG] Power method: auto
[  751.457664] [DEBUG] Stop X on exit: 1
[  751.457670] [DEBUG] Driver: nvidia
[  751.457677] [DEBUG] Driver module: nvidia
[  751.457683] [DEBUG] Card shutdown state: 1
[  751.457785] [DEBUG]Process /sbin/modprobe started, PID 1804.
[  751.457820] [DEBUG]Hiding stderr for execution of /sbin/modprobe
[  751.458836] [DEBUG]SIGCHILD received, but wait failed with No child processes
[  751.458864] [DEBUG]Configuration test passed.
[  751.459326] [INFO]/usr/sbin/bumblebeed 3.2.1-2013-04-26-Format:%h$ started
[  751.459565] [INFO]Unloading nvidia driver
[  751.459681] [DEBUG]Process rmmod started, PID 1805.
rmmod: ERROR: Module nvidia is in use by: nvidia_modeset
[  751.460707] [DEBUG]Process with PID 1805 returned code 1
[  754.469292] [ERROR]Unloading nvidia driver timed out.
[  754.469336] [DEBUG]Drivers are still loaded, unable to disable card
[  754.469344] [INFO]Initialization completed - now handling client requests

When I execute optirun and primusrun the following output is shown:

Code:
[  813.871261] [DEBUG]Accepted new connection
[  813.871485] [INFO]Starting X server on display :8.
[  813.871831] [DEBUG]Process Xorg started, PID 1809.
[  813.877551] [DEBUG]Process with PID 1809 returned code 1
[  813.877586] [ERROR][XORG] (EE)
[  813.877601] [DEBUG][XORG] Fatal server error:
[  813.877609] [ERROR][XORG] (EE) Invalid isolated device specification
[  813.877621] [ERROR][XORG] (EE)
[  813.877630] [ERROR][XORG] (EE)
[  813.877635] [DEBUG][XORG] Please consult the The X.Org Foundation support
[  813.877640] [DEBUG][XORG]     at http://wiki.x.org
[  813.877646] [DEBUG][XORG]  for help.
[  813.877650] [ERROR][XORG] (EE)
[  813.877656] [ERROR]X did not start properly
[  813.877919] [DEBUG]Socket closed.
I thinks is has something to do with the socket? I do not know, I'm not used to fix problems related to graphics cards/kernel.

There are the two files in /var/run

bumblebeed.pid
bumblebee.socket

Code:
srw-rw---- 1 root  bumblebee    0 Jul 22 16:47 bumblebee.socket
-rw-r--r-- 1 root  root         4 Jul 22 16:47 bumblebeed.pid
I know the outputs above here are shown from the root user, but the same outputs are shown if I execute optirun or primusrun from a normal that is in the bumblebee group.

Any ideas? There's the "rmmod: ERROR: Module nvidia is in use by: nvidia_modeset", socket and xorg problem.
 
Old 07-23-2019, 02:47 AM   #4
J_W
Member
 
Registered: Apr 2004
Location: Yamagata, JAPAN
Distribution: Slackware64-current
Posts: 189

Rep: Reputation: 123Reputation: 123
Re: I cannot run optirun or primusrun

Hello.
Sorry. I don't have a confident solution of your issue. I have a laptop PC with nvidia-GPU with Intel chip, and using bumblebee with NVIDIA 430.34 driver.
I attached a nvidia-bumblebee.SlackBuild file for 430.34 which I'm using.

And , the plan-B is to use Nvidia's pure Prime function (not bumblebee) by installing "sh NVIDIA-Linux-x86_64-430.34.run".
In this case, you need to create xorg.conf in /etc/X11/ directory.
You can find a xorg.conf making script at the bottom post of following thread.
<SOLVED> nvidia prime on dual gpu configuration giving a blank screen
I used this script and create xorg.conf of my PC and it's working fine.

I attached my xorg.conf sample just in case, below.
Code:
Section "ServerLayout"
	Identifier "layout"
	Screen 0 "nvidia"
	Inactive "intel"
EndSection

Section "Device"
	Identifier "nvidia"
	Driver "nvidia"
        VendorName     "NVIDIA Corporation"
        BoardName      "GeForce 940MX"
	BusID "PCI:1:0:0"
EndSection

Section "Screen"
	Identifier "nvidia"
	Device "nvidia"
	Option "AllowEmptyInitialConfiguration"
EndSection

Section "Device"
	Identifier "intel"
	Driver "modesetting"
EndSection

Section "Screen"
	Identifier "intel"
	Device "intel"
EndSection
Attached Files
File Type: txt nvidia-bumblebee.SlackBuild.txt (12.5 KB, 21 views)
 
1 members found this post helpful.
Old 07-23-2019, 04:00 AM   #5
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Lightbulb

Quote:
Originally Posted by J_W View Post
Hello.
Sorry. I don't have a confident solution of your issue. I have a laptop PC with nvidia-GPU with Intel chip, and using bumblebee with NVIDIA 430.34 driver.
I attached a nvidia-bumblebee.SlackBuild file for 430.34 which I'm using.

And , the plan-B is to use Nvidia's pure Prime function (not bumblebee) by installing "sh NVIDIA-Linux-x86_64-430.34.run".
In this case, you need to create xorg.conf in /etc/X11/ directory.
You can find a xorg.conf making script at the bottom post of following thread.
<SOLVED> nvidia prime on dual gpu configuration giving a blank screen
I used this script and create xorg.conf of my PC and it's working fine.

I attached my xorg.conf sample just in case, below.
Code:
Section "ServerLayout"
	Identifier "layout"
	Screen 0 "nvidia"
	Inactive "intel"
EndSection

Section "Device"
	Identifier "nvidia"
	Driver "nvidia"
        VendorName     "NVIDIA Corporation"
        BoardName      "GeForce 940MX"
	BusID "PCI:1:0:0"
EndSection

Section "Screen"
	Identifier "nvidia"
	Device "nvidia"
	Option "AllowEmptyInitialConfiguration"
EndSection

Section "Device"
	Identifier "intel"
	Driver "modesetting"
EndSection

Section "Screen"
	Identifier "intel"
	Device "intel"
EndSection
Thanks for the answer. Now that I have updated to a new kernel just a few hours ago, I tried to make a new manual installation, very carefully.

I didn't try with the Driver you have, just the +current driver that the ./download.sh has in it, but I took your nvidia-bumblebee.SlackBuild and installed from there.

Some of the errors I got in previous installations and whose output I put in the previous post are no longer there.

Sadly again... I still cannot run primusrun or optirun. But I'm getting closer...

Now, no error was shown executing bumblebeed, but the errors appear when I execute primusrun or optirun...

Code:
[root@comp ~]# bumblebeed -vvv
[ 2116.526870] [DEBUG]Found card: 0a:00.0 (discrete)
[ 2116.526894] [DEBUG]Found card: 00:02.0 (integrated)
[ 2116.526899] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf
[ 2116.527234] [DEBUG]Process /sbin/modprobe started, PID 21007.
[ 2116.527276] [DEBUG]Hiding stderr for execution of /sbin/modprobe
[ 2116.528503] [DEBUG]SIGCHILD received, but wait failed with No child processes
[ 2116.528518] [DEBUG]Detected nvidia driver (module nvidia)
[ 2116.528560] [DEBUG]bbswitch has been detected.
[ 2116.528568] [INFO]Switching method 'bbswitch' is available and will be used.
[ 2116.528573] [DEBUG]Active configuration:
[ 2116.528580] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf
[ 2116.528587] [DEBUG] X display: :8
[ 2116.528594] [DEBUG] LD_LIBRARY_PATH: /usr/lib64/nvidia-bumblebee:/usr/lib/nvidia-bumblebee
[ 2116.528601] [DEBUG] Socket path: /var/run/bumblebee.socket
[ 2116.528607] [DEBUG] pidfile: /var/run/bumblebeed.pid
[ 2116.528614] [DEBUG] xorg.conf file: /etc/bumblebee/xorg.conf.nvidia
[ 2116.528622] [DEBUG] xorg.conf.d dir: /etc/bumblebee/xorg.conf.d
[ 2116.528631] [DEBUG] ModulePath: /usr/lib64/nvidia-bumblebee/xorg/modules,/usr/lib64/xorg/modules
[ 2116.528638] [DEBUG] GID name: bumblebee
[ 2116.528645] [DEBUG] Power method: auto
[ 2116.528652] [DEBUG] Stop X on exit: 1
[ 2116.528659] [DEBUG] Driver: nvidia
[ 2116.528666] [DEBUG] Driver module: nvidia
[ 2116.528673] [DEBUG] Card shutdown state: 1
[ 2116.528791] [DEBUG]Process /sbin/modprobe started, PID 21008.
[ 2116.528819] [DEBUG]Hiding stderr for execution of /sbin/modprobe
[ 2116.529975] [DEBUG]SIGCHILD received, but wait failed with No child processes
[ 2116.529992] [DEBUG]Configuration test passed.
[ 2116.530479] [INFO]bumblebeed 3.2.1-2013-04-26-Format:%h$ started
[ 2116.530598] [INFO]Unloading nvidia driver
[ 2116.530697] [DEBUG]Process rmmod started, PID 21009.
[ 2116.563255] [DEBUG]Process with PID 21009 returned code 0
[ 2116.563629] [INFO]Switching dedicated card OFF [bbswitch]
[ 2116.733254] [INFO]Initialization completed - now handling client requests
[ 2118.466605] [DEBUG]Accepted new connection
[ 2118.466818] [INFO]Switching dedicated card ON [bbswitch]
[ 2118.980367] [INFO]Loading driver nvidia (module nvidia)
[ 2118.980559] [DEBUG]Process modprobe started, PID 21015.
[ 2119.203029] [DEBUG]Process with PID 21015 returned code 0
[ 2119.203112] [INFO]Starting X server on display :8.
[ 2119.203280] [DEBUG]Process Xorg started, PID 21018.
[ 2119.209151] [DEBUG]Process with PID 21018 returned code 1
[ 2119.209195] [ERROR][XORG] (EE) 
[ 2119.209201] [DEBUG][XORG] Fatal server error:
[ 2119.209206] [ERROR][XORG] (EE) Invalid isolated device specification
[ 2119.209216] [ERROR][XORG] (EE) 
[ 2119.209221] [ERROR][XORG] (EE) 
[ 2119.209229] [DEBUG][XORG] Please consult the The X.Org Foundation support 
[ 2119.209236] [DEBUG][XORG] 	 at http://wiki.x.org
[ 2119.209244] [DEBUG][XORG]  for help. 
[ 2119.209252] [ERROR][XORG] (EE) 
[ 2119.209257] [ERROR]X did not start properly
[ 2119.209342] [DEBUG]Socket closed.
The only error there now is something with xorg. No more module, socket, bbswitch or PID problems I think.

Maybe... it has something to do with the fact that I din't install any desktop environment during slackware installation? I'm just using window managers.

Could you tell me if you made a full slackware installation? And what desktop environment are you using?

Maybe starting X11 through some of those desktop environments/display managers will solve this problem (X did not start properly)... that's the only (easy) thing I haven't tried yet.

My only and very useful hint is that I have used my hardware with other GNU/Linux distros and works just fine with bumblebee, and yes, I have had desktop environments/X11 in those, except for Arch (just window manager) I think. So it's worth keep trying... I hope.

If nothing of that works, I'll try what you told me secondly.

Last edited by slac; 07-23-2019 at 04:13 AM. Reason: Some spell-checking
 
Old 07-23-2019, 05:13 AM   #6
J_W
Member
 
Registered: Apr 2004
Location: Yamagata, JAPAN
Distribution: Slackware64-current
Posts: 189

Rep: Reputation: 123Reputation: 123
My PC environment is Slackware64-current.
And, I installed bumblebee related packages by manually which is sown in The Manual Way.

I pulled SlackBuild and sources(except the latest NVIDIA drivers) from WhiteWolf1776/Bumblebee-SlackBuilds.
Then get NVIDIA's latest drivers from below.
https://download.nvidia.com/XFree86/...x86_64/430.34/
https://download.nvidia.com/XFree86/

Files you need are NVIDIA-Linux-x86_64-430.34.run and *.tar.bz2 of the latest(430.34) nvidia-installer, nvidia-modprobe, nvidia-persistenced, nvidia-settings, nvidia-xconfig.
After log-in with new kernel, put NVIDIA-Linux-x86_64-430.34.run in nvidia-kernel directory and build & install nvidia kernel modules.
Then, put NVIDIA-Linux-x86_64-430.34.run and *.tar.bz2 files above in nvidia-bumblebee directory, and build & install using my SlackBuild that I attached before.

Please try.
Hope this would some help for you.
 
1 members found this post helpful.
Old 07-24-2019, 03:31 AM   #7
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Arrow

Quote:
Originally Posted by J_W View Post
My PC environment is Slackware64-current.
And, I installed bumblebee related packages by manually which is sown in The Manual Way.

I pulled SlackBuild and sources(except the latest NVIDIA drivers) from WhiteWolf1776/Bumblebee-SlackBuilds.
Then get NVIDIA's latest drivers from below.
https://download.nvidia.com/XFree86/...x86_64/430.34/
https://download.nvidia.com/XFree86/

Files you need are NVIDIA-Linux-x86_64-430.34.run and *.tar.bz2 of the latest(430.34) nvidia-installer, nvidia-modprobe, nvidia-persistenced, nvidia-settings, nvidia-xconfig.
After log-in with new kernel, put NVIDIA-Linux-x86_64-430.34.run in nvidia-kernel directory and build & install nvidia kernel modules.
Then, put NVIDIA-Linux-x86_64-430.34.run and *.tar.bz2 files above in nvidia-bumblebee directory, and build & install using my SlackBuild that I attached before.

Please try.
Hope this would some help for you.
I made a clean slackware installation and updated everything correcly. After that, I followed up your instructions. Sadly didn't work. I thinks it's time to give this up for the moment. Maybe I'll try this again later when I have more experience in the topic, maybe I could finally configure it in Slackware... It has been 2 years...

Thank you for the effort anyway Good luck!
 
Old 07-24-2019, 11:49 PM   #8
SunnyJim
Member
 
Registered: Jan 2016
Location: Canada
Distribution: slackware and linux mint
Posts: 110

Rep: Reputation: Disabled
If you are up to it slackware-current works with prime sync if you set it up right. bumblebee is just a kludgy work around (in my honest opinion).
Look at my thread: https://www.linuxquestions.org/quest...op-4175562920/
skip to the end for the good part. Prime sync is what you want, not bumblebee, although your stability may vary from mine it might be worth a try.
and acceleration through the hdmi port just might work ok which is more than i can say for bumblebee. prime sync more closely approximates how
things were intended to work.

Last edited by SunnyJim; 08-02-2019 at 08:59 PM.
 
1 members found this post helpful.
Old 07-25-2019, 04:54 AM   #9
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Post

Quote:
Originally Posted by SunnyJim View Post
If you are up to it slackware-current works with prime sync if you set it up right. bumblebee is just a kludgy work around (in my honest opinion).
Look at my thread: https://www.linuxquestions.org/quest...op-4175562920/
skip to the end for the good part. Prime sync is what you want, not bumblebee, although your stability may vary from mine it might be worth a try.
Sure, I just made a fresh Slackware 14 current installation. I already followed the instructions the user above gave me [J_W] (to install nvidia bumblebee), they didn't work tho (sadly). So I already have the bbswitch, nvidia-bumblebee and nvidia-kernel packages installed. I think those packages are needed to be re-installed when a kernel upgrade is done (that's the easiest way to get rid of them, I think), but I'm already using the latest kernel version that's available through the official slackware repository by this time and I'm saying this because I don't know how to re-install the kernel, if you could give me a link to that information or just telling me how to do so, I'll be happy to follow the instructions to make the GPU work through PRIME just as you and [J_W] told me.
 
Old 07-25-2019, 06:33 AM   #10
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Arrow

Quote:
Originally Posted by SunnyJim View Post
If you are up to it slackware-current works with prime sync if you set it up right. bumblebee is just a kludgy work around (in my honest opinion).
Look at my thread: https://www.linuxquestions.org/quest...op-4175562920/
skip to the end for the good part. Prime sync is what you want, not bumblebee, although your stability may vary from mine it might be worth a try.
Never mind with my last answer... If did things right then it was easier than I thought.

So I did:

Code:
removepkg nvidia-bumblebee-*.txz nvidia-kernel-*.txz libbsd-*.txz bbswitch-*.txz primus-*.txz
Then:

Code:
slackpkg reinstall kernel-*
eliloconfig
... and some other commands to prepare a second option for booting up through a generic kernel.

If I did it right, then I'm gonna try with Prime. I'll come back later, I hope, with good results.

Last edited by slac; 07-25-2019 at 06:35 AM. Reason: More some spell-checking
 
Old 07-25-2019, 10:22 AM   #11
SunnyJim
Member
 
Registered: Jan 2016
Location: Canada
Distribution: slackware and linux mint
Posts: 110

Rep: Reputation: Disabled
Talking prime sync setup

eliloconfig? hmm, i have had problems with it. If it works for you ok, but if not and you have virtual terminal switching problems use grub instead.
One thing at a time. good luck
 
1 members found this post helpful.
Old 07-26-2019, 05:33 AM   #12
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Talking Finally get this f nvidia gpu working

Quote:
Originally Posted by J_W View Post
Hello.
Sorry. I don't have a confident solution of your issue. I have a laptop PC with nvidia-GPU with Intel chip, and using bumblebee with NVIDIA 430.34 driver.
I attached a nvidia-bumblebee.SlackBuild file for 430.34 which I'm using.

And , the plan-B is to use Nvidia's pure Prime function (not bumblebee) by installing "sh NVIDIA-Linux-x86_64-430.34.run".
In this case, you need to create xorg.conf in /etc/X11/ directory.
You can find a xorg.conf making script at the bottom post of following thread.
<SOLVED> nvidia prime on dual gpu configuration giving a blank screen
I used this script and create xorg.conf of my PC and it's working fine.

I attached my xorg.conf sample just in case, below.
Code:
Section "ServerLayout"
	Identifier "layout"
	Screen 0 "nvidia"
	Inactive "intel"
EndSection

Section "Device"
	Identifier "nvidia"
	Driver "nvidia"
        VendorName     "NVIDIA Corporation"
        BoardName      "GeForce 940MX"
	BusID "PCI:1:0:0"
EndSection

Section "Screen"
	Identifier "nvidia"
	Device "nvidia"
	Option "AllowEmptyInitialConfiguration"
EndSection

Section "Device"
	Identifier "intel"
	Driver "modesetting"
EndSection

Section "Screen"
	Identifier "intel"
	Device "intel"
EndSection
Quote:
Originally Posted by SunnyJim View Post
If you are up to it slackware-current works with prime sync if you set it up right. bumblebee is just a kludgy work around (in my honest opinion).
Look at my thread: https://www.linuxquestions.org/quest...op-4175562920/
skip to the end for the good part. Prime sync is what you want, not bumblebee, although your stability may vary from mine it might be worth a try.
Quote:
Originally Posted by SunnyJim View Post
eliloconfig? hmm, i have had problems with it. If it works for you ok, but if not and you have virtual terminal switching problems use grub instead.
One thing at a time. good luck
Thank you sooooo much! Finally I get this f nvidia gpu working! DD

I tried to get the PRIME technology working with Nouveau... I had three problems with that and I'm gonna explain those just in case someone else find this thread.

First problem: Nouveau module doesn't exist in Slackware current. The reality is that nouveau module exists but it has another name. The noveau module driver in Slackware Current is identified with the name "nv" in the xorg config files.

Second problem: Nouveau module is being used by the kernel that makes xorg unable to use it. Just blacklist nouveau in /etc/modeprobe.d

Third problem: There's no nouveau driver compatible with the graphic card I'm currently using. Even tho I can use nouveau driver under another circumstances I cannot use it with PRIME. (Strange)

Because of the third problem I installed the Nvidia driver just as [J_W] pointed me out in the answer he gave me.

Code:
sh NVIDIA-Linux-x86_64-430.34.run
Also [J_W] gave me some links to manually download some packages to install nvidia-bumblebee when I was trying that, that's where I downloaded that .run file, and actually there are two files in that link, one without 32compatibily and the normal one. The normal one still gives you the option to install without 32compat, but I think the one without 32compat could be better since its size is smaller (in case you don't need 32compat).

Now it's time to create the custom xorg conf file.

When I run: lspci that command gives the BUS ID of the cards. My gpu's BUS ID is 0a:00:00 which should be translated to decimal when configuring the xorg file, so I actually have 10.0.0 as BUS ID.

Then I just put in the .xinitrc file what [SunnyJim] has published in another thread which is the one of the link he shared in his previous answer (the xrandr commands). A black screen appeared the first time I tried and I cannot remember what I did but I think I just re-checked my .xinitrc and custom xorg config file just as [SunnyJim] said in that same thread and it worked.

Now I have the gpu nvidia working correctly! Again, thank you so much for your anwers, you actually helped me out!

Last edited by slac; 07-26-2019 at 05:34 AM. Reason: Some spell-checking
 
Old 07-26-2019, 09:25 AM   #13
mumahendras3
Member
 
Registered: Feb 2018
Location: Indonesia
Distribution: Slackware-current + s6 + s6-rc + s6-linux-init (github.com/mumahendras3/sl6ckware)
Posts: 125

Rep: Reputation: Disabled
Quote:
First problem: Nouveau module doesn't exist in Slackware current. The reality is that nouveau module exists but it has another name. The noveau module driver in Slackware Current is identified with the name "nv" in the xorg config files.
For what I know, "nv" is the old NVIDIA video driver for xorg, not nouveau driver. The nouveau driver is called "nouveau" if you want to use it in xorg.conf file. Maybe you haven't installed xf86-video-nouveau package?

NVIDIA Optimus under nouveau driver doesn't need bumblebee. You can look at https://nouveau.freedesktop.org/wiki/Optimus/ for instructions on how to enable Optimus support under nouveau. Basically it's the matter of ensuring the nouveau kernel driver is loaded and used by the kernel (and not conflicting with nvidia proprietary driver), ensuring that xorg loaded the nouveau driver and used it, then add something in ~/.xinitrc like this:

Code:
xrandr --setprovideroffloadsink nouveau Intel
(Altough from my own experiences, the above command isn't really needed because usually it's already configured automatically if you are using the newer xorg-server and xf86-video-nouveau packages like in Slackware-current). Then when you want to use the discrete graphics just set the environment variable DRI_PRIME=1, for example:

Code:
DRI_PRIME=1 glxinfo | grep "OpenGL vendor string"
That command will output "OpenGL vendor string: nouveau" if everything are set correctly

As for the performance, using NVIDIA's official way of course is faster in most cases than using the nouveau driver. But of course that depends on the user's needs

Last edited by mumahendras3; 07-26-2019 at 09:29 AM.
 
1 members found this post helpful.
Old 07-26-2019, 05:56 PM   #14
slac
Member
 
Registered: May 2019
Posts: 265

Original Poster
Rep: Reputation: Disabled
Post About the confussion between nv and nouveau

Quote:
Originally Posted by mumahendras3 View Post
For what I know, "nv" is the old NVIDIA video driver for xorg, not nouveau driver. The nouveau driver is called "nouveau" if you want to use it in xorg.conf file. Maybe you haven't installed xf86-video-nouveau package?

NVIDIA Optimus under nouveau driver doesn't need bumblebee. You can look at https://nouveau.freedesktop.org/wiki/Optimus/ for instructions on how to enable Optimus support under nouveau. Basically it's the matter of ensuring the nouveau kernel driver is loaded and used by the kernel (and not conflicting with nvidia proprietary driver), ensuring that xorg loaded the nouveau driver and used it, then add something in ~/.xinitrc like this:

Code:
xrandr --setprovideroffloadsink nouveau Intel
(Altough from my own experiences, the above command isn't really needed because usually it's already configured automatically if you are using the newer xorg-server and xf86-video-nouveau packages like in Slackware-current). Then when you want to use the discrete graphics just set the environment variable DRI_PRIME=1, for example:

Code:
DRI_PRIME=1 glxinfo | grep "OpenGL vendor string"
That command will output "OpenGL vendor string: nouveau" if everything are set correctly

As for the performance, using NVIDIA's official way of course is faster in most cases than using the nouveau driver. But of course that depends on the user's needs
Thank you for pointing out that information. I was about to ask something but I found the answer myself.

The reason because I wrote that (the details about nv in my last answer) it's simply because when I was removing the bumblebee related packages I forget to remove the package that blacklists the nouveau not only at boot up but in slackpkg. That's why when I was trying to install the xf86-video-nouveau pkg (through slackpkg) I didn't find it, so I just assumed that the package with the name of xf86-video-nv was the one since nv=nouveau? (Because I didn't know the nv driver) Now I know it is not the case.

As far as the other information you gave me is concerned, you're right; It is not necessary to execute:

Code:
xrandr --setprovideroffloadsink nouveau Intel
... in Slackware Current.

Thanks again.

Last edited by slac; 07-26-2019 at 06:02 PM. Reason: Some spell-checking
 
  


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
[SOLVED] cannot compile nvidia-driver from slackbuilds.org on Slackware64-14.0 tramni1980 Slackware 5 07-10-2013 09:33 PM
Eglibc cannot compile suffix of object files while trying to cross compile Bry6n Linux From Scratch 0 08-21-2012 06:14 PM
cannot compile nvidia driver 177.82 with custom 2.6.30.5 tramni1980 Slackware 8 08-22-2009 12:31 PM
CLFS 5.9 - Glibc compile: suffix of object files, cannot compile Noddegamra Linux From Scratch 3 04-27-2009 12:49 AM
slack 9 with NVidia drivers; cannot compile opengl programs gunter Slackware 5 07-12-2003 11:35 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 05:04 PM.

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