Linux – framebuffer not available. How to install the device /dev/fb/0 on Ubuntu


I am trying to run an application that uses framebuffer on 2.6.31-14-generic #48-Ubuntu.

All I need to do is to install a framebuffer device to get rid of the following error:

/dev/fb/0: No such file or directory
framebuffer not available.
FATAL: no framebuffer available

I searched Google and found some resources indicating to do that on Grub2 – I got nothing though I followed them seamlessly.

Any ideas?

Best Answer

  • You need to activate the framebuffer drivers, which are always deactivated by default.

    I configured these:

    echo "fbcon" | sudo tee -a /etc/initramfs-tools/modules
    echo "vesafb" | sudo tee -a /etc/initramfs-tools/modules

    And then I commented out vesafb (this works for all cards I heard) in


    Then we update the config:

    sudo update-initramfs -u -k all

    We are almost there. Now we need to look for supported resolutions for our card in framebuffer. You probably will have to install hwinfo

    sudo hwinfo --framebuffer

    You can see the resolutions and its hexadecimal code.

    Now you can either press the e key at boot time and add vga=[hexadecimalcode] (e.f. vga=0x346) or make the change permanent in /boot/grub/menu.lst after the defoptions word.

    I found it more secure to try the e key before touching the grub configuration to be sure that it works.

    Later, when you switch to tty with Alt+F1-6 it will be in the resolution you specified. You can use fbi and other utilities.

  • Related Question