Bumblebee-Project / Bumblebee

Bumblebee daemon and client rewritten in C
http://www.bumblebee-project.org/
GNU General Public License v3.0
1.29k stars 142 forks source link

Google-Earth not running with primus/optirun #818

Open merkur04 opened 7 years ago

merkur04 commented 7 years ago

Xorg.8.log.txt optirun _command.txt bumblebee.conf.txt

Hello everybody!

I'm not sure if this is really a bumblebee issue. Starting googleearth with the command "optirun --debug -b primus googleearth" gives the output:

"primus: fatal: failed to acquire direct rendering context for display thread"

Googleearth started but freezes as soon as the window begins to open. I've googled this output several times and found a lot of issues related to it. Most of them are about 32-bit games which did not start when using the optirun-command. But all the solutions didn't apply to my problem. As all other APPS run faultlessl with optirun/primusrun and from what I've found in the Internet about this issue, I presume it has something to do with 32-bit applications.

Can anybody give me a hint where I have to search or whether it is a bumblebee bug at all?

I've attached the Debug-output of the above mentioned command and the "Xorg.8.log" output which gives me no relevant hint.

OS: Debian-Jessie 64-bit Kernel: 4.7.0-0.bpo.1-amd64 Bumblebee version: 3.2.1-13 Nvidia Driver: 367.44-3

libgl1-mesa-dri: 12.0.3-1/i38612.0.3-1

primus-libs-ia32:i386 and primus-libs:i386 are installed.

bluca commented 7 years ago

Do you have the i386 nvidia libraries installed? You can install all of them via the metapackage nvidia-driver-libs-i386 if not

merkur04 commented 7 years ago

Thank you for your quick reply :)

I installed: nvidia-driver-libs:i386/jessie-backports libnvidia-eglcore:i386/jessie-backports. There were some dependencies which had also been installed:

libegl-nvidia0:i386{a} libegl1-glvnd-nvidia:i386{a} libgldispatch0-nvidia:i386{a} libnvidia-eglcore:i386 nvidia-driver-libs:i386

Installed also "nvidia-driver-libs-i386:i386"

Then tried again (without a reboot) after a restart of bumblebeed, but still the same result. I'm not sure any longer after what update this problem occurs. I had never a problem running Googleearth with primusrun/optirun. Maybe it had been mesa or openGL, but not sure.

bluca commented 7 years ago

If you run sudo update-glx --config glx is /usr/lib/nvidia/bumblebee selected?

merkur04 commented 7 years ago

Yes, the automatic modus.

bluca commented 7 years ago

Do other 32bit applications work? You can check for example glxgears, which you can extract (dpkg -x) from the i386 package: http://ftp.us.debian.org/debian/pool/main/m/mesa-demos/mesa-utils_8.2.0-1_i386.deb

merkur04 commented 7 years ago

I've only Skype as a 32-bit version. And it runs without a problem.

I've also deleted googleearth, rebuild and installed it again, reinstalled also all nvidia-driver packages, because it helped someone with the same output by trying to launch a 32-bit game. But for me it remains the same. I'm using Googleearth version 6.0.3.2197+1.2.0-1

bluca commented 7 years ago

If other 32bit applications work fine then it's most likely a primus or google earth problem, unlikely to be related to bumblebee

merkur04 commented 7 years ago

Yes, that was also my suspicion, because there is no hint in the Xorg.8.log. All seems to work fine.. As I have told, I unfortunately can't trace back any longer after which Update the problem occurs. I guess it was a mesa or OpenGL Update..

Thank you very much. I'll try to install googleearth7 and give an update tomorrow :)

merkur04 commented 7 years ago

I tried Googleearth 7, but the result is the same. but then I tried to run optirun/primusrun with libgl debug variable and the output is as follows:

"LIBGL_DEBUG=verbose optirun -b primus googleearth"

libGL: screen 0 does not appear to be DRI3 capable libGL: pci id for fd 7: 8086:0a16, driver i965 libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/tls/i965_dri.so libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/i965_dri.so libGL: Using DRI2 for screen 0 libGL: screen 0 does not appear to be DRI3 capable libGL: pci id for fd 21: 8086:0a16, driver i965 libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/tls/i965_dri.so libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/i965_dri.so libGL: Using DRI2 for screen 0 libGL: screen 0 does not appear to be DRI3 capable libGL: pci id for fd 15: 8086:0a16, driver i965 libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/tls/i965_dri.so libGL: OpenDriver: trying /usr/lib/i386-linux-gnu/dri/i965_dri.so libGL: Using DRI2 for screen 0 primus: fatal: failed to acquire direct rendering context for display thread ^C[ 8565.034664] [WARN]Received Interrupt signal.

Screen :0 ?? So can I take it for sure that this not a bumblebee/primus bug but has something to do with Mesa and DRI? But Googleearth runs faultless with the intel card..

bluca commented 7 years ago

Are the mesa 32 bit libraries installed?

libgl1-mesa-glx:i386 libgl1-mesa-dri:i386

merkur04 commented 7 years ago

Yes, both are installed.

bluca commented 7 years ago

Just tried on debian stable + jessie-backports driver/bumblebee and cannot reproduce. The google earth is the latest deb 64bit package from google's website.

$ LIBGL_DEBUG=verbose optirun -b primus -vv google-earth
[  476.476304] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf
[  476.477109] [DEBUG]optirun version 3.2.1 starting...
[  476.477132] [DEBUG]Active configuration:
[  476.477144] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf
[  476.477172] [DEBUG] X display: :8
[  476.477182] [DEBUG] LD_LIBRARY_PATH: /usr/lib/x86_64-linux-gnu/nvidia:/usr/lib/i386-linux-gnu/nvidia:/usr/lib/nvidia
[  476.477195] [DEBUG] Socket path: /var/run/bumblebee.socket
[  476.477208] [DEBUG] Accel/display bridge: primus
[  476.477230] [DEBUG] VGL Compression: proxy
[  476.477246] [DEBUG] VGLrun extra options: 
[  476.477262] [DEBUG] Primus LD Path: /usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus:/usr/lib/primus:/usr/lib32/primus
[  477.197794] [INFO]Response: Yes. X is active.

[  477.197806] [INFO]Running application using primus.
[  477.197903] [DEBUG]Process google-earth started, PID 11091.
[1126/220839:ERROR:net_util.cc(2195)] Not implemented reached in bool net::HaveOnlyLoopbackAddresses()
libGL: screen 0 does not appear to be DRI3 capable
libGL: pci id for fd 42: 8086:0a16, driver i965
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/tls/i965_dri.so
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
libGL: Can't open configuration file /home/bluca/.drirc: No such file or directory.
libGL: Using DRI2 for screen 0
[1126/220839:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler.
[1126/220839:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler.
libGL: screen 0 does not appear to be DRI3 capable
libGL: pci id for fd 54: 8086:0a16, driver i965
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/tls/i965_dri.so
libGL: OpenDriver: trying /usr/lib/x86_64-linux-gnu/dri/i965_dri.so
libGL: Can't open configuration file /home/bluca/.drirc: No such file or directory.
libGL: Using DRI2 for screen 0
libGL: Can't open configuration file /home/bluca/.drirc: No such file or directory.
[1126/220840:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler.
[1126/220840:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler.
merkur04 commented 7 years ago

I also use bumblebee from jessie-backports. I'll give it another try with the Googleearth package from the Google website. This package differs from the official jessie/stable package.

merkur04 commented 7 years ago

No, the result is the same. "optirun --debug -b primus googl-earth" gives:

[ 4831.614658] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf [ 4831.614863] [INFO]Configured driver: nvidia [ 4831.614947] [DEBUG]optirun version 3.2.1 starting... [ 4831.614953] [DEBUG]Active configuration: [ 4831.614958] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf [ 4831.614961] [DEBUG] X display: :8 [ 4831.614963] [DEBUG] LD_LIBRARY_PATH: /usr/lib/x86_64-linux-gnu/nvidia:/usr/lib/i386-linux-gnu/nvidia:/usr/lib/nvidia [ 4831.614965] [DEBUG] Socket path: /var/run/bumblebee.socket [ 4831.614967] [DEBUG] Accel/display bridge: primus [ 4831.614970] [DEBUG] VGL Compression: proxy [ 4831.614974] [DEBUG] VGLrun extra options: [ 4831.614976] [DEBUG] Primus LD Path: /usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus:/usr/lib/primus:/usr/lib32/primus [ 4831.615428] [INFO]Response: Yes. X is active.

[ 4831.615440] [INFO]Running application using primus. [ 4831.615562] [DEBUG]Process google-earth started, PID 1623. [1126/233047:ERROR:net_util.cc(2195)] Not implemented reached in bool net::HaveOnlyLoopbackAddresses() [1126/233047:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler. [1126/233047:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler. [1126/233047:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler. [1126/233047:ERROR:nss_ocsp.cc(581)] No URLRequestContext for OCSP handler. primus: fatal: failed to acquire direct rendering context for display thread

Another crash happened while handling crash!

[ 4832.667427] [DEBUG]SIGCHILD received, but wait failed with No child processes [ 4832.667518] [DEBUG]Socket closed. [ 4832.667574] [DEBUG]Killing all remaining processes.

bluca commented 7 years ago

So any other application ran through optirun is fine? This is quite strange.

Could you try adding --debug to the ExecStart line in /lib/systemd/system/bumblebeed.service, running systemctl daemon-reload and systemctl restart bumblebeed and run optirun, and then attach the logs from journalctl -b -r --since "5 minutes ago" ?

merkur04 commented 7 years ago

bumblebee.log.txt

Thanks for the reply! All 64-Bit applications run without an error, yes.

I run google-earth and afterwards "brutalchess" 32-Bit version, which also doesn't work correctly. The window opened and immediately afterwards freezes. Then I run "journalctl -b -r --since "2 minutes ago". I think this should match all relevant data. I attached the Logfile output.

Running "optirun --debug /usr/games/brutalchess" gives the following:

"optirun --debug -b primus /usr/games/brutalchess [ 6295.647134] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf [ 6295.647395] [INFO]Configured driver: nvidia [ 6295.647493] [DEBUG]optirun version 3.2.1 starting... [ 6295.647499] [DEBUG]Active configuration: [ 6295.647501] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf [ 6295.647503] [DEBUG] X display: :8 [ 6295.647505] [DEBUG] LD_LIBRARY_PATH: /usr/lib/x86_64-linux-gnu/nvidia:/usr/lib/i386-linux-gnu/nvidia:/usr/lib/nvidia [ 6295.647507] [DEBUG] Socket path: /var/run/bumblebee.socket [ 6295.647509] [DEBUG] Accel/display bridge: primus [ 6295.647511] [DEBUG] VGL Compression: proxy [ 6295.647513] [DEBUG] VGLrun extra options: [ 6295.647515] [DEBUG] Primus LD Path: /usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus:/usr/lib/primus:/usr/lib32/primus [ 6296.396010] [INFO]Response: Yes. X is active.

[ 6296.396025] [INFO]Running application using primus. [ 6296.396136] [DEBUG]Process /usr/games/brutalchess started, PID 966. Failed to load fonts. X Error of failed request: GLXBadFBConfig Major opcode of failed request: 156 (GLX) Minor opcode of failed request: 24 (X_GLXCreateNewContext) Serial number of failed request: 30 Current serial number in output stream: 30 ^C[ 6300.714319] [WARN]Received Interrupt signal. [ 6300.714345] [DEBUG]Socket closed. [ 6300.792495] [DEBUG]SIGCHILD received, but wait failed with No child processes [ 6300.792513] [DEBUG]Socket closed. [ 6300.792517] [DEBUG]Killing all remaining processes.