Use sddm display manager with custom lock screen to replace gdm


In Linux, I like to experiment with different user interfaces for the desktop experience. However, sometimes, certain components become blockade for enabling such environments. In the end, either I have to completely give up on the application, or live up with half baked application. One such component happens to be the display manager.


On a typical day, I wanted to install a background (image) to gnome 3’s display manager (aka gdm). Nothing special, just the background. I have been using a passable theme on my gnome desktop. Except few components, I am starting to get used to gnome 3.16. I have selected a passable icon theme, re-arranged the panel, and got 80 percentage of my extensions working. Some of the earlier desktop bugs have disappeared. In that regards, the experience is more positive than negative.

However, the login manager dis-behaves and is not easy to configure. It is more annoying than anything else. I am not able to patch a nice little background to the login manager. I replaced the default background (which worked before gnome 3.16), but it does not work anymore. I even tried to create a custom theme and replace all the images as suggested by some blog posts. It still did not work.

Now, my only resolve for this problem was to get rid of gdm as my default display manager. After some searching and filtering, the choice came down to sddm. I have used several login managers (both ugly and the modern beautiful one). I had not heard about sddm before, but after reading its description that, it was made using QML (which I really like for modern interfaces) and is a successor for KDM, I found it interesting. Another new entry was Qingy, but because of QML for sddm and the lack of theming option for Qingy (in the description that I read) made me more biased towards sddm. After I looked at some of the images of sddm and the theme that came with it, I was sold. Moreover, since it was created using QML, I hoped that I could probably change at least one theme to my preference.


So sddm it is. I installed the sddm package, and some themes that my package manager suggested. After the installation, I have themes like elarun, futuristic and maui among others. I went to each of these directories and looked at the screenshots or the background images to get an idea of how the theme would look, during login. I liked how maui looked. I then looked in the qml file that defined the theme’s behavior. It did not have any specific values for the background. It however, used theme.conf to read the background image.


I could either rename a preferred image to background.png or change the name in this file. I also noticed that the theme name that sddm was picking was the directory name, rather than anything defined inside (I figured that out by looking some of the files in other themes). My option was simple, copy maui to another name (say mycustom), copy my preferred image to background.png and change “Current” variable in /etc/sddm.conf to “mycustom”


Once this was done, only thing that remained was to disable gdm as my display manager, and enable sddm and add it as my default display manager for login. I did this using a virtual terminal (Ctrl + Alt + F2).

$ sudo systemctl stop gdm
$ sudo systemctl disable gdm
$ sudo systemctl enable sddm.service
$ sudo systemctl start sddm

Lock Screen

After gdm is off, “Ctrl + Alt + L” no longer works for locking the screen in gnome. To solve this problem, I resorted to “i3lock” from i3 window manager. I added “i3lock -d” to my custom keyboard shortcut and assigned it to “Ctrl + Alt + L”.

The problem I have with i3lock is, after it locks the screen, the screen clears to white. I can change it to black, but that is not the solution. I don’t want my screen to draw power, when it is locked. I want the screen to turn off the display. The solution, I use is, lock the screen and turn off the display using two commands.

This can be done by creating a file in bin (can be any name) directory in the home folder called with following text.

xset dpms force off && i3lock -d

After making it executable (chmod +x ~/bin/, and changing the lock shortcut command to full path (not ~ as prefix for home) of this script, I was able to lock and turn off the display using “Ctrl + Alt + L”.


In my experience, this is a very good option among countless other options we Linux users have for login or locking our desktops. I hope someone likes it, as I did. Cheers !!


Leave a comment

Filed under Uncategorized

Leave a Reply

Please log in using one of these methods to post your comment: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s