NOTE TO USERS OF OPENSUSE 12.3
For a description of how I did this procedure on openSUSE 12.3, go to HERE, instead!
NOTE TO USERS OF OPENSUSE 13.1
For a description of how I did this procedure on openSUSE 13.1, go to HERE, instead!
Disclaimer: Bumblebee 3.0 is experimental. It is not supported by openSUSE 12.2. You should not assume that you will get any desired results by imitating this procedure. In fact, you may damage, hose, or otherwise foul up your system. If you are not willing to take that risk on yourself, please leave now and do not try to imitate this procedure. On the other hand, if you are willing and able, you are welcome to test this and provide your feedback, for example by noticing mistakes I made and putting your corrections in the comments.
(Here are the instructions I originally used (and subsequently modified) to arrive at this procedure: File README.md of Package bumblebee)
- Run the following command and make sure the output is as shown:
# cat /etc/SuSE-release openSUSE 12.2 (x86_64) VERSION = 12.2 CODENAME = MantisAlso make sure that I haven't done any weird, non-standard things to my 12.2 installation, like upgrade the kernel to 3.7, install the proprietary nVidia driver "the hard way" (or any other way), etc.
- Add the "Bumblebee nVidia" repository from "Factory"
# zypper ar -f http://download.opensuse.org/repositories/home:/Bumblebee-\ Project:/nVidia:/latest/openSUSE_Factory "Bumblebee nVidia"
- Add Overman79's Open Build Service repository
# zypper ar -f http://download.opensuse.org/repositories/home:/Overman79\ /openSUSE_12.2/ "Home:Overman79"
- Read carefully Overman79's repository description:
Repository Description: Bumblebee brings Nvidia's Optimus Support for Linux through VirtualGL. To use it in Opensuse, you will need to run the following command after installing the bumblebee package inside this repo: # systemctl enable bumblebeed.service Remember to add yourself to the "bumblebee" group. If you want to be able to turn on/off the Nvidia card, i recommend install the "dkms-bbswitch" package. If you use a standard kernel, install the "bbswitch" package. To use the Nvidia proprietary drivers with bumblebee, add the Bumblebee Project Team repo and install the packages "x11-video-nvidia" and "dkms-nvidia" Until i add a proper systemctl service file for dkms, it will be necessary to manually rebuild the modules after a kernel upgrade with this command: # dkms build -m module_name -v version
- Add myself to the "bumblebee" group. This can be done using YaST (Security and Users -> User and Group Management). Read more about YaST here. Or it can be done from the command line using this technique.
- Install the "Linux kernel development" pattern in YaST
- Install the "dkms-nvidia" package. (This may not go smoothly. Make sure the package really does install -- first it downloads the binary blob, then it installs it (DKMS kernel module build), and then it makes changes to GRUB2 and initrd. All of this must go well, or it won't work.)
# zypper refresh # zypper install dkms-nvidia
- Enable the dkms system service by issuing the command
systemctl enable dkmsas root
- Install other NVIDIA-related packages:
# zypper install x11-video-nvidia \ x11-video-nvidia-devel \ nvidia-compute \ nvidia-compute-develAnd, assuming you're running a 64-bit system
# zypper install x11-video-nvidia-32bit \ x11-video-nvidia-devel-32bit \ nvidia-compute-devel-32bit
- At this point, you might reboot to test that the 'nvidia' driver really is installed and running. Try
lsmod | grep nvidia,
lsmod | grep nouveau, and
- Install the "dkms-bbswitch" and "bumblebee" packages:
# zypper install dkms-bbswitch # zypper install bumblebee
- Here's what I see at this point:
# zypper info bumblebee ... Repository: home:Overman79 Name: bumblebee Version: 3.0.1-16.1 Arch: x86_64 .... # zypper info dkms-bbswitch ... Repository: home:Overman79 Name: dkms-bbswitch Version: 0.5-2.1 Arch: noarch ...
- Activate the "bumblebeed.service":
# systemctl enable bumblebeed.service # systemctl start bumblebeed.service
- Reboot one more time, and try this:
# lsmod | grep nvidia # lsmod | grep i915 i915 505525 4 drm_kms_helper 51052 1 i915 drm 272508 5 i915,drm_kms_helper i2c_algo_bit 13413 1 i915 video 19345 1 i915 button 13906 1 i915 # lsmod | grep bbswitch bbswitch 13708 0 # # systemctl status bumblebeed.service bumblebeed.service - Bumblebee C Daemon Loaded: loaded (/usr/lib/systemd/system/bumblebeed.service; disabled) Active: active (running) since Mon, 28 Jan 2013 12:56:52 +0100; 4h 0min ago Main PID: 3548 (bumblebeed) CGroup: name=systemd:/system/bumblebeed.service └ 3548 /usr/sbin/bumblebeed Jan 28 12:56:52 wilbur bumblebeed: [ 725.806621] [INFO] /usr/sbin/bumblebeed 3.0.1 started
- Read about the 'bbswitch' module -- this is really important:
- Look at /var/log/messages and search for 'bbswitch':
bbswitch: version 0.5 bbswitch: Found integrated VGA device 0000:00:02.0: \_SB_.PCI0.VID_ bbswitch: Found discrete VGA device 0000:01:00.0: \_SB_.PCI0.PEG0.VID_ bbswitch: detected an Optimus _DSM function bbswitch: Succesfully loaded. Discrete card 0000:01:00.0 is on bbswitch: disabling discrete graphics
- See if discrete graphics is enabled or disabled:
# cat /proc/acpi/bbswitch 0000:01:00.0 ON
- Test the setup further:
$ optirun glxspheres ... while waiting for the spheres to appear, start another terminal ... $ lsmod | grep nvidia nvidia 9385442 40 $ sudo cat /var/log/messages | grep bbswitch ... notice that the last log entry shown is "bbswitch: enabling discrete graphics" ...
- Another way to see the current status of the discrete graphics adapter:
$ optirun --status
- Stop the test by pressing CTRL-C in the glxspheres window. After that, try
lsmod | grep nvidiaagain and notice that the module has been switched back out.
- Submit bug reports concerning this documentation to me :-)
- Q. I also see several options on software.opensuse.org for version 3.x. Is using one of these a better option?
A. Yes, I believe version 3.x is a better option, though I have not tested version 2.x extensively.
- Q. After bumblebee is installed and running, can I then install any of the drivers from the Nvidia repository? or do I need to get drivers from a specific place?
A. The way I did it (see above), I installed the nvidia drivers first, and bumblebee second. Bumblebee seems to want to have nvidia installed and running before it will start.
- Q. Is it possible to uninstall bumblebee afterward if things go wrong?
A. Well, I don't know what you mean by things going wrong, but you can always remove ("zypper remove ...") all the nvidia and bumblebee-related packages if you like.
- This thread on forums.opensuse.org is significant.