Recently a client asked me to install a server at their small business. The server will perform a number of functions including file server, domain name server, email server and web server. In this series of posts I’ll cover setting up a Linux small business server (SBS) using the Ubuntu 6.10 Server.
Before continuing I should explain the network setup. The network consists of a couple of PC’s connected using multi-port ADSL router. I don’t want to change the network configuration so I’m going to leave the router handling Internet sharing (NAT), network firewall and DHCP. I will need to tweak the DHCP settings so that computers on the clients network use an internal domain name server (DNS) instead of using the router as their domain name server. I’ll explain why in my post on setting up a domain name server.
Choosing a Linux Distribution
The first think I needed to do was choose a Linux distribution to use as the base from my small business server. In the past I’ve used a number of distributions but I’ve never been really happy with using these as a server. Most want to install a GUI and you find your server running a lot of processes that really aren’t required. By contrast the Ubuntu server installs so few processes that you can’t even access it remotely until you install the ssh server.
Installing the Ubuntu server
I’m not going to talk too much about installing the base Ubuntu server. What I will say is that I choose to not do a LAMP or DNS server installation. This left me with the cleanest possible server to which I will add services as I need them.
Allowing remote access
Once the server has been installed the first thing you’ll want to do is enable remote access. This will allow you to install the other services over the network and administer the server without needing to go to the console. Installing the ssh server is as easy as logging into the server console and typing
% sudo apt-get install ssh-server
You will now be able to access the server from computers inside the business using ssh. As I want to be able to access the server from outside the clients network I need port forward TCP and UDP port 22 from the ADSL router to the server. With port forwarding enabled I can ssh to the server from outside the clients network by using the public IP address of the ADSL router. The router will then forward the packets to/from the server. How you setup port forwarding is beyond the scope of this post because it will vary from one router to another.
Warning: Don’t enable port forwarding if you don’t need it. The more ports you forward to your server the more exposed your server is and the easier it will be for someone to hack into it.
In the next post I will cover installing the domain name server.
This site contains my personal ramblings on Linux, PHP, Java, .NET and anything else that I feel is important.