Page 1 of 2

[Solved] nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 17:02
by lieutenantdan
.
.EDIT: Solved, see here: http://forum.porteus.org/viewtopic.php? ... 014#p29082
.

Code: Select all

"Xorg failed to start up - deactivating proprietary driver(s)."
...and the output if I boot Porteus into text mode and run startx: ('tail -n20 /var/log/Xorg.0.log')

Code: Select all

Loading extension GLX
(EE)
Fatal server error:
(EE) no screens found(EE)
(EE)
...are the relevant lines. I have also tried modifying my xorg.conf:

Code: Select all

Section "ServerLayout"
    Identifier     "default"
    Screen         0 "Screen0"
    Inactive       "intel"
EndSection

Section "Monitor"
    Identifier     "Monitor0"
EndSection

Section "Device"
    Identifier     "nvidia"
    Driver         "nvidia"
    BusID          "PCI:03:00:0"
EndSection

Section "Screen"
    Identifier     "Screen0"
    Device         "nvidia"
    Monitor        "Monitor0"
EndSection

Section "Device"
    Identifier     "intel"
    Driver         "modesetting"
    BusID          "PCI:00:02:0"
EndSection

Section "Screen"
    Identifier     "Screen1"
    Device         "intel"
    Monitor        "Monitor0"
EndSection
... and I get nothin.

<3 Porteus btw, I've created a Peerguardian module (still working out kde dbus kinks, works great in other environments); promise I'll give back to community, I want this as my primary OS. I've got kind of a hardie for portable distros.

Thanks ya'll, much love.

EDIT: I ought to include that I've also attempted the vga_detect cheat code and I've tried installing the driver using the .run file directly from nVidia, both yielded the same result as above.

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 17:08
by fanthom
need more info. please run 'psinfo' while in text mode and upload generated raport to pastebin.com.

thanks

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 17:14
by lieutenantdan
http://pastebin.com/BgWx1Yd0

Hey thanks for your time. :D

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 17:24
by fanthom
this is a dual GPU setup:

Code: Select all

00:02.0 VGA compatible controller [0300]: Intel Corporation Haswell-ULT Integrated Graphics Controller [8086:0a16] (rev 0b)
        Subsystem: Acer Incorporated [ALI] Device [1025:0866]
        Kernel driver in use: i915
        Kernel modules: i915

Code: Select all

03:00.0 3D controller [0302]: NVIDIA Corporation Device [10de:1341] (rev a2)
        Subsystem: Acer Incorporated [ALI] Device [1025:0867]
        Kernel driver in use: nvidia
        Kernel modules: nouveau, nvidia
and i guess that Intel takes priority over nVidia. nVidia can be used only for 3D and wont be working without additional effort (bumblee package?).
please wait on brokenman to confirm as he has similar config.

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 17:28
by lieutenantdan
Thank you, sir. I will wait for mr. brokenman, and in the meantime I'll do some research on the bumblebee package.

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 22:06
by francois
Meanwhile, you may try the nvidia 340.24 (I imagine you are on 64 bit):
http://dl.porteus.org/x86_64/current/drivers/

Just put it in the /porteus/modules folder and reboot.

You can run to set it permanently given that you use the change cheatcode with your bootloader menu entry:
viewtopic.php?f=123&t=3506

Code: Select all

nvidia-settings

Re: nVidia driver issue on GeForce 840M

Posted: 29 Oct 2014, 23:07
by lieutenantdan
hello francois! Thank you for your time.
I should have indicated my present use of the 340.24 drivers. And now, an update from my progress:

I've discovered this thread/package:
http://forum.porteus.org/viewtopic.php? ... mus#p17183

However, I've manually updated it for use with porteus 3.0.1 and 340.24 drivers. I feel like I've made some progress, though I cannot confirm because I'm stuck again.

When I try to use "optirun" (which is for bumblebee), I receive the following error:

Code: Select all

[ 1043.264333] [ERROR]The Bumblebee daemon has not been started yet or the socket path /var/run/bumblebee.socket was incorrect.
[ 1043.264747] [ERROR]Could not connect to bumblebee daemon - is it running?
I personally believe the following error (which appears during boot time) is to blame for the daemon not running:

Code: Select all

/usr/sbin/bumblebeed: error while loading shared libraries: libbsd.so.0: cannot open shared object file: No such file or directory

Re: nVidia driver issue on GeForce 840M

Posted: 30 Oct 2014, 00:45
by brokenman
Yes correct. In this dual setup intel will be used by default. Bumblebee is the package to use if you want t switch to the discreet card. I havn't compiled it under 3.1rc1 but will try tonight.

Re: nVidia driver issue on GeForce 840M

Posted: 30 Oct 2014, 01:22
by lieutenantdan
Much love, thank you very much.

Re: nVidia driver issue on GeForce 840M

Posted: 31 Oct 2014, 01:56
by brokenman
I was able to get primus running under Porteus 3.1rc1.

Follow the instructions here: http://docs.slackware.com/howtos:hardwa ... ia_optimus

Install Everything in this order. Skip the VIrtualGL section and just compile and install the Primus part. I am not using proprietary drivers ... only the nouveau kernel module (ships with porteus)

At the end instead of running: primus glxgears you should run

DRI_PRIME=1 glxgears

This is because Kernel 3.12+ has added in-kernel power management, replacing bbswitch. My FPS output after this was:

Code: Select all

root@porteus:/mnt/sda8/projects/bumblebee# DRI_PRIME=1 glxgears
Running synchronized to the vertical refresh.  The framerate should be
approximately the same as the monitor refresh rate.
21162 frames in 5.0 seconds = 4232.299 FPS
21325 frames in 5.0 seconds = 4264.887 FPS
21195 frames in 5.0 seconds = 4238.996 FPS

Re: nVidia driver issue on GeForce 840M

Posted: 31 Oct 2014, 23:05
by lieutenantdan
I had it working at one point, "glxgears -info" reported using nVidia card.

Then I got brave and turned the slackware packages into a module and made a startup script:

Code: Select all

make bumblebee group
add myself to it
execute bit set on rc.bumblebeed
start bumblebeed
rebooted and the modules load, everything looks proper. Unfortunately however, "glxgears -info" reports the use of intel drivers. Crap, I was so close! What am I doing wrong? Or would it perhaps be alright with you if i use your module?

The aforementioned commands i actually executed in three different ways:

"DRI_PRIME=1 glxgears -info":
reported intel driver
~7000fps

"optirun glxgears -info":
reported intel driver
~60fps

"primusrun glxgears -info":
reported intel driver
~60fps

The one time i got everything working I had some old modules i was testing out loaded (I believe it was the driver that shipped with porteus, unsure):

"DRI_PRIME=1 glxgears -info":
reported nVidia driver (proprietary)
~600fps (mentioned framerate drop due to proxy from :8)


In the meantime, I'll keep trying to replicate that success, and make it into module.

Side note: I was missing glibc-32bit-dev files when i tried to do COMPAT32=yes compiling.

Re: nVidia driver issue on GeForce 840M

Posted: 31 Oct 2014, 23:22
by brokenman
Glad you got it working. I made a module today doing exactly what you described above. Did you check that the startup script added the group and users?

I created my module under 32bit so I will reboot now and make one for 64bit.

Re: nVidia driver issue on GeForce 840M

Posted: 01 Nov 2014, 00:53
by brokenman
https://www.dropbox.com/s/gfui31800lo68 ... e.xzm?dl=0

This is the 64bit version. It should add the required group and users to that group. It should also start the bumblebee daemon. There is a script called bbgo which you can use.

bbgo glxgears -info

Keep in mind that this does not take care of switching cards. The bbswitch kernel module is not loaded. If you want to play with that you can:

Code: Select all

modprobe bbswitch
echo ON > /proc/acpi/bbswitch

Re: nVidia driver issue on GeForce 840M

Posted: 05 Nov 2014, 19:51
by lieutenantdan
With your help, it is now working! Thank you for your time.

For me, the

Code: Select all

optirun, bbgo, DRI_PRIME=1
commands (with glxgears -info) are using Intel graphics, but the

Code: Select all

primusrun glxgears -info
is using nVidia graphics.


What I did: (note: using proprietary drivers)
  1. Grabbed Porteus 3.1RC, KDE.
  2. Grabbed the package you provided above:
    https://www.dropbox.com/s/gfui31800lo68 ... e.xzm?dl=0
  3. Built the nvidia driver 340.46 using "libvdpau, nvidia-bumblebee, nvidia-kernel, nouveau-blacklist" slackware packages obtained from:
    http://docs.slackware.com/howtos:hardwa ... ia_optimus (bundled them together using mergexzm)
    Here is the driver module I made: https://www.sendspace.com/file/wvrw7z
  4. Ran primusrun glxgears -info
On an Acer Aspire V3-572G-54S6, which comes with a GeForce 840M. Gunna see if I can now mark the thread as solved. However, I do have additional questions, if I may.

How do I pipe Wine through bumblebee? One of my agendas is that I want to get some Windows games up and running, so I'm attempting to do:

Code: Select all

primusrun wine Wow.exe
Which then uses the Intel driver.

Re: [Solved] nVidia driver issue on GeForce 840M

Posted: 05 Nov 2014, 20:35
by brokenman
Glad you got it working. You can start bash using primusrun and then anything else it invokes should also run with the nvidia graphics card. I haven't tested this but I guess it would go: primusrun bash then wine something