amonakov / primus

Low-overhead client-side GPU offloading
ISC License
216 stars 20 forks source link

primusrun failed with "file exists" error #163

Closed woodelf closed 9 years ago

woodelf commented 9 years ago

Starting this month (earlier may be), I found I cannot correctly run primusrun any more. It always failed with error. The variable _PRIMUSVERBOSE=2 does not help to provide any useful output at all. It also only shows below error message:

wood@Gentoo ~ $ primusrun glxgears
primus: fatal: failed to connect to Bumblebee daemon: File exists

However, I cannot figure out what is the exact file that causing this issue. My bumblebee daemon is correctly running, and of course, my user is a member of bumblebee group.

wood@Gentoo ~ $ LANG=C systemctl status -l bumblebeed
bumblebeed.service - Bumblebee C Daemon
Loaded: loaded (/usr/lib64/systemd/system/bumblebeed.service; enabled; vendor preset: enabled)
Active: active (running) since Sat 2015-03-28 00:16:31 CST; 39min ago
Main PID: 5589 (bumblebeed)
CGroup: /system.slice/bumblebeed.service
        └─5589 /usr/sbin/bumblebeed

Mar 28 00:16:31 Gentoo systemd[1]: Started Bumblebee C Daemon.
Mar 28 00:16:31 Gentoo systemd[1]: Starting Bumblebee C Daemon...
Mar 28 00:16:31 Gentoo bumblebeed[5589]: [ 4718.141907] [INFO]/usr/sbin/bumblebeed 3.2.1 started

I'm quite sure it works fine before. Could you kindly help to solve this issue?

optirun works fine, but I really need primus to run some of the steam games.

I'm using Gentoo, and here is some of my package version info. I'm not sure if it will be helpful to diagnose the issue:

linux-kernel-3.19.3 xorg-server-1.17.1 libdrm-2.4.60 xf86-video-intel-2.99.917 mesa-10.5.1 nvidia-drivers-349.12

amonakov commented 9 years ago

I've pushed a commit that fixes a mistake in error handling, can you check if it helps? If not, please run primusrun strace glxgears and supply the resulting log.

woodelf commented 9 years ago

The new commit fixed this problem! Now primus works like a charm.

Good job, and thank you so much, @amonakov