The default TTY console resolution on Ubuntu 18.04 Server is normally 800x600. This may be satisfactory in many cases. However, there are times that higher resolution is required. To increase TTY console resolution on the Ubuntu 18.04 server it is necessary to change the configuration of the relevant GRUB boot loader settings within the /etc/default/grub.

TTY console resolution on Ubuntu 18.04 Server virtual machine
Default 800x600 TTY console resolution on Ubuntu 18.04 Server virtual machine

Software Requirements and Conventions Used

Software Requirements and Linux Command Line Conventions
Criteria Requirements
Operating System Ubuntu 18.04 Bionic Beaver Server
Software The configuration works on all bare metal or virtual Ubuntu 18.04 server installations
Other Privileged access to your Linux system as root or via the sudo command. To apply GRUB configuration, reboot of the Ubuntu 18.04 will be also required.
Conventions # - requires given linux commands to be executed with root privileges either directly as a root user or by use of sudo command
$ - requires given linux commands to be executed as a regular non-privileged user

How to increase TTY console resolution step by step instructions

In order to change/increase TTY console resolution we first should obtain supported TYY console screen resolution information. This will require a system reboot and execution of videoinfo from the GRUB command console. In the next step we will configure the GRUB boot loader and perform the system reboot:


  1. Reboot your system into GRUB menu. Press c key to enter GRUB's command line.
    enter GRUB's command line
    To enter GRUB's command line press c key
  2. Obtain available console resolution information be executing the following GRUB commands:
    grub> set pager=1
    grub> vbeinfo
    
    available console resolution options
    Press space bar to scroll down. Take a note of your desired resolution eg. 1024x768.
  3. Reboot your system or enter the normal command to continue with normal server boot.

    Once in the system edit /etc/default/grub to include the following settings. The bellow GRUB settings will set TTY console to 1024x768 resolution.
    GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"
    GRUB_GFXPAYLOAD_LINUX=1024x768
    


    The proposed /etc/default/grub file is shown below:
    # If you change this file, run 'update-grub' afterwards to update
    # /boot/grub/grub.cfg.
    # For full documentation of the options in this file, see:
    #   info -f grub -n 'Simple configuration'
    
    GRUB_DEFAULT=0
    GRUB_TIMEOUT_STYLE=hidden
    GRUB_TIMEOUT=2
    GRUB_DISTRIBUTOR=`lsb_release -i -s 2> /dev/null || echo Debian`
    GRUB_CMDLINE_LINUX_DEFAULT="nomodeset"
    GRUB_CMDLINE_LINUX=""
    
    # Uncomment to enable BadRAM filtering, modify to suit your needs
    # This works with Linux (no patch required) and with any kernel that obtains
    # the memory map information from GRUB (GNU Mach, kernel of FreeBSD ...)
    #GRUB_BADRAM="0x01234567,0xfefefefe,0x89abcdef,0xefefefef"
    
    # Uncomment to disable graphical terminal (grub-pc only)
    #GRUB_TERMINAL=console
    
    # The resolution used on graphical terminal
    # note that you can use only modes which your graphic card supports via VBE
    # you can see them in real GRUB with the command `vbeinfo'
    #GRUB_GFXMODE=640x480
    
    # Uncomment if you don't want GRUB to pass "root=UUID=xxx" parameter to Linux
    #GRUB_DISABLE_LINUX_UUID=true
    
    # Uncomment to disable generation of recovery mode menu entries
    #GRUB_DISABLE_RECOVERY="true"
    
    # Uncomment to get a beep at grub start
    #GRUB_INIT_TUNE="480 440 1"
    GRUB_GFXPAYLOAD_LINUX=1024x768
    
  4. Apply the new GRUB configuration and reboot your system:
    $ sudo update-grub
    $ sudo reboot
    
    Custom TTY console resolution on Ubuntu 18.04 Linux Server
    Custom TTY console resolution on Ubuntu 18.04 Linux Server
ARE YOU LOOKING FOR A LINUX JOB?
Submit your RESUME or create a JOB ALERT on LinuxCareers.com job portal.
DO YOU NEED ADDITIONAL HELP?
Get extra help by visiting our LINUX FORUM or simply use comments below.

You may also be interested in:



Comments and Discussions