0

I am dual booting ubuntu 20.04 desktop on my mid 2012 macbook pro. I'd like to run it as headless server with the lid closed. To try to do this I set systemctl default to multi-user, disabled gdm, and set grub to boot into single user mode. Everything is working fine (~2% CPU) when I have an external monitor plugged in but as soon as I unplug the external monitor cpu usage spikes (~40%), and systemd_logind starts running reportedly using ~80% cpu. When I plug the external monitor back in systemd_logind stops using a bunch of cpu and the system goes back to around 2% cpu.

Any suggestions would be greatly appreciated.

PS: I tried to install ubuntu server originally, but it wouldn't let me do the partitioning the way I needed to dual boot, so i had to use desktop to install.

badi95
  • 1
  • 2

1 Answers1

0

Follow suggestions from @denzel to run journalctl -f while unplugging got me:

systemd-logind[772]: Suspending...
systemd-logind[772]: Unit suspend.target is masked, refusing operation.
systemd-logind[772]: Failed to execute suspend operation: Permission denied

So I googled a bit and found this answer askubuntu.com/a/1180519/1132566 Which seemed to fix the issue.

badi95
  • 1
  • 2