I have a computer that has 7 drives, running Ubuntu Server 18.04, and is used as a low power file server. But for now, I can only SSH within the local network. I would like to know how to access my "server" over the internet.
Classic basic networking question. Since your server works on the LAN, your server works. Everything else is networking that is unrelated to Ubuntu.
Your public internet IP address is your ROUTER's IP address. That's what a router does - it shares your public IP address among all the devices on your LAN.
- Find your PUBLIC IP address. Any search engine will tell you how.
Pick a PORT NUMBER. For ssh, you can forward port 22...or any other port number.
Login to your router. Turn on Port Forwarding. Forward the PORT NUMBER to your server's LAN IP address.
Test login from the LAN:
- You already did this, so it should work. This simply tests that your server is still up and running at the expected LAN IP address.
Test login from the internet:
ssh user@public_ip_address -p port_number
- This WON'T work when you are connected to the LAN. You need to be outside the area controlled by your router.
-p port_numberonly needed if you picked a different port number.