How to install Bumblebee on Arch Linux

In this article I will describe how to install Bumblebee on Arch Linux. The Bumblebee-Wiki provides the following description for the software: “Bumblebee is an effort to make Nvidia Optimus enabled laptops work in GNU/Linux systems. Such feature involves two graphics cards with two different power consumption profiles plugged in a layered way sharing a single framebuffer”. Please be extremely cautious throughout the whole installation procedure, depending on your system you may end up with a messed up driver or system configuration! This “How To” is based on my system, here are the most relevant specs:

  • Lenovo ThinkPad T420s
  • CPU: Intel Core i7 – 2620M with integrated GPU
  • Graphics: NVIDIA 4200M Optimus Graphics (NVIDIA GF119M)

0. Preparations
1. Installation
2. Important and useful commands
3. Troubleshooting

0. Preparations

  1. Only use the integrated graphics card:
    Make sure that you are only using the integrated graphics device (intel) and that everything related to the Optimus technology is disabled in BIOS. Disable “OS detection for NVIDIA Optimus” and set the “Graphics device” to “Integrated Graphics” (that’s the on chip GPU) in BIOS. You can see the described configuration in the screenshot below:
    bios conf 1

  2. Remove any installed NVIDIA drivers:
    Remove any previously installed NVIDIA drivers and tools e.g. nvidia, nvidia-utils, xf86-video-nouveau, nouveau-dri. Only the drivers for your integrated intel GPU should be installed. Example:

    $ sudo pacman -R nvidia nvidia-utils xf86-video-nouveau nouveau-dri
    $ sudo pacman -S mesa

1. Installation

  1. Install the drivers
    First install the drivers and tools for the graphics. Notice that I used the official NVIDIA drivers, because the open source drivers (xf86-video-nouveau , nouveau-dri) sadly didn’t seem to work with Bumblebee:

    pacman -S mesa nvidia nvidia-utils

    Notice: Like I mention in the Preparations section the mesa drivers should already be installed!

  2. Install Bumblebee:
    Now it’s time to install Bumblebee and all the required tools

    $ pacman -S bumblebee bbswitch primus
  3. Enable the Bumblebee daemon:
    The Bumblebee daemon will start automatically with the next system start

    $ sudo systemctl enable bumblebeed
  4. Reboot and activate Optimus:
    Reboot your system and activate the Optimus features in BIOS – Enable the “OS detection for NVIDIA Optimus” option and set the Graphics device to “NVIDIA Optimus”. You can see the described configuration in the screenshot below:
    bios conf 2

  5. The first test:
    Try to render GLX-Gears with your NVIDIA graphics card by using the following command:

    $ optirun -vv glxgears

    You should see a window with the spinning GLX-Gears. You can also see in the output that the NVIDIA drivers are being used.

    [42522.192710] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf
    [42522.193024] [DEBUG]optirun version 3.2.1 starting...
    [42522.193034] [DEBUG]Active configuration:
    [42522.193038] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf
    [42522.193042] [DEBUG] X display: :8
    [42522.193045] [DEBUG] LD_LIBRARY_PATH: /usr/lib/nvidia:/usr/lib32/nvidia
    [42522.193048] [DEBUG] Socket path: /var/run/bumblebee.socket
    [42522.193051] [DEBUG] Accel/display bridge: auto
    [42522.193054] [DEBUG] VGL Compression: proxy
    [42522.193057] [DEBUG] VGLrun extra options: 
    [42522.193060] [DEBUG] Primus LD Path: /usr/lib/primus:/usr/lib32/primus
    [42522.193086] [DEBUG]Using auto-detected bridge virtualgl
    [42525.985376] [INFO]Response: Yes. X is active.
    [42525.985395] [INFO]Running application using virtualgl.
    [42525.985506] [DEBUG]Process vglrun started, PID 19563.
    8229 frames in 5.0 seconds = 1645.525 FPS
    7899 frames in 5.0 seconds = 1579.775 FPS

    This command is also useful to test the NVIDIA card:

    optirun glxgears -info

    That’s it! From now on you can use the optirun command to render any application with the NVIDIA card. Make sure to also check out the next section of this article to learn the most important and some useful commands. Take a look at the Troubleshooting section if you run into any trouble.

2. Important and useful commands

  • Run any program/command by using the NVIDIA graphics card:
    $ optirun theCommand
  • Checking if the NVIDIA card is activated:
    $ cat /proc/acpi/bbswitch


    0000:01:00.0 OFF


    0000:01:00.0 ON
  • Manually activate or deactivate the NVIDIA card:
    To manually activate the nvidia card:

    $ sudo echo ON >> /proc/acpi/bbswitch

    For manual deactivation, use:

    $ sudo echo OFF >> /proc/acpi/bbswitch
  • Manually start or stop Bumblebee:
    To manually start the Bumblebee daemon:

    $ sudo systemctl start bumblebeed

    To manually stop the Bumblebee daemon:

    $ sudo systemctl stop bumblebeed

3. Troubleshooting

  • Failed to load module “mouse”
    You try to run an application e.g. glxgears with optirun, but it’s not working. Optirun complains about not being able to load the module “mouse” like in the following example

    $ optirun -vv glxgears
    [ 1164.937930] [DEBUG]Reading file: /etc/bumblebee/bumblebee.conf
    [ 1164.938184] [DEBUG]optirun version 3.2.1 starting...
    [ 1164.938191] [DEBUG]Active configuration:
    [ 1164.938194] [DEBUG] bumblebeed config file: /etc/bumblebee/bumblebee.conf
    [ 1164.938197] [DEBUG] X display: :8
    [ 1164.938199] [DEBUG] LD_LIBRARY_PATH:
    [ 1164.938202] [DEBUG] Socket path: /var/run/bumblebee.socket
    [ 1164.938204] [DEBUG] Accel/display bridge: auto
    [ 1164.938207] [DEBUG] VGL Compression: proxy
    [ 1164.938209] [DEBUG] VGLrun extra options:
    [ 1164.938212] [DEBUG] Primus LD Path: /usr/lib/primus:/usr/lib32/primus
    [ 1164.938224] [DEBUG]Using auto-detected bridge virtualgl[ 1164.943613] [INFO]Response: No - error: [XORG] (EE) Failed to load module "mouse" (module does not exist, 0)
    [ 1164.943629] [ERROR]Cannot access secondary GPU - error: [XORG] (EE) Failed to load module "mouse" (module does not exist, 0)[ 1164.943633] [DEBUG]Socket closed.
    [ 1164.943645] [ERROR]Aborting because fallback start is disabled.
    [ 1164.943651] [DEBUG]Killing all remaining processes.

    install the missing module/driver

    pacman -S xf86-input-mouse
  • Can’t use a second monitor via Displayport:
    I still had not enough time to find a working solution for this problem. However there are some things I could find out: On my system the displayport is hard-wired to the NVIDIA graphics device, so in order to use the displayport the nvidia card must be activated. In this case a second X Server is necessary to use a second monitor that’s connected via displayport.

About M0nk3ym0nk3y

M0nk3ym0nk3y is one of the three LinuxM0nk3ys from Linux M0nk3ys @ WordPress Linux M0nk3ys @ YouTube Linux M0nk3ys @ Twitter

Posted on October 14, 2013, in Audio / Video, Configure, Install, Troubleshooting and tagged , , , , , , , , , , , , , , , , , . Bookmark the permalink. 8 Comments.

  1. Did You try to install bumblebee with official Nvidia package delivered via Nvidia web page?

    • No, I didn’t try the drivers from the Nvidia web page. However I think that it should make no difference, since the drivers from the Arch repository are basically the same as the ones from the Nvidia website, just prepackaged for Arch Linux.

  2. You installed nvidia package, but I thought drivers for Your dedicated card contain nvidia-340xx package. Did I miss something?

    • I suppose you are referring to the new packaging structure of the nvidia drivers in the arch repository as stated here. This post is from October 2013, back then there was only one main nvidia package. However I don’t believe that the NVIDIA 4200M (NVIDIA GF119M) drivers are in the nvidia-340xx package. The nvidia-340xx package only contains the drivers for the old G8x, G9x, and GT2xx GPUs. I have not updated the drivers yet, so I’m not 100% sure, but I think that the drivers for my card are still included in the main package.

  3. Good work. Maybe if I would install a few times ealier it might work for me. Once again I’ve tried install nvidia package, and this time xorg.0.log say that device is not found (EE). Have You any sugestion for me? I use 1000m nvidia quadro.


    • I can’t really help you with so little information. However I found out that your NVIDIA 1000M is actually a GF108GLM. You can check this by running:

      $ lspci -nn | grep VGA

      So I assume that the drivers for your card should be in the main nvidia package. Besides that, I found this post from a guy with the same graphics card as you. The post shows how to install the drivers and bumblebee, but focuses more on the multi monitor setup. The described steps are basically the same as in my post (install the nvidia drivers, install bumblebee and configure your BIOS correctly).

  4. Thanks for Your try, anyway. I know my id card, but even that I cannot find out for sure which package I should have installed ( ). For the second, Arch wiki about bumblebee installation sugest to have Optimus enabled in BIOS. I get in stuck with it.


  1. Pingback: Bumblebee – ArchWiki | antixtodo

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: