If you have removed many packages, you may have accidentally deleted something like lightdm. This package allows you to access your graphical desktop and, in many cases, it will automatically take you. When you remove and restart the machine, you will probably only find a blank screen of nothing.
Don’t worry, because you can probably repair the login screen with a minimum of reproductions. You may want to connect an Ethernet cable to your computer, if applicable, and connect the charger if it is a laptop, as this may be the safest option when handling packages.
How To Fix A Broken Gnome Login Screen On Linux
The Gnome login screen generally works smoothly, as it is a beautiful piece of software with an excellent team behind it. However, even great tools have their difficult days and stop working. So, in this guide, we’ll see how to repair a damaged GNOME login screen in Linux.
Note that it is not necessary to use the Gnome Shell desktop environment to take advantage of this solution. All you need is that you are using a relatively recent version of the Gnome screen manager (the login screen).
In the event that the Gnome login screen stops working as it should, you will not be able to log in to the Gnome session. Since it is not possible to access the Gnome session, it is not possible to quickly open a terminal window to force the login screen to cooperate. Instead, you should take advantage of the TTY virtual console.
What is TTY? It is basically the text-only virtual terminal that can be accessed when a combination of keyboards is pressed on a Linux system. All Linux distributions have default features. Some, like Ubuntu, have six virtual terminals, while other Linux distributions may only have one or two. And then there’s Arch Linux, which offers users TTY virtual consoles as the default desktop environment until they configure everything manually.
The TTY virtual console is useful for working in emergency situations, especially in cases like this, where the Gnome login screen does not respond well, hangs or simply does not work properly.
To get your hands on the TTY virtual console on the Linux desktop, find the keyboard and press Ctrl + Alt + F2, and the first terminal will open. Even if you keep in mind that not all Linux systems assign a TTY to this combination, try some of the others in the following list.
- Ctrl + Alt + F3
- Ctrl + Alt + F4
- Ctrl + Alt + F5
- Ctrl + Alt + F6
After logging in to the TTY virtual console on your Linux PC, locate the “login” section and enter the PC username to access the command line terminal. The “root” account also works.
When you log in to the TTY virtual console, continue with one of the following methods to fix the Gnome login window on your Linux PC.
Method 1: Rebooting Gnome Display Manager With systemd
One way to force the Gnome login screen to repair is to reboot the service that controls it. The reason why it is advisable to restart it is that if problems occur with a program or service, updating the problematic application can quickly restart the application in a short time.
Rebooting the Gnome screen manager means that you need to use the Systemd init system. The reason why Systemd is an integral part of the restart process is that Gnome is tightly integrated with it.
To reboot, use the command systemctl restart gdm.service, along with sudo, since you cannot run system-level commands without root privileges.
sudo systemctl restart gdm.service
When you run the “systemctl restart” command above, the Linux PC should immediately remove it from the TTY virtual terminal and access a newly restarted Gnome login screen, which should work.
If the restart process did not work, try this process as often as necessary. Or give a chance to Method 2.
Method 2 – Stopping And Restarting Gnome Display Manager With System
Restarting the Gnome screen manager’s Systemd service is another good way to resolve problems with the login screen since when it is updated, the problems usually disappear. However, rebooting may not work in all cases.
An alternative approach to make Gnome Display Manager work again is to stop the process. So, start over. In fact, this is probably the same as rebooting, but it is an excellent way to resolve problems with Method 1.
To stop running the Gnome login screen, you need to use the Stop Systemd command. Therefore, in the TTY virtual terminal, try systemctl stop gdm.service with sudo privileges.
sudo systemctl stop gdm.service
Running the “systemctl stop” command above should immediately kill the Gnome display manager. However, I wouldn’t know, since the TTY console is still active. From here, use the command systemctl start gdm.service with sudo to start it again.
sudo systemctl start gdm.service
Immediately after executing the “systemctl start”, the Gnome Display manager will remove it from the TTY virtual terminal and return to a new login screen. Otherwise, if not, press Ctrl + F7 to send the virtual terminal in the background.
That’s it for today. I hope the article helps you to fix the issue of broken login screen on Linux OS. Stay tuned as we will be back soon with another useful article to share with you.
- How To Fix Folders Not Writable By User Account In Linux
- Repair Corrupted Pen Drive or SD Card In Simple Steps [ Quick Guide ]
- Now You Can Force Enable Google Chrome Dark Mode On Windows 10
If you have any query feel free to drop that in the comment section and Visit ATechGuides for more information.