Server week : The essential SSH Server.

Mar 18

This week in “Server week” we are going to set up a variety of servers that allow you to do a variety of things. One of the most basic and versatile server you can set up must be the SSH Server. Long time fans probably know that the SSH server is the base ingredient for a lot of fun stuff you can do. For example.

  • Transfer files over the internet.
  • Work with command line applications from a remote computer.
  • Tunnel your browser traffic through your own server to stop nosy network admins.
  • Connect to your home network with a VPN connection.

These are just a couple of things you can do, but before you can do that, you will need the basic ingredient : Let’s set up an SSH Server.

MOTD_TAIL

Required ingredients.

  • Debian based Linux distribution : ( you can do it with a redhat based one too, but we use a debian based one for the tutorial)
  • Static ip for your Linux distribution.
  • Connection to the internet.
  • If you don’t have a static IP : A dynamic DNS service like opendns or Dyndns.
  • An open port on your router forwarded to your linux machine.

Let’s get cooking.

  • Open up a terminal on your linux machine and type : sudo apt-get install openssh-server
  • After the server is installed, connect to it from a remote machine using a terminal application like Putty (for Windows) Secure Shell (for the Chromebooks) or from the terminal on other Mac and Linux machines.
  • Connect to your Linux server with the command : ssh yourusername@theipofyourserver

And starting out that is ALL you need to do. If you want to do this from the internet you need to forward the correct port (The standard port is Port 22) from your router to your linux machine so you can make it accessible from the internet.

Lets make it pretty.

Lets make it secure.

  • SSH servers run standard on port 22, so a lot of scriptkiddies will go around the internet and “knock” on your port 22 to see if there is a server there. We are going to “obscure” the location of your SSH server a little by changing the default portnumber (Remember you also need to adjust this on your server) Follow THIS tutorial to get you started.
  • Next time you connect remember to connect with ssh -p portnumberyouchose yourusername@theipofyourserver
  • If you want to get rid of entering your password when you connect you can log in using secure SSH keys. Its a little bit on the advanced geeky side but it DOES keep your machine extremely secure : Only a machine with a unique digital fingerprint can connect using this method : Here is a good tutorial.

Lets start using it.

The SSH server offers you a variety of functionalities we talked about in previous blogposts. We will line up the best uses for SSH here.

These are just a couple of examples of what you can do over this very powerful little SSH connection. Remember always to use strong passwords and keep your server up to date.  Have fun ! 

Related Posts

Server week : Why not “roll your own private little cloud”.

Mar 10

Cloud services. We love them ! All you need to do is hand over your email address, use the same password you have everywhere and sito presto : Before you know it you are using yet another free service that does whatever you require. From handling your email, to storing your documents, from chatting with your friends to keeping track of all the Care-Bear stuff you track on line .. there is a cloud service for everything.

Screenshot-9

We are not always the customer, sometimes we are the product.

What most of us forget is that, unless you are paying for said service, you are not a customer, but a product. If your free cloud service has any plans about staying in business and paying that giant hosting bill for that ‘free storage’, it’ll better have a business plan. Most cloud services make money by selling you adds that you click on. The people who PLACE the adds are the actual customers of the service ..  YOU .. are the product. This might not be true with a paid service ( Another way of working for a cloud service might be to get you hooked with a free account and then make you UPGRADE into a subscription plan). So if you are using that favourite cloud service of yours, ask yourself : Am I ok with being “The Product” ?

Just “Who IS” the cloud ?

Behind every fancy logo or snazzy name is a company. That company can be  a multi brazillian dollar company who buys up instant messaging clients for sixteen billion the way you buy new socks. It might also be two crummy guys sitting in their moms basement remote controlling their servers somewhere else. You  only see the flashy logo,  you never read the terms of service (just click agree-agree-agree) and have no idea of who might be looking at your data. Who knows you may have signed over the creative rights of your summer snapshots to the cloud company that turns it into a “Free online picture-slideshow”.. because you never read the terms of service.  And for the sake of argument : What if there is a problem you can’t fix ? Who are you gonna call … Chances are you will probably get to talk to the REAL Ghostbusters before you get a living person on the other end of the line at your “free cloud service”.  So are you safe ? Is the data yours ? What happens if the bubble bursts and the service goes away  ? 

So what if you rolled your own ?

If you make it really simple you can say that cloud services are just servers running on applications. ( But they are actually spread out on servers all over the world and are optimised for coping with a LOT of simultaneous users). But what if you don’t need that ? What if its just you and your dog using them ? Then you could basically run them yourself right ?  The answer is : YES. It takes some tinkering and having at least one machine that is online for most of the time to make sure your “private cloud” is accessible but aside from a little patience, a spare machine and an internet connection, its about ALL you need.

I don’t trust cloudy skies.

This week we boldly choose to chose “DISAGREE” on the terms of service of the cloud providers, we decide NOT to trust their free business model and we venture out on our own little geeky adventure : Rolling our own private cloud. The luxury of a cloud service, but being run on your own hardware, in your own home (or on YOUR webspace) with YOU in control. We will try to show you some great examples of just how much fun you can have while being your personal cloud provider. Most if not all services we will setup can be hosted on a Linux virtual machine and are accessible from any operating system (or device) that is capable of connecting to the internet.

Enjoy.

Related Posts