I am trying to hibernate from cron using the command systemctl hibernate
. However, I am getting the following error:
Failed to set wall message, ignoring: Interactive authentication required.
Failed to hibernate system via logind: Interactive authentication required.
Failed to start hibernate.target: Interactive authentication required.
See system logs and 'systemctl status hibernate.target' for details.
If I execute the above command manually from terminal, it works as expected.
How do I hibernate from cron?
I am using Ubuntu 16.04.