How To: Disable Sleep/Hibernation on Ubuntu Server

*~grumbles~*

Seriously! My log contained lovely hints like:

[code]Apr 3 12:18:27 server systemd[1]: Reached target Sleep.[/code]

[code]sudo systemctl mask sleep.target[/code]

[code]sudo systemctl mask suspend.target[/code]

[code]sudo systemctl mask hibernate.target[/code]

[code]sudo systemctl mask hybrid-sleep.target[/code]

[code]systemctl status sleep.target[/code]

Finally, thanks for reading. Like always, I love the feedback and the newsletter is still there waiting for you to sign up. If you do sign up, I chose a pretty crappy domain name and you should probably check your spam inbox for the confirmation email.




Let’s Spin up a Quick Python Server!

What to do? What to do?

SSH (secure shell) enabled on your desktop (in this scenario) and that you know how to use it. So, it’s with a giant assumption and a leap of faith when I say that you’ve successfully used SSH to get to your desktop and you’ve already navigated to the directory where this latest and greatest distro image resides.

SCP (secure copy protocol) if you wanted. That’s all well and good, but darn it we’re aiming for the most contrived situation possible just so I can tell you how to spin up a server with Python! So, for whatever reason, you’re hellbent on doing this in your browser. And do this in your browser you shall!

contribute to the site!

[code]python -V[/code]

[code]python -m SimpleHTTPServer[/code]

[code]python3 -m http.server[/code]

[code]ip.address.of.desktop:8000[/code]

You're effectively running a simple server.

access by hostname
See? No IP address required! You can also use this for the above mentioned SSH!

Now, if you want to do so, you can also change the port number. This is the same for both commands. In both cases, just add your chosen port number at the end. Like so:

[code]python3 -m http.server 9000[/code]

And, again, it should look a bit like this:

See? It's a different port number.
Note the changed port number. You should probably avoid reserved ports.

[code]wget http://kgiii-lmde.local:9000/debian-10.8.0-amd64-DVD-1.iso[/code]