I was annoyed when a newly installed machine running Ubuntu 18.04 Desktop crashed when connecting to user accounts served remotely via NIS. Ubuntu v16 worked fine. What was wrong? After many blind alleys I found these steps online somewhere and this solved the problem for me.
$ sudo cp /lib/systemd/system/systemd-logind.service /etc/systemd/system/ $ sudo vim /etc/systemd/system/systemd-logind.service $ diff /lib/systemd/system/systemd-logind.service /etc/systemd/system/systemd-logind.service 37c37 < IPAddressDeny=any --- > IPAddressDeny= $ sudo systemctl daemon-reload $ sudo systemctl restart systemd-logind.service
I was encountering the following error message in /var/log/syslog.
systemd-logind[782]: do_ypcall: clnt_call: RPC: Unable to send; errno = Operation not permitted
The solution (that worked for me) was found among replies to a bug report, after I dug through things for a while.
I post this here in the hope that it will help someone else in the same situation.