I am running Centos 7 and all I want to do is make my computer go to sleep immediately. There is a setting I have set to make my computer go to sleep but only after a certain amount of inactivity but when I leave work, I want to be able to make it go to sleep immediately right after instead of turning my computer off.
I looked and found this link https://www.cyberciti.biz/faq/linux-command-to-suspend-hibernate-laptop-netbook-pc/ and I tried both commands
sudo systemctl suspend
sudo systemctl hibernate
and get the message
A dependency job for suspend.target failed. See 'journalctl -xe' for details.
I just want to be able to make my computer go to sleep so that I can pick up from where I left off the day before instead of turning off my computer everytime I leave from work.