How to enable display of framebuffer images (e.g. in w3m, fbi) within byobu (pts)?

I'm trying to run a minimal Ubuntu 13.10 installation without X Window System on my old laptop. One of the most useful tools I rely on in this setup is byobu; however, it seems to prevent me from using applications capable of displaying images in framebuffer.

One such program is the browser w3m (installed with its w3m-img package). Executed from outside byobu (in tty1), though only if preceded by sudo, it displays web pages with images loaded as expected. However, if byobu is enabled (and thus my terminal is no longer identified as tty1, but rather as dev/pts/1), there's no way to get w3m to display images (no matter if I launch it with sudo or not).

The same applies to the fbi image viewer. Outside of byobu (but again, only if I launch it with sudo), it works without any problems. With byobu enabled, it instead produces an error message, the relevant bit of which seems to be

ioctl VT_GETSTATE: Inappropriate ioctl for device (not a linux console?)

As far as I understand, it all has to do something with the fact that byobu relies on a pseudo-terminal, and with some arcane permission settings (as the sudo requirement I mentioned seems to indicate).

Thanks in advance for any help with this!


Solution 1:

As Braden Best's answer says, you need to add your user to the video group.

But you can also do it with the following command:

sudo usermod -a -G video {your username}

Log out and back in (or reboot) after doing this to see the change.

Solution 2:

The framebuffer device (/dev/fb0) is owned by user root and group video

$ ls -l /dev/fb0
crw-rw---- 1 root video 29, 0 Jan 27 11:00 /dev/fb0

To avoid using sudo to make programs using the framebuffer work, you would add yourself to the video group.

First, edit the file. I'm using vim for this example, and assuming no prior knowledge of how to use it.

$ sudo vim /etc/group 

While in vim, find the video line. To do that, just type /video followed by Enter

Then, add yourself to the group by typing Shift+A followed by your username, and then save the file by typing esc followed by :wq, and Enter

A quick restart of your shell, and you should be able to use programs like fbi without prefixing it with sudo