Saturday, April 20, 2024
HomeReviewsEverything You Need to Know About Linux Ubuntu Server

Everything You Need to Know About Linux Ubuntu Server

As you should probably know, Linux powers the majority of the web we see today. This is mainly because Linux systems are inherently more secure and stable than other systems. There are several types of Linux distributions for powering servers. Some notable ones include Ubuntu, Red Hat, Debian, and CentOS. Ubuntu, in particular, has been enjoying a surge in popularity as a server distro in recent times. In this guide, our editors have outlined why the Linux Ubuntu server is outgrowing many of its competitions. Stay with us throughout this guide to learn why Ubuntu shines as a server distro.

Learn More About Ubuntu Server & How to Use It


We have divided this entire guide into three parts. The first portion discusses the various things to know about Ubuntu as a server distro. In contrast, the second part shows users how to install and configure a working server using it, and the last part discusses what to do after installing Ubuntu server. Continue reading the following sections to learn some important information about the server.

A. Frequently Asked Question – FAQ


This section discusses some of the most asked queries regarding the Ubuntu server. As a Linux system administrator, you must know all these aspects, which ultimately helps you to deploy, configure, and use a Ubuntu Server successfully.

1. What is the Ubuntu Server?


It is an operating system developed by Canonical and a large number of open source developers across the world. It is meant to power modern-day servers that serve static and dynamic web pages, applications, files, containers, and many more. The ability to run this on a wide range of platforms and architecture make this a suitable choice for enterprises as well as hobbyists.

Linux ubuntu server

Moreover, Ubuntu boasts a stable and continuously growing ecosystem, which makes it easy to install and manage demanding applications. Although the core system is free to use, Canonical provides excellent support for enterprises via its modest subscription plans. No matter what type of platform you want to develop, Ubuntu will get you covered. It works extremely well with clouds and thus is a viable solution for cloud service providers.

2. Difference Between Ubuntu Server and Desktop?


If you are a predominantly desktop user, you might wonder what’s the difference between your everyday Ubuntu desktop solution and its server counterpart. Before we answer this question, let us discuss the dissimilarities between a desktop and a server first.

When talking about desktops, we refer to personal computers that we use for everyday tasks like productivity, gaming, and office works. These systems are equipped with peripheral devices such as a keyboard, mouse, and modems for obvious reasons. They are also powered by reasonable hardware resources. We usually use Linux desktop environments on these devices. The Ubuntu desktop is arguably among the best Linux distributions for such systems.

desktop vs server

Servers, on the other hand, are much beefier in terms of CPU resources. This is because they are designed to be more powerful, stable, and secure for long term usage. Since they are often managed remotely, most servers do not include common peripheral devices. This is known as a headless setup, obtaining the jargon from the omission of I/O devices. Traditionally, servers come in two form factors, either rackmount or tower.

3. Which Architectures are Supported by Ubuntu?


As we have said already, Ubuntu supports a wide range of hardware platforms or architecture for its server OS. The most commonly used platform is AMD64 or x86-64 architecture. This is the traditional 64-bit machines that power our personal computers. It also supports the older x86 or 32-bit platforms. So, you can also turn any older computer into a personal server.

Now, apart from these common ones, you can also run the server OS into mainframes and embedded systems. Ubuntu supports the IBM Z mainframes, IBM POWER pcs, and ARM-based server systems in this regard. This means you can not only fire up a server onto a legacy machine but will also be able to turn your Raspberry Pi into a mini server. It allows users to build exciting IoT projects using low-cost components. Go to this link to download the server image for your Raspberry Pi.

4. What Can I Run Using Ubuntu Server?


Developers can use this server OS for powering a large number of services as well as infrastructure. The most common use cases include website hosting, FTP servers, Linux email servers, print servers, database servers, media servers, container services, cloud services, and development platforms. These are only the most typical scenarios where someone might use Ubuntu. Of course, you can always get extra creative and develop something more useful.

5. How Popular is the Ubuntu Server?


Ubuntu has been gaining steady popularity as a server distribution for some time now. Many corporations are switching to Ubuntu from other server distros due to its solid ecosystem and reliable support. Among the 37% of global websites powered by various Linux distributions, Ubuntu accounts for a whopping 45% share. At the same time, competitors like the Red Hat Enterprise Linux (RHEL) has only a mere 2% share. Debian and CentOS, each has around 18% share in this regard.

trend comparison among Ubuntu RHEL Debian CentOS

So, it is pretty evident that Ubuntu is as popular as a server distribution as it is with desktops. Some of the factors that account for its continuously growing popularity are a proven ecosystem, friendly community, eas of use, and enterprise support. This is why even direct competitors like Microsoft are using Ubuntu for powering their Azure cloud services. The number of Ubuntu-powered services in the Amazon cloud is also twice that of all other os combined.

6. What Are the System Requirements for Ubuntu?


One key benefit of Ubuntu is that it does not require extremely high-end CPU resources. Although you would probably want to make your server hardware as beefy as possible, Ubuntu doesn’t force users to do this. It means you can easily build a personal or home server system using older hardware or by buying only some modest resources. The minimum system requirements for a simple server setup is given below.

  • 1 GHz CPU
  • 512 MB of RAMs
  • 1 GB of Disk Storage(1.75 for all features)

Canonical recommends the following requirements for a server.

  • 1 GHz or better CPU frequency
  • 1 gigabyte or more RAMs
  • Minimum 2.5 gigabytes of Disk Storage

7. Are Ubuntu Servers Stable?


Stability is a big concern when it comes to enterprise servers. Luckily, Ubuntu fares very well in this regard. The Ubuntu LTS or (Long Term Support) versions are supported for 5 years. This ensures that your server will receive all the necessary security patches as well as software updates. It helps reducing system vulnerabilities and allows admins to harden their system against malicious users. Check out our guide on essential Linux hardening tips to secure your server.

stability of ubuntu

Although many admins argue that Debian systems are inherently more stable than Ubuntu, their argument is not so strong. After all, Ubuntu itself is based on Debian. Moreover, Canonical is taking stability issues more seriously than ever and are working quite hard to maintain Ubuntu’s status as a reliable server distro.

8. How Good is the Enterprise Support for Ubuntu?


The availability of solid enterprise support is a big deal for businesses. Ubuntu does a pretty great job in this regard. Although the server distro is free and open-source, Canonical provides lucrative subscription plans for corporations that want to use Ubuntu as their server OS. The support plans include 24/7 security fixes, administration support, and help with OpenStack, Kubernetes, and Docker. Below is a summarized list of support plans.

  • Ubuntu Advantage for Virtual Machines – from $75 per year
  • Ubuntu Advantage for Enterprise Servers – from $225 per year
  • Ubuntu Advantage for Desktops – from $25 per year

Please check out the pricing plans on the Ubuntu website to get a detailed quotation on managed cloud services, storage, and infrastructure support. Overall, Ubuntu performs way better than its competitors in terms of paid support thanks to its robust pricing plans and quality assurance.

9. How Good is the Ubuntu Documentation?


Good documentation is really crucial when you are looking for a server distribution. Luckily, Ubuntu also does a damn good job in this aspect. You can relax knowing that whatever problem you may face in your server, the official tutorials and guides will help you overcome that. This is especially important for developers and system admins since, without proper documentation, they’d need to solve complex problems all by themselves.

official server documentation

The Ubuntu website provides all sorts of installation guides and configuration tutorials for the Linux Ubuntu server alongside supplementary utilities. The official server documentation is a good place to start if you are a server admin or developer. If you get stuck with some undocumented problems, you can always consult the various Ubuntu forums and IRC channels. We also cover a lot of fundamental knowledge that would be interesting.

10. How Supporting is the Ubuntu Community


An engaging community is a must for any open-source software. Thankfully, Ubuntu boasts one of the largest communities of developers and FOSS enthusiasts one can imagine. This is a great thing for a lot of reasons. For once, you can easily get essential advice and feedback on your server. No matter how complex a problem seems, the thriving community will always make sure that it gets solved in the least possible time.

community support

The Ask Ubuntu forum is one of my go-to destinations whenever I tackle a new kind of problems. A large number of veteran Ubuntu users work tirelessly for solving seemingly unsolvable problems. You can even find active Ubuntu developers on this forum. The Ubuntu IRC channel is another great place to strike a conversation with your fellow developers and admins.

11. Is Ubuntu Server Totally Free of Cost?


Yes, all variations of the Ubuntu system is totally free of any cost, both the server and the desktop. No matter whether you are an enterprise or a mere hobbyist, you only pay if you want to get professional support or managed enterprise solutions. The bare metal system is free all the time for anyone. This FOSS philosophy is one of the key reasons behind Ubuntu’s ever-growing popularity.

Moreover, the entire source code of the server is available freely. This allows enterprises to modify the system from scratch based on company requirements. However, you should not mess around with the source unless you are a professional developer who knows exactly what he’s up for. Nevertheless, the availability of the codebase is a big plus for a lot of reasons.

B. How to Install Ubuntu Server


Installing the server is a trivial process if you have got a display monitor connected to your machine. If a display is not set up, you can either install Ubuntu over the serial port or via an SSH connection. The latter method requires that the system is already connected to a network and is configured accordingly. The below steps show you how to install the server when a monitor is available.

1. Back-Up Existing Data


We always recommend our readers to back up their system before installing any new distribution. There are multiple ways to back up a Linux machine. However, we highly suggest users use a proven Linux backup utility like the Bacula enterprise solution. You can also just copy the entire disk to the cloud or to a private Linux NAS solution if you have access to one of those.

backing up existing system

If you are a home user, you can simply clone the hard disk to an external drive. This can be done very easily using the Linux dd command. Or, you can use another Linux disk cloning software such as Clonezilla or GParted. Nevertheless, you should always back up your current system unless you are installing the server on a brand new machine.

2. Create the Installation Media


The easiest way to set up a Ubuntu OS is to create a live bootable media such as a live USB drive. You can tackle this in multiple ways. However, we are not going to show the steps in detail here. If you don’t already know how to do this, follow the basic steps noted below.

  • First, download the Ubuntu ISO image from this page.
  • Format the USB disk appropriately and set up a Linux partition
  • Copy the ISO image to the USB disk using CLI tools or a GUI alternative
  • Enable booting from a removable drive in your system’s BIOS settings
  • Plug the installation media to the appropriate USB port
  • Boot into the live OS and choose Ubuntu Installation

3. Start the Installation Process


You can set up the server into your machine once you have successfully booted into the Live OS. An on-screen message will greet you with a welcome screen and display the available options. From here, the setup process is quite simple. The installation basically takes yours through all the steps. If you don’t need any custom settings, you can simply stick with the default options and press enter.

The first screen will ask you to choose your language from a set of options. This will provide the language during your installation and the default for your server. You can navigate around the options using the UP and DOWN buttons of your keyboard. Use the PageUP and PageDOWN buttons to go through a range of options like you are used to on your desktop. Press enter to select an option and proceed to the next stage of installation.

language selection

The next step will show if there are any updates for your installer. Ubuntu release images are updated frequently, and a new update will contain bug fixes and major software updates. This saves time after the installation process. However, you can choose not to install the updates if you want by selecting “Continue without updating” from this menu.

installer updates

Now, the installer will ask you to set the keyboard layout. The default is set to English(US). You can either change this or simply stick with the given one. If you are installing the Linux Ubuntu server from a remote terminal, you can guess the layout of the actual keyboard by answering some questions about the keyboard.

keyboard layout

This stage takes care of the network configuration for your server. The server installer will attempt to configure ethernet network interfaces via DHCP. Ubuntu utilizes a netplan for network configuration in this step. Apart from static DHCP, it can also set up VLANs and bonds. However, you can simply skip this step and proceed to the next step of the installation.

network configuration

Ubuntu will ask the admin to set up any proxy during this step. You should not configure the proxy policies in this step unless it is mandatory. Nevertheless, if you choose to set up a proxy for your server, the installer will use it to access the package repositories and the snap store during and after installation.

proxy configuration

The following step will try to select an appropriate mirror using your GeoIP. Ubuntu has several mirrors of its package repositories around the world. You can either select the recommended mirror or provide a specific one using its URL in this step.

ubuntu mirrors

Now, you will need to set up the storage for your server. The simplest workflow consists of checking the “use an entire disk” option and then choosing a disk to install the Ubuntu server. Select done on the installation screen and confirm the installation process. However, you may also be interested in setting up LVM and LUKS encryption for added security. If you set up encryption, then you will need to use the secret password each time the server boots.

storage configuration for ubuntu server

You can also select “Custom storage layout” for a more customized storage configuration. This will forward the installation process to the main storage customization screen. The following options will allow you to create new partitions and format existing ones alongside other operations. Admins can also create RAID(Redundant Array of Inexpensive Disks) configurations during this step. The server installer can create RAID setups using the RAID levels 0, 1, 5, 6, or 10. Check out this guide to learn more about Linux RAID documentation.

more storage configuration

Once you have completed the storage configuration, the actual installation process starts. The installer will copy all the necessary files to your system in this step and will take about 10-20 minutes. You can not revert any changes made in the earlier stages once the installation begins. So, make sure that everything is set up correctly.

set user profile

After the setup finishes successfully, you will be presented with a screen where you need to provide your Ubuntu profile information. Simply enter the username, hostname, and password for your administrator account. The next screen will ask you to configure the SSH access to your server.

ssh configuration

Usually, most servers are managed over a remote SSH login. So, you may want to install the OpenSSH server in this step. You can import SSH keys from either GitHub or Launchpad. By default, password login is disabled whenever a key is imported. However, you can revert this later. You can also ignore ssh configuration in this stage and simply select “Done” to go to the next step.

snaps collection

This step will display a list of snap packages that may come in handy for server setup. You can check the ones you want to install using the navigation keys or omit this step. The following screen will display the installation log alongside the progress. Once completed, you can view the full log or reboot the system. The server is now installed and ready to use. Simply log in using your username and password once the system boots again.

C. What to Do After Installing Ubuntu?


Once the installation process is finished, you need to set up the server for day to day use. This process is not trivial and may vary based on your requirements. Nevertheless, we have prepared a list of things to do after installing the Ubuntu operating system. Check out that guide and perform the tasks that are needed by you.

You may want to keep your server to the bare minimum and omit things like graphical software installation. This will help you maintain a lean setup and will reduce the occurrence of unwanted bugs. Admins also need to harden their Linux system in order to thwart off malicious users and activities. We have created a dedicated guide to help admins secure their servers earlier. Check that out to implement some proven security policies. The following sections provide additional information on some essential tasks.

1. Package Management


Admins usually spend a large amount of their time installing and updating packages on the server. Luckily, Ubuntu makes it very easy to manage your packages. The preferred way of package management is the APT(Advanced Packaging Tool) command-line utility. We are illustrating some primitive usage of the apt command in Linux here.

$ sudo apt install nmap

This command will download and install the Nmap package on your server.

$ sudo apt remove nmap

This command will remove the Nmap package. You can specify multiple package names in the same command.

$ sudo apt remove --purge nmap

Adding the –purge option will delete all configuration files related to Nmap.

$ sudo apt update

This command updates the local package index and will include the latest changes.

$ sudo apt upgrade

Run this command after updating the package index for upgrading your packages to their latest available versions. You can also use the Debian package manager(dpkg) for installing local packages. However, try to avoid removing or upgrading packages using the dpkg utility.

$ wget https://ftp.tw.debian.org/debian/pool/main/n/nmap/nmap_7.70+dfsg1-6_amd64.deb

This command will download the Debian package for Nmap. Now, we can install it using dpkg.

$ sudo dpkg -i nmap_7.70+dfsg1-6_amd64.deb

Use the below command to display a list of all locally installed packages using dpkg.

$ dpkg -l

The output will be quite long, so it’s a good idea to use a filtering tool like the Linux grep command for locating specific packages.

$ dpkg -l | grep chrome

Use the following command to display all files that are installed by a specific package.

$ dpkg -L vlc

2. Server Security


No matter whether you are running a professional server or a personal one, you’ll be seeing intrusion attempts all the time. Malicious users have progressed a lot in the last couple of years, and many servers remain vulnerable to various types of attacks. You must enforce industry best practices to keep your server out of these guys’ reach.

server security

Server security is a broad topic and requires years of experience as well as patience to master. You should check out our earlier guide on essential Linux hardening tips to get started in this regard. Some of the must enforce rules include user account management, password expirations, SSH access control, appropriate IPtables & firewall configuration, disabling unused services, and so on. You may also want to install some essential open source security solutions.

3. Virtualization


Virtualization allows companies to run multiple services in secure and isolated environments. Most servers use some sort of virtualization technologies for using their CPU resources efficiently. Ubuntu server supports all major forms of virtualization, including hypervisors-based and OS-based. KVM or (Kernel Virtual Machine) is the default virtualization technology on Ubuntu. It is available for all major platforms, including Intel, AMD, ARM64, LinuxONE, and IBM POWER.

Linux containers virtualization

OS level virtualization can be achieved by using a platform like Docker, Linux Containers, containerd, or systemd-nspawn. Enterprises usually use Docker for applications that require extensive scaling and frequent modification. We have already covered how to install Docker in Linux, and some essential Docker commands for admins. On the other hand, LXC or Linux Containers provide isolated environments that can be treated as lightweight Linux virtual machines. Check out this guide to learn everything you need to know about Linux containers.

4. High Availability


High availability or HA clusters are a set of machines that power critical applications with an aim to reduce or eliminate server downtime. This is used by enterprises for in-demand databases, network file servers, and commercial applications, among many more. Ubuntu offers excellent support for high availability computing and comes with a wide range of tools that allow the creation and management of robust clusters. Admins can develop highly fault-tolerant infrastructure using Ubuntu’s HA utilities.

ubuntu HA

Linux Ubuntu server provides everything needed for cluster heartbeat, quorum, and fencing. Canonical offers a large number of core HA packages such as Kronosnet, Corosync, Pacemaker, DRBD(Distributed Replicated Block Device), and DLM(Distributed Lock Manager). There are also many community packages for high availability computing, like Corosync-Qdevice and SBD(STONITH Block Device). Overall, you will get all the tools and support for maintaining efficient HA clusters.

5. Essential Tools


We will recommend some essential tools for a Linux server in this section. First up is logwatch, a powerful yet versatile log analyzer that provides crucial information regarding all types of activities in your server. Visit this page to learn how to install and configure the logwatch.

Byobu is a wrapper around the GNU Screen terminal multiplexer or tmux. It is installed by default on your server and allows admins to run multiple terminal sessions and tabs over remote connections.

The etckeeper utility is a robust version control mechanism that stores the contents of /etc into a repository. It integrates itself with APT and commits changes to /etc to the repository each time a package operation takes place. Version controlling the /etc has become an industry best practice due to its usefulness. Visit this page to learn more about etckeeper.

SysAdmins spend a large portion of their time monitoring servers and networks. There are several effective monitoring tools at the disposal of a Ubuntu admin. Nagios and Munin are two popular and free open-source applications that allow admins to monitor server systems, networks, and infrastructure. Visit this guide to learn more about Nagios and this one for Munin.

The Rsnapshot utility is an excellent snapshot taker for Ubuntu. It is based on the rsync tool and allows admins to take incremental backups of the Linux file system. Rsnapshot works well with both local and remote filesystems and is thus a viable solution for remote server administrators. You can learn more about Rsnapshot on this page.

6. Useful Services


Web servers typically run various services based on enterprise or personal requirements. Here, we will discuss some of the common services you could use with your Linux Ubuntu server. First, talk about databases. The most popular database choices for Linux are MySQL and PostgreSQL. Ubuntu offers both of these via the main repository and provides the necessary support.

postgres vs mysql

Ubuntu allows admins to set up file servers, domain controllers, print servers, active directory, and other resource sharing services using Samba. It makes it easy to create a stable and coherent infrastructure consisting of multiple Ubuntu and Microsoft Windows machines. You can also integrate Samba with an LDAP backend.

Servers powered by Ubuntu use CUPS (Common UNIX Printing System) as their print service. It allows admins to manage print jobs, queues, and network printing using the Internet Printing Protocol(IPP). CUPS has in-built support for a wide range of printers and can detect network printers automatically. Moreover, the simple web interface makes it very easy to configure and administer CUPS.

ubuntu cups server

Ubuntu provides excellent support for BIND (Berkley Internet Naming Daemon). It is the most popular Linux program for creating name servers. Admins can use this tool for easily setting up a DNS service on their server. These services map IP addresses to fully qualified domain names (FQDN) and vice-versa. Please visit this page to learn how to set up a DNS service on Ubuntu.

FTP servers are the preferred way of transferring files within an infrastructure. Ubuntu provides the FTP daemon vsftpd for setting up a working file server. Visit this guide to learn how to install, configure, and secure an FTP server powered by Ubuntu.

Kerberos is a network authentication system that works by establishing a trusted third party. Although not all applications can use Kerberos, it is still a viable choice for setting up a secure network services infrastructure. You can easily install and use Kerberos on your Ubuntu server. Follow this guide to learn which packages to install and how to configure Kerberos in Ubuntu.

Kerberos administration

You may use the OpenLDAP implementation for setting up an LDAP service in your Ubuntu environment. It uses the LDAP protocol for setting up active directory services. These are highly customizable information stores that serve as a single point where a user can search and locate resource information for all services spanning over a distributed infrastructure. Visit this guide to learn more about Ubuntu OpenLDAP services.

If you want to set up a VPN (Virtual Private Network), you can use the OpenVPN application. It provides a simple, flexible, and secure way of creating a VPN service. Setting up an OpenVPN service takes time and requires detailed planning. For now, you can visit this guide to learn the basics of OpenVPN on Ubuntu environments.

You can also use your Ubuntu system as a Linux mail server. Mail communication is a complex process that involves many steps and protocols. Usually, the sender sends the message using an email client or Mail User Agent (MUA). This message is then transferred across a number of Mail Transfer Agents (MTA) before ending up in a Mail Delivery Agent (MDA). The MDA then sends the mail to the recipient’s mailbox. Ubuntu supports many MTA’s, including Postfix and Exim4. Dovecot is a popular MDA supported by Ubuntu.

ubuntu mail server

Squid is a reliable caching and proxy service supported by Ubuntu. You can use this software to set up proxies for all major network protocols, including HTTP, FTP, and SSH. Visit this guide to learn more about how to use Squid on a Ubuntu Linux environment.

Apache is the go-to choice for setting up a web server on Ubuntu or any other Linux environments. We have already covered this in our earlier guide on Linux LAMP installation. However, the Ubuntu documentation on Apache is also a good place to start. Nginx is another popular web server that can also be used as a load balancer and reverse proxy. Check this guide to learn everything you need to know about the Nginx web server.

Ending Thoughts


The Linux Ubuntu server is a solid choice for building demanding infrastructures. What makes Ubuntu stand out from others is its excellent community as well as ecosystem and enterprise support. No matter whether you are looking to build a complex IaaS platform or a personal home server, Ubuntu has you covered. Our editors have curated this guide with everything you need to know for running Ubuntu as a server environment. This is especially suitable for users who are yet to try their hands in a server environment. Hopefully, you have gained the insights you were looking for. Leave us a comment below if you have any specific questions.

Mehedi Hasan
Mehedi Hasan
Mehedi Hasan is a passionate enthusiast for technology. He admires all things tech and loves to help others understand the fundamentals of Linux, servers, networking, and computer security in an understandable way without overwhelming beginners. His articles are carefully crafted with this goal in mind - making complex topics more accessible.

1 COMMENT

  1. I am switching from Windows to Linux after reading your blog, and some of these benefits amazed me, as I wasn’t aware of them.
    Thanks for sharing.

LEAVE A REPLY

Please enter your comment!
Please enter your name here

You May Like It!

Trending Now