How to take screenshots of the Linux framebuffer console in Ubuntu.

Posted: May 24, 2012. At: 11:35 PM. This was 5 years ago. Post ID: 3915

How to capture your Virtual Terminal to a png file

Ubuntu framebuffer console. Using fbgrab.
Ubuntu framebuffer console. Using fbgrab.

The fbgrab application is used to screen capture the Linux frame-buffer console. Install this utility with the sudo apt-get install fbgrab command and then you may use this command to take a screen-shot of the frame-buffer console.

Download the source code and then unpack it.

localhost% tar -xvf fbgrab-1.3.tar.gz

Then prepare to compile the source code to a binary.

localhost% cd fbgrab-1.3

Now, compile the source code.

localhost% make
cc -g -Wall   fbgrab.c -lpng -lz -o fbgrab
gzip --best --to-stdout fbgrab.1.man > fbgrab.1.gz

And install it the binary and man page to the proper locations on the filesystem.

localhost% su
Password: 
[root@localhost fbgrab-1.3]# make install
install -D -m 0755 fbgrab /usr/local/bin/fbgrab
install -D -m 0644 fbgrab.1.gz /usr/local/share/man/man1/fbgrab.1.gz
sudo fbgrab vty.png

This is obviously a very useful command that you can use to upload screen-shots of your frame-buffer console to the Internet.

The fbgrab homepage: https://fbgrab.monells.se/.

No comments have been made. Use this form to start the conversation :)

Leave a Reply