Unable to run optirun glxspheres as non-root user

Hi,

When I run optirun glxspheres, I get the following

raaj@raaj-Laptop:~> optirun glxspheres 
Polygons in scene: 62464 (61 spheres * 1024 polys/spheres)
Visual ID of window: 0x21
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  154 (GLX)
  Minor opcode of failed request:  24 (X_GLXCreateNewContext)
  Value in failed request:  0x0
  Serial number of failed request:  22
  Current serial number in output stream:  23

However, I am able run the command as root.

raaj-Laptop:/home/raaj # optirun glxspheres
Polygons in scene: 62464 (61 spheres * 1024 polys/spheres)
Visual ID of window: 0x21
Context is Direct
OpenGL Renderer: GeForce 940M/PCIe/SSE2
82.305632 frames/sec - 91.853086 Mpixels/sec
82.782618 frames/sec - 92.385401 Mpixels/sec
82.281129 frames/sec - 91.825740 Mpixels/sec
82.800279 frames/sec - 92.405111 Mpixels/sec
81.928772 frames/sec - 91.432509 Mpixels/sec
81.770838 frames/sec - 91.256255 Mpixels/sec

I am in the bumblebee group

raaj@raaj-Laptop:~> groups
users bumblebee
raaj@raaj-Laptop:~>

Now, I am able to open programs like inkscape using optirun as a normal user so I don’t understand why glxspheres does not run under normal user mode. Given below are more information


raaj@raaj-Laptop:~> systemctl status bumblebeed
● bumblebeed.service - Bumblebee C Daemon
   Loaded: loaded (/usr/lib/systemd/system/bumblebeed.service; enabled; vendor preset: disabled)
   Active: active (running) since Fri 2017-12-29 19:17:22 EST; 1h 44min ago
 Main PID: 1119 (bumblebeed)
    Tasks: 1 (limit: 512)
   CGroup: /system.slice/bumblebeed.service
           └─1119 /usr/sbin/bumblebeed

Warning: Journal has been rotated since unit was started. Log output is incomplete or unavailable.

raaj@raaj-Laptop:~> optirun --status
Bumblebee status: Ready (3.2.1). X inactive. Discrete video card is off.

raaj@raaj-Laptop:~> cat /proc/acpi/bbswitch
0000:01:00.0 OFF


Any ideas to try ? I am also looking at other Linux forums but unable to find the solution.

I suffer from the same error, but cannot run it as root either.

Note inkscape does not use GL calls and so proceeds to run fine.

I have found a fix that works for me while I was typing my own thread.

Conclusion: SDB on installing the nvidia drivers is WRONG. DO NOT USE THE NVIDIA REPOSITORY.

Instead, grab the two RPMs from the tumbleweed repo (they are scripts) and install those, after purging any nvidia packages, e.g. G03, G04, etc.

http://download.opensuse.org/repositories/X11:/Bumblebee/openSUSE_Tumbleweed/x86_64/

After I did that everything seems to be hunky dory.

Thanks VintagePC ! It works for me too ! rotfl!

Spoke too soon. I rebooted my laptop and when I run optirun glxgears -info, I get an error :frowning:

user@user-Laptop:~>optirun glxgears
X Error of failed request:  BadValue (integer parameter out of range for operation)
  Major opcode of failed request:  154 (GLX)
  Minor opcode of failed request:  24 (X_GLXCreateNewContext)
  Value in failed request:  0x0
  Serial number of failed request:  22
  Current serial number in output stream:  23

I am able to run optirun as root

user-Laptop:/home/user # optirun glxgears
4037 frames in 5.0 seconds = 807.258 FPS
4096 frames in 5.0 seconds = 819.149 FPS
4125 frames in 5.0 seconds = 824.929 FPS