I'm wondering if there is a way to watch films or images without running X server. I'm not using login manager - I log in to tty and start X server manually.

Hypothetical situation: I log in, but decide to only watch film, or maybe view few photos. I don't want to run X server and all the GUI stuff just for this purpose.

How can I watch films/images without X?


3 Answers 3


For Images:

You can watch images with fbi:

       fbi - linux framebuffer imageviewer

       fbi [ options ] file ...

       fbi  displays  the  specified  file(s) on the linux console using the framebuffer device.  PhotoCD, jpeg, ppm,
       gif, tiff, xwd, bmp and png are supported directly.  For other formats fbi tries to use ImageMagick's convert.

Example command:

$ fbi path/to/file.jpg

For videos:

  • You can use vlc from tty/console:

    Example command:

    $ vlc /path/to/file.mp4
  • You can also use mplayer:

    $ mplayer /path/to/file.mp4

    Note: Video output drivers can be set by -vo option e.g caca, fbdev.(This external article may help)

  • @MatthewRock Have you tried vlc without X session?
    – Pandya
    Sep 2, 2015 at 11:01
  • Works without X. Nice! Sep 2, 2015 at 21:02
  • 4
    You must have permission to write to /dev/fb0. So either sudo, or sudo usermod -aG video $USER. Or else fbi fails, and vlc renders ASCII art. Maybe audio group is also needed. Aug 28, 2016 at 18:31

It's availability depends on the kernel features, but by using the Linux framebuffer provided by the kernel (or Direct Framebuffer library, which allows hardware acceleration) it should be possible to play video on the console, too.

For example, using MPlayer: mplayer -vo fbdev filename.avi or mplayer -vo directfb filename.avi should do the trick if all the required pieces are in place. As pointed out in the other answer, vlc might be easier to get working and it also supports both the old FB and DirectFB.

Wikipedia article says the following about the framebuffer:

There are three applications of the Linux framebuffer.

  • An implementation of text Linux console that doesn't use hardware text mode (useful when that mode is unavailable, or to overcome its restrictions on glyph size, number of code points etc.). One popular aspect of this is the ability to have console show the Tux logo at boot up.
  • A possible graphic output method for a display server, independent of video adapter hardware and its drivers.

  • Graphic programs avoiding the heavy overhead of the X Window System.

The last item includes several Linux programs such as MPlayer, links2, Netsurf, fbida and libraries such as GGI, SDL, GTK+ and Qt Extended can use the framebuffer directly. This is particularly popular in embedded systems.

There is now a library DirectFB which provides a framework for hardware acceleration of the Linux framebuffer.

There's also a Q & A exactly on this topic on this very same forum, and of course the old Framebuffer HOWTO.

Most notably, you should have /dev/fb0 character device available (or more than one if there are multiple framebuffer devices available). At the bare minimum, the output of zcat /proc/config.gz |grep FB should contain CONFIG_FB=y, but I'm not quite sure if the modern GPUs with DRM also need a sort of a legacy driver to make FBDEV work (in my case, I seem to have CONFIG_DRM_I915_FBDEV=y for the Intel GPU).

  • FATAL: Could not initialize video filters (-vf) or video output (-vo).
    – CS QGB
    Sep 7, 2022 at 3:58

You could run a super-light window manager based on wayland. For example I would recommend rootston (from the wlroots project). For example rootston -E vlc, you will get nothing else than vlc.

rootston has no menu, tray, clock, desktop, etc. There is nothing at all. However it is more of a proof of concept, and regularly crashes. It should be OK for watching a movie, though.

rootston is not based on X so it answers your question.

However for running application which are not compatible with wayland, Xwayland will be launched as a layer of compatibility and may contain X code.

If it's only the "GUI stuff" which bothers you, you could look into Openbox.


You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .