[ITP: Understanding Networks] Setting Up a Linux Host

I followed Professor Igoe’s articles on how to set up a virtual host and how to configure a firewall and here’s a quick recap on the process. First off, a virtual host is just a computer system attached to the internet.

Create Droplet

Digital Ocean is a platform for virtual hosting, so I started off by creating a new account by logging into my GitHub account. One thing I haven’t been successful with yet is setting up the student credits but I think I’m using some sort of other free trial which should work for now.

Each individual host is called a “Droplet”. So, in your Digital Ocean account choose “Droplet” from the side menu. Then hit the green “Create” button > “Droplets”. Next, configure your Droplet with the parameters shown below.

  • “Ubuntu” image

  • “Basic” plan

  • Cheapest subscription plan

  • No block storage

  • Pick NYC datacenter

  • Choose hostname and password

  • Create Droplet!

Using my “Terminal” program to log into my new virtual host!

Configure Droplet

Add Users

Next, I needed to setup a user. The first user on any POSIX host is called “root” but it is not advised to operate as the “root” user. Once the new user is created, you can use the “sudo” keyword to perform tasks as the superuser. So once the new user is created it needs to be added to the superusers group.

Update the operating system

Use the “apt” keyword (Advanced Package Tool) to update the Ubuntu operating system. Then, I used the “apt” command to install the Uncomplicated Firewall. A firewall sets the rules for what you device’s network interfaces should do with incoming or outgoing data packets.

I also installed other tools such as “network tools” and node.js which is a tool for server-side programming in JavaScript.

Configure Firewall

I followed the second article to setup my firewall. The first image shows how I enabled certain ports of my firewall to receive communications. The second image shows my setup Uncomplicated Firewall. Now my virtual host is up and running and protected by a firewall!

Loose Ends

One weird thing that I ran into a couple of times was this error message that my kernel was out of date. I did reboot my host, so maybe that fixed the issue?! I’ll keep an eye out for it in the future.