There is an ubuntu 18.04 on my notebook. It was upgraded from 16.04.
The notebook's lid is closed and it is connected to a monitor. When I switch on the notebook and login to the system, half of the times it goes to suspend and in the other half times it logins correctly.
I found this answer, but I cannot accept it, because:
- it worked well with 16.04
- this setting IgnoreLid=true would mean that the lid of my notebook is broken which is not true.
My lid is not broken, it worked before the upgrade and it works half of the reboots. What is the explanation of this? Also, I want to keep this feature that I want my notebook to suspend when the lid is open and I close it.
For the record. My notebook is docked in a station, so the power button is always available for me. Means, I can switch it on or suspend it without opening the lid.
Any better idea how to fix this issue?
UPDATE: I can't test it anymore because I don't have a docking station to my new notebook. So I can accept one of the answer if multiple people say this or that is the working solution.
For me, Sam's comment gave the working solution.
Edit the file
/etc/systemd/logind.conf
. You need to do this with root permission, so for example you can run this command:Just uncomment the line:
That is, change it to:
Save and exit.
This allows the docked laptop run with the lid closed or open.
Edit the file
/etc/systemd/logind.conf
change the line:
to:
Save the file and reboot.
After changes it should match my system:
Also check your Ubuntu power settings for what to do when lid is closed. For myself I have to open lid to access power button so the settings there are irrelevant. Since you can access power button with lid closed it may be significant.