Change virtual terminal font size
This post is about how to change the resolution (i.e. font size) of virtual terminals or “tty” in Linux. Virtual terminal is the basic command line interface which you see when you press <Ctrl><Alt><F1> (note: to get back to your existing Gnome or KDE session press <Alt><F7>). This is different from the Terminal emulator, such as the Terminal application in Gnome.
To change the font size of the virtual terminal it is necessary to set the vga parameter in the entry used by the Grub bootloader to start up Linux. Follow the steps below to set the entry correctly.
- First, intall the hwinfo utility through Synaptic or Terminal:
sudo apt-get install hwinfo - Then run the following command in Terminal:
sudo hwinfo --framebuffer - The command will output some information about your graphics system. Skip the top bit and you should see a list of entries like this:
Mode 0x0300: 640x400 (+640), 8 bits
Mode 0x0301: 640x480 (+640), 8 bits
Mode 0x0303: 800x600 (+800), 8 bits
Mode 0x0305: 1024x768 (+1024), 8 bits
Mode 0x0307: 1280x1024 (+1280), 8 bits
Mode 0x0317: 1024x768 (+2048), 16 bits
Mode 0x0318: 1024x768 (+4096), 24 bits - Review the list which might be quite long, select the resolution you want to use and copy the hexadecimal number after Mode. For example, for 24 bit 1024×786 resolution the number is 0×0318.
- Still in the Terminal emulator, run the following command to edit the Grub bootloader configuration file:
gksudo gedit /boot/grub/menu.lst - Find the entry you want to edit (or copy an existing entry and give it a different name) and change the line which begins with “kernel”. As a precaution, make sure you have at least one entry left in the file without the new resolution so you can still safely boot and edit the file again if necessary.
Original entry:
kernel /boot/vmlinuz-2.6.28-15-server root=/dev/sda3 ro quiet splash
New entry:
kernel /boot/vmlinuz-2.6.28-15-server root=/dev/sda3 ro quiet vga=0x0318 splash - Reboot your computer and at the Grub menu select the entry which was edited. You may notice some difference during the boot process, to verify that the resolution and font size are suitable press <Ctrl><Alt><F8> once you are at the login screen. This will take you to tty8 which should display messages from the boot process.
Leave a comment
| Trackback
