Red Hat Linux Enterprise 8 has been in the market for quite a time now and if you are also facing a problem with setting the display resolution persistently in GUI, then this is the article for you. In this tutorial, we will learn how to set display resolution permanently in RHEL 8 (Red Hat Linux Enterprise 8).
It is a simple process and only requires a few steps, which involves first setting your display to the desired resolution and then copying its file. Please note that this solution is only for the people who are having a problem keeping their display resolution on RHEL 8. It might and might not work for you.
Steps to Set Display Resolution in RHEL 8 Permanently
1. Login to your RHEL 8 machine and right-click to get “Display Settings“. Then under “Displays” change the resolution to the desired one.
By default, you must be seeing 800×600.
2. Now after following step 1, a file will be created i.e. ~/.config/monitors.xml. You have to copy this file to /var/lib/gdm/.config/ directory. This will display same resolution after reboot.
This file contains all the settings for the monitor and resolution and looks like below.
[root@rhel8 ~]# ls -lh ~/.config/monitors.xml -rw-r--r--. 1 root root 560 Apr 30 10:57 /root/.config/monitors.xml [root@rhel8~]# # cat ~/.config/monitors.xml <monitors version="2"> <configuration> <logicalmonitor> <x>0</x> <y>0</y> <scale>1</scale> <primary>yes</primary> <monitor> <monitorspec> <connector>Virtual-1</connector> <vendor>unknown</vendor> <product>unknown</product> <serial>unknown</serial> </monitorspec> <mode> <width>1680</width> <height>1050</height> <rate>59.954746246337891</rate> </mode> </monitor> </logicalmonitor> </configuration> </monitors>
[root@rhel8 ~]# ls -lh /var/lib/gdm/.config/ total 0 drwxr-xr-x. 2 gdm gdm 18 Sep 27 2019 dconf drwx------. 3 gdm gdm 27 Sep 27 2019 gnome-session drwx------. 3 gdm gdm 17 Sep 27 2019 ibus drwx------. 2 gdm gdm 263 Sep 27 2019 pulse [root@rhel8 ~]# cp ~/.config/monitors.xml /var/lib/gdm/.config/ [root@rhel8 ~]# reboot
THAT’S IT!!
Special Note About Display Resolution
If you are running your RHEL 8 machine/server in a VMWare Workstation, please also consider checking “Display Scaling” in virtual machine settings.
We hope you like this tutorial on setting display resolution permanently on RHEL 8. Do let us know if you are facing any problem or you fixed this issue by any other method. If you like our article, please consider subscribing to our blog and share with your friends.