Ok.. here is a cheat sheet for all the useful commands you might need.
Open a WSL session on your windows PC
ssh username@hostname.scottworld.net sudo -s (to become root/admin)
This will reboot the server (only really necessary after a kernel update)
reboot
This will cause the server to shutdown and power off - you will need to press the power on button to restart.
shutdown -h now
Occasionally you will need to make sure things are secure and up to date.
apt update (this will refresh the repositories and look for updates) apt upgrade (this will install any new updates) apt autoremove (this will remove any old packages that are no longer used)
This will list all disks and their current usage.
df -h
This is really handy to see what is going on. Open a 2nd WSL ssh session to the server and run the following to follow the syslog in real time.
tail -f /var/log/syslog
Use nano to edit files. Its is recommended you use TAB to predict the path and the file name.
nano /path/to/the/file
Exit the file and save after editing with
ctrl x (then press Y to save, followed by enter)
cd /path/to/location (change directory) pwd (show present working directory) cd .. (go up a directory) rm /path/to/file/or/directory -R (removes a file or directory the -R removes everything in it and under it) mkdir directoryname (makes a directory) rmdir directoryname (removes a directory) ls -l (lists the directory contents in a nice format) ls -la (lists the directory as well as hidden files in a nice format)
There is some useful stuff here
https://ubuntu.com/tutorials/command-line-for-beginners#1-overview