I am setting up Debian computers for my high school and I would like to somehow customize LightDM to display system and network information at the login screen.

The big picture is the following : people log into the computers thanks to LDAP authentication. But we have a non-optimal network situation.

First, the computer could be physically disconnected from the network. Second, the DHCP server could fail to give the computer an IP address in time. Third, the LDAP server might be down.

Currently, the standard way to detect this is that your login credentials are rejected. But then you might as well have mistyped them, or simply forgot them.

So there are various causes for a failure to log in, and we unfortunately cannot expect most teachers to even begin to understand them, which leads to frustration and low-value reports of "I cannot login".

So I would like to display an information window stating either "Network cable seems to be disconnected" or "Network is responding, waiting for an IP address" or "Network seems down" or "Network is ready for authentication".

How can I run a program that would compute such information, then display and maybe update it on the login screen ?

  • not a direct answer : why not 1) poll those informations in a file 2) have a local readonly user with little or no credential, 3) you connect and file is displayed, then auto logoff. – Archemar Nov 14 '17 at 14:34
  • Although you want a graphical login, a plan B could be to redirect a network-check script output to /etc/issue, script > /etc/issue. You'd need to change to boot to multi-user instead of graphical. Then they could have an informative message before attempting to login. They would just have to learn to type startx. – jbrock Nov 14 '17 at 21:58

Probably the proper way to do this is to write your own greeter (the thing that shows the "login:" prompt etc). If you are familiar with web technologies you might write your own webkit greeter as in this example.

Or you might try running an X11 application from the hook provided by lightdm. In the file /etc/lightdm/lightdm.conf add a line like


in the [SeatDefaults] section, and in this executable script do something simple like

#--beware running as root
(sleep 2 && xlogo) &
#--must return 0 or lightdm stops
exit 0

where xlogo is some suitable application. I tested this only with

lightdm --test-mode --debug

which you can run whilst you are logged in, and it shows you in a window what you might really get. You will need to test this for real and work out if the window can get iconified or killed, and whether it dies when someone actually logs on. Also make sure you don't stay root in the script, and put it somewhere safer. There are logs in ~/.cache/lightdm/log/.

As an application you could use something like conky which can be fairly easily configured to present system information on the root screen.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.