12

The following appears when running optirun glxgears with primus and nvidia-331-updates configured in bumblebee.conf:

primus garbage

This is on 14.04 Trusty Tahr, upgraded from 13.10. The application seems to run on the nvidia gpu, but doesn't display correctly as it did in the previous distro version. I suspect this is a bug in primus in the 14.04 repos, unless one of my packages is poorly configured.

The window does refresh and display part of the glxgears image, but only when I shrink the window, and once per frame that the window is being resized. The GL viewport is scaled incorrectly in this process as well.

Continuing some testing, the PRIMUS_UPLOAD=1 flag seems to make the window refresh properly and everything works as intended. This is not a permanent solution though.

Adam Ryczkowski
  • 4,403
  • 9
  • 40
  • 65
Eidolon
  • 131
  • 6
  • 1
    I have a similar problem. In particular, PRIMUS_UPLOAD=1 seems to consume so many resources that the overhead is larger than the gains... – Florian Echtler Mar 30 '14 at 14:51
  • Do you have nvidia-prime installed? That could be causing the problem. When I try running things on the nvidia card using primus, it works just fine. – biggles5107 May 27 '14 at 21:31
  • @Furyhunter - this is too humblesome - look in my profile for solution about nvidia optimus (with bumblebee) there is an SDK-package at nvidia to download - it is this link here : http://askubuntu.com/questions/311151/how-can-i-install-nvidia-driver-gt-520-and-cuda-5-0-in-ubuntu13-04/311154#311154 – dschinn1001 Jun 05 '14 at 04:06
  • You could also try using the nouveau drivers to see if the bug in the nvidia drivers rather than primus. Also, you can try using optirun vanilla, instead of primus. – Sparhawk Jun 06 '14 at 14:54
  • One thing I do instead of using primusrun itself is use optirun with the primus bridge (set in bumblebee.conf). I seem to get better results doing it this way. – biggles5107 Jun 12 '14 at 18:27

2 Answers2

1

I would recommend using "Nvidia Prime Indicator".

First Remove Bumblebee You need to get rid of Bumblebee and the Nvidia driver. Bumblebee does not run well on my Optimus machine, same problems, get Prime indicator. Also the nvidia-331-updates will be installed with sudo apt-get upgrade after this install.

This is my guide from another thread, try it, I feel it could work.

Carefull on next steps, do only the necessary steps:

To remove and purge bumblebee run terminal (if you got black screen, press Ctrl+Alt+F2) and type:

sudo apt-get remove --purge bumblebee

To install Prime run all 3 rows of command:

sudo add-apt-repository ppa:nilarimogard/webupd8 &&
sudo apt-get update && sudo apt-get install prime-indicator

It should work out from the box with Prime Indicator.

If not, purge them all with:

sudo apt-get remove 'nvidia.*' prime-indicator && sudo apt-get autoremove

and start from scratch with:

sudo apt-get install nvidia-331 indicator-prime

When you get it work, install mesa-utils which allows us to recognize the GPUs:

sudo apt-get install mesa-utils

You have Nvidia Optimus, next steps for Intel driver:

Switch to Intel GPU from Prime Indicator and get Intel Graphics Installer .deb file, install it via Software Center, find the Installer in Dash and run it to update your Intel 4000 with latest drivers.

EDIT: After installing the Intel package, IF sudo apt-get update fails on download.01.org public key, run this in terminal:

This will add the correct Key.

sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys A902DDA375E52366
muru
  • 197,895
  • 55
  • 485
  • 740
Zbunjeni
  • 179
1

Use GitHub retrieve method to check your specs.

$ lspci -vnn | grep '\''[030[02]\]'
00:02.0 VGA compatible controller [0300]: Intel Corporation Haswell-ULT Integrated Graphics Controller [8086:0a16] (rev 09) (prog-if 00 [VGA controller])
08:00.0 3D controller [0302]: NVIDIA Corporation GK208M [GeForce GT 740M] [10de:1292] (rev a1)
  • Notice the notation 08:00.0 with a single dote.
Only laptops have these kind of nVidia Optimus card, so this project won't apply to desktops (for now). Cards from the 4xxM and newer series are all Optimus-enabled. The M stands for "Mobile". But having a 4xxM card isn't enough to be sure that you're having an Optimus laptop. There must also be an integrated video controller in your processor. To check that, run this command in a [terminal][1]:

Ubuntu way to go with Bumblebee (Wiki)

  • Basic Setup for 12.04 - 13.04

you need to purge the ppa if you've installed it.

  • Basic_Setup_for_13.10_and_later

Terminal on, and enter the commands below:

-- UbuntuWiki instructions

  1. Enable the Universe and Multiverse repositories - you need to do this to allow the bumblebee and nvidia packages respectively to be installed.

  2. sudo apt-get install bumblebee bumblebee-nvidia primus linux-headers-generic

  3. Reboot

now

Fist make sure nvidia-current version is 304 is really cool.

After installation--

$ ls -l /etc/bumblebee/
-rw-r--r-- 1 root root 2957 Dez  1 00:38 bumblebee.conf
drwxr-xr-x 2 root root 4096 Nov 30 23:57 xorg.conf.d
-rw-r--r-- 1 root root  513 Dez  1 00:37 xorg.conf.nouveau
-rw-r--r-- 1 root root 1380 Dez  1 00:37 xorg.conf.nvidia

REMEMBER 08:00.0?

$ cat /etc/bumblebee/xorg.conf.n*
$ view /etc/bumblebee/xorg.conf.nouveau # and
$ view /etc/bumblebee/xorg.conf.nvidia  # and change the last dot in

BusID "PCI:08:00.0"

Next:

 $ view /etc/bumblebee/bumblebee.conf
 [bumblebeed]
 VirtualDisplay=:8       # refers to PCI:08:00.0, the 1st left 0 is ignored
 KeepUnusedXServer=false
 ServerGroup=bumblebee
 TurnCardOffAtExit=false
 NoEcoModeOverride=false
 Driver=nvidia           # changed
 XorgConfDir=/etc/bumblebee/xorg.conf.d

 [optirun]
 Bridge=auto
 VGLTransport=proxy
 PrimusLibraryPath=/usr/lib/x86_64-linux-gnu/primus:/usr/lib/i386-linux-gnu/primus
 AllowFallbackToIGC=false

 [driver-nvidia]
 KernelDriver=nvidia-current
 PMMethod=bbswitch       # changed
 LibraryPath=/usr/lib/nvidia-current:/usr/lib32/nvidia-current
 XorgModulePath=/usr/lib/nvidia-current/xorg,/usr/lib/xorg/modules
 XorgConfFile=/etc/bumblebee/xorg.conf.nvidia

 [driver-nouveau]
 KernelDriver=nouveau
 PMMethod=auto
 XorgConfFile=/etc/bumblebee/xorg.conf.nouveau

Wanning: I removed the original comments (intrunctions) as a backup. Do it too or browse the file and change the values without touching comments.

Test primus

 DRI_PRIME=0 glxgears -info | grep "GL_VENDOR"
 DRI_PRIME=1 glxgears -info | grep "GL_VENDOR"

 $ DRI_PRIME=:8 glxgears # and finaly do it

After that follow the information provided in--

Example_update_to_nvidia-319_driver at UbuntuWiki.

You will adjust the driver version and paths too in the file above.

Works very well to me.

ftcosta
  • 121
  • 1
  • 5