25th October 2016, 15:11 
		
	
	
		HA, after throwing the towel in, I still made 1 effort to check the Arch wiki regarding bumblebee and it seems I found a solution ;-) They really have an EXCELLENT wiki. Seems that the intel related xorg.conf is interfering with bumblebee. So these are the steps that finally got my optirun glxgears running ;-)
1. install driver nvidia-367 from graphics ppa (long-lived branch) and do prime-select intel
2. install bumblebee bumblebee-nvidia and primus from bumblebee/testing repo (add-apt-repository ppa:bumblebee/testing)
3. adapt /etc/modprobe.d/bumblebee.conf and /etc/bumblebee/bumblebee.conf according to this article http://www.webupd8.org/2016/08/how-to-in...lebee.html
4. check if PCI BusID in /etc/bumblebee/xorg.conf.nvidia is OK (check with lspci | egrep 'VGA|3D')
5. and the magic step that did it: move /etc/X11/xorg.conf.d/20-intel to some other backup location :-) /etc/X11/xorg.conf.d must be empty
6. reboot
7. try optirun glxgears - for me WORKS and NO SCREEN TEARING ;-)
8. primusrun glxgears RUNS ALSO ;-)
	
	
	
1. install driver nvidia-367 from graphics ppa (long-lived branch) and do prime-select intel
2. install bumblebee bumblebee-nvidia and primus from bumblebee/testing repo (add-apt-repository ppa:bumblebee/testing)
3. adapt /etc/modprobe.d/bumblebee.conf and /etc/bumblebee/bumblebee.conf according to this article http://www.webupd8.org/2016/08/how-to-in...lebee.html
4. check if PCI BusID in /etc/bumblebee/xorg.conf.nvidia is OK (check with lspci | egrep 'VGA|3D')
5. and the magic step that did it: move /etc/X11/xorg.conf.d/20-intel to some other backup location :-) /etc/X11/xorg.conf.d must be empty
6. reboot
7. try optirun glxgears - for me WORKS and NO SCREEN TEARING ;-)
8. primusrun glxgears RUNS ALSO ;-)

 
								



 

 So maybe the xorg.conf from /etc/X11/ interferes with it somehow. I had similar behavior as you before (when I made it work but after reboot it stopped working), but I think it was all because of those bloody xorg.conf files. And Ubuntu 16.04 introduced the graphics-manager functionality which should automate the detection of graphics cards, but it does more harm than good. So please paste here the content of xorg.conf, so we see what you have in it and then maybe we conclude that you don't need it at all and then it'll all work
 So maybe the xorg.conf from /etc/X11/ interferes with it somehow. I had similar behavior as you before (when I made it work but after reboot it stopped working), but I think it was all because of those bloody xorg.conf files. And Ubuntu 16.04 introduced the graphics-manager functionality which should automate the detection of graphics cards, but it does more harm than good. So please paste here the content of xorg.conf, so we see what you have in it and then maybe we conclude that you don't need it at all and then it'll all work  
