Set up a multipurpose home server

Data Diviner

© Lead Image © Maxim Kazmin,

© Lead Image © Maxim Kazmin,

Article from Issue 202/2017

Install a home server to make your data omnipresent.

These days a server isn't something that you'll find only inside a corporate environment. With the proliferation of computing devices inside a typical home, it makes sense to create your own always-on server for your household. You can use your home server as a central media hub to stream videos, music, and pictures to other devices connected to your network. Another popular use for such a server is as a dedicated seed box for downloading and seeding content (legally, of course) such as Linux ISOs or software from the Internet Archive.

Amahi [1] is a free, open source home server solution based around Fedora Linux. It's flexible and customizable, easy to install, and has lots of pluggable apps that you can install with a single click to extend the features of the server to suit your needs. For example, Amahi includes a DLNA server and several streaming servers to broadcast all kinds of multimedia to compatible players and devices. It also includes Greyhole for pooling disks into a unified network storage medium that you can then use to create shares that can be accessed via the Samba protocol and even used as a network backup target. Amahi also comes with a free dynamic DNS name that you can use to access your files from anywhere on the planet.

Amahi has modest hardware requirements, which is why it's often touted as a solution for putting an old unused computer back into active duty. It can manage a small network from a computer with a 1GHz processor and 512MB RAM. Deployments on larger networks where multiple users are shuttling oodles of data running several different apps will require a multicore processor with at least 4GB of RAM and ideally multiple hard disks.

Get Amahi

At the time of writing, the latest stable version of the server is Amahi v9. The developers recommend rolling it out atop a Fedora 23 installation. Before you get started with Amahi, follow the instructions in the "Install Fedora Server 23" box to set up a dedicated machine for the Amahi Server using the Fedora netinstall ISO to install a minimal server.

Install Fedora Server 23

Amahi is best set up on a headless server that's always powered on, especially because it's serving essential services like DNS and DHCP. The Amahi developers recommend implementing it on top of a minimal Fedora Server installation. Grab the 64-bit netinstall ISO [2] and burn it onto an optical disk or transfer it onto a USB disk. Boot from the media and begin the installation. Fedora's Anaconda installer uses the hub-and-spoke model and will bring you to the Installation Summary screen from where you'll have to configure the various essential aspects of your particular installation. Anaconda should automatically pick the correct keyboard and time and date settings.

Next up is partitioning. Feel free to partition the disk as you see fit. You can also let the installer partition the disk automatically but make sure you don't use the LVM partitioning scheme as that allots a majority of space to the /home partition, which isn't used by Amahi. Instead use the Standard partitioning scheme to make sure the Amahi shares and web apps get the maximum space. Similarly, if you define the partitions manually, make sure the new mount points you add are Standard partitions. Secondly, in the Software Selection section you'll have to toggle the Minimal Install checkbox. Finally, while the installer copies files to the hard disk, you get the option to define a user and set a password for the root user. Amahi developers advise you to not define a password for the root user and instead add a user and toggle the checkbox to give Administrative permissions to this user.

Once your minimal Fedora 23 server is up and running, switch to any other machine with a functional desktop environment and head to Amahi's website and click the big green Get Started Now button to register with the service. The sign-up process is fairly straightforward and, besides the login credentials, also involves picking up a username that will help determine your Dynamic DNS URL.

Once you've registered, log in to the Amahi dashboard on the website and click the ConfigureYour HDA button. An HDA or Home Digital Assistant is Amahi's way of referring to your Amahi Linux home server. The configuration process will walk you through a couple of pages requesting various information about your network setup. You'll be asked to enter the gateway address of the network that will host the Amahi server. This is the IP address of the wireless or wired router in your home network that provides the network settings for the rest of the network. Depending on the make and model of your router, the IP address for the gateway is typically,, or To figure out these settings under Linux, enter the route command in a terminal and make a note of the address listed under the Gateway column for the default route.

Next up, you'll have to enter the fixed IP address that will be used by the Amahi server. Usually it's safe to go with the default suggestion, unless you've already assigned the listed address to another server on your network. For this tutorial, let's assume this to be The third and last setting you'll be prompted for is the local DNS domain name. This is the name for your home domain so you can change it to whatever catches your fancy. Do keep in mind that your network shares and Amahi apps will be accessible via this domain, so make it something meaningful.

Once you've entered the requested information, click the Create Your HDA Profile button, which will bring up a page with the necessary information required to setup your Amahi HDA. Make a note of the install code shown on this page (Figure 1).

Figure 1: You can also ask Amahi to email you the install code along with install instructions.

Roll Out the Server

Now head to your Fedora server, fire up a terminal window, and switch to the super user root with su -. The first order of business is to download and install Amahi's repository with:

rpm -Uvh

Once the repository has been installed, grab the server with:

dnf -y install hda-ctl

When these packages have been download, you can install Amahi using the install code shown earlier with:

hda-install <the-install-code>

This will configure the Amahi server as per the settings you provided earlier.

That's all there is to it. You don't have to manually edit any configuration files or tweak network settings. Amahi does it all for you automatically. When it's done, simply reboot the server (Figure 2). Once it comes back up, you'll have a fully functional home server that's initially accessible via the static IP address you set up previously (, in our case). The first time you fire up your Amahi server's web interface, you'll be asked to create a dashboard admin user. It's a safe bet to supply the authentication information for the user you created while installing Fedora server.

Figure 2: You can install Amahi on a headless server via SSH, which is installed as part of the minimal install selection.

By default, Amahi wants to manage your network and hand out IP addresses to all connected machines on your network and resolve websites. This allows all machines on your network to access the Amahi server, the apps running on the server as well as the shares with human readable names instead of IP addresses. However, most users already have a DHCP server on their router. You can, of course, continue using the router's DHCP server and just use Amahi for DNS, which still lets you access the server and the apps with friendly names. However, there are some trade-offs as mentioned in the "Not Using Amahi's Core Services" box.

Not Using Amahi's Core Services

To take advantage of all of Amahi's network conveniences, you need to let it handle the DHCP and DNS services for the entire network. However, it is flexible enough to let you turn these off and instead continue using them from the existing source, which for a majority is the router. There are, however, disadvantages when you prevent Amahi from running these services.

If you continue using your existing DHCP server and only use Amahi for DNS as described in the tutorial, you'll still be able to use a majority of Amahi's network conveniences and functionality across all machines in your network. First, you'll be able to access the Amahi server using the http://hda address from all machines. Second, all computers in your network will be able to use the apps installed on the Amahi server using their network-friendly URLs, such as

If you don't tweak the DNS settings in your router, you'll still be able to access the Amahi server by pointing to the server's complete IP address, such as, instead of the short address. Similarly, the other machines will also be able to access the file server when you point them to the server's URL. Some apps and services like UPnP might also be able to stream to other machines, but their performance isn't guaranteed.

To continue using your router's DHCP address, fire up the Amahi server's web interface and login. Now head to Setup | Settings | Details and toggle the Advanced Settings option. After the advanced settings have been enabled, head to Network | Settings and disable the DHCP server by unchecking the checkbox adjacent to the option labeled DHCP. The next important task is to ask your local network to use Amahi Server's DNS to access the Amahi apps. The exact process for this step varies from one router to the other. Generally, you open the router's admin page in your browser and look for the page that lists settings for the DHCP server on the router. Among other settings on this page, you can enter the static address of the Amahi server as both the Primary and Secondary DNS servers (Figure 3).

Figure 3: The DNS Server 2 is optional and can be left blank.

Bear in mind though that after you've tasked Amahi with resolving DNS you'll have to make sure that the server running Amahi is up and running before any client can access the Internet. If the Amahi server goes down, the computers on the network will not be able to resolve websites until the server running Amahi comes back up again. If you ever take down the Amahi server, don't forget to hand over the DNS function back to your router. Once you've set up Amahi's DNS, you can access your server by pointing your web browser to http://hda (Figure 4).

Figure 4: By default, Amahi lists all the installed apps on its simple dashboard, but you can also access them directly via their friendly URLs.

Share Files

You can now start configuring the home server as per your requirements. The first order of business is to create users who will interact with the server. At this point the server has only one user that's also the Administrator by default. You should create other users depending on the number of users that are connected to your network and will be using the data in the Amahi server either directly or via its many apps.

To add a user, head to Setup | Users and click the New User button at the bottom of the page. This opens up a brief form and prompts you for full name and authentication information for the user. Once a user has been added, it's displayed in the users table along with the other users. To edit a user's detail, click on their username in the table. You can then edit their details and even toggle the Admin checkbox to make them an administrator on the Amahi server with the same privileges as that of the first user.

Once you've defined the users, it's time to manage network shares, which is one of Amahi's core functions. By default, Amahi creates a bunch of shared folders (books, movies, music, pictures, etc.) that are accessible to all users. To view and configure them, head to Setup | Shares.

You can further customize an individual share by clicking it. This brings several options related to that particular share. From here you can reset a share's permissions, control access, and even delete the share entirely. By default, all shares are available to all users. To specify users, uncheck the All Users checkbox. This displays a list of users on the server and lets you select which user has read and/or write access to the folder (Figure 5). To create a new share, scroll down and click the New Share button. Give it a name, and set it to visible. After it's been created, you can repeat the process described earlier to control access and permissions.

Figure 5: Amahi's access control skills are rudimentary but enough to be effective.

You can now access your shares from other computers in your network. To manipulate the files in the shares from Windows, launch the file manager and enter\\hda in the address bar. Similarly, in Linux the Shares are accessible when you enter smb://hda in a file manager.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy Linux Magazine

Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

comments powered by Disqus
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters

Support Our Work

Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.

Learn More