Linux is the most versatile operating system on the planet and can serve in just about any capacity you can imagine, from embedded systems to desktops, to full-stack servers, and more. Another area where Linux shines is Network Attached Storage (NAS). By deploying Linux as your in-house NAS solution, you’ll find it to be everything you need.
And, fortunately, you don’t have to roll your own NAS platform. Thanks to distributions like openmediavault a strong Linux-based NAS solution is simple to deploy and use.
Openmediavault includes features such as:
- Based on Debian Linux
- Web-based administration
- Easy updates
- Volume management
- Link aggregation
- Wake On Lan
- IPv6 support
- Email notifications
- File sharing
- Extendible via plugins
SEE: 40+ open source and Linux terms you need to know (TechRepublic Premium)
I’m going to demonstrate how easy it is to install openmediavault. I want to demonstrate this using VirtualBox as my virtual platform of choice. The installation itself is actually quite simple, but there are a few tricks you need to understand to get this solution up and running.
What you’ll need
To follow along with this tutorial, the only things you’ll need are the openmediavault IOS image and a running instance of VirtualBox. That’s it, let’s build a NAS.
How to install openmediavault
1. Create your virtual machine
I’m not going to walk you through every step of the installation (as it’s pretty straightforward). The first thing to be done is the creation of the virtual machine. To do this, open VirtualBox and click Tools | New. Create your virtual machine as you normally would, but make sure, in the Network section, you select Bridged Adapter (Figure A).
2. Boot openmediavault
Continue setting up the VM and then, once complete, boot openmediavault, which will start the ncurses-based installer (Figure B).
Via this text installer, you’ll set configurations such as:
- Install language
- Keyboard configuration
- Domain name
- Root password
- Time zone
- Package manager mirror
- Debian archive mirror
- HTTP proxy (optional)
The installation is fairly obvious. If you’ve ever installed a GUI-less Linux server, this will be old hat. The only obstacle comes about after the VM installation is complete. Once you’ve gone through the install, you’ll need to shut down the VM and add a new virtual drive. Without adding a new virtual drive, you won’t be able to create any filesystems to be used as storage space for your NAS (which is kind of important).
3. Add a new virtual drive
So, shut down the now-installed virtual machine, select it from the VirtualBox left sidebar, and click Settings. In the Settings window, select Storage and then, under Storage Devices, select Controller: SATA and then click the tiny hard disk icon associated with Controller: SATA (Figure C).
In the resulting window (Figure D), click Create and then walk through the disk creation wizard (making sure to select VDI when prompted).
4. Boot the VM and log in
After creating the virtual drive, boot the VM. Once it boots, log in as the root user (with the root user password you created during installation). We then need to find out the IP of the server with the command:
If you want to set that server with a static IP address, open the configuration file with:
Comment out the line that configures your internet device with a static address, so that line looks something like:
#iface enp0s3 inet dhcp
Below that line, add something like (editing for the interface name, IP addresses required, and domain):
auto enp0s3 iface enp0s3 inet static address 192.168.1.77 netmask 255.255.255.0 gateway 192.168.1.1 dns-domain example.com dns-nameservers 188.8.131.52,184.108.40.206
5. Save, close and restart
Save and close the file. Restart networking with:
sudo systemctl restart networking
6. Login at the server
Point a web browser to http://SERVER (Where SERVER is the IP address of the server hosting openmediavault). You should be presented with the openmediavault login screen, where you’ll use the credentials admin/openmediavault.
7. Configure your dashboard
The first screen you’ll see informs you that the dashboard has yet to be configured (Figure E).
Click the settings page link and, in the resulting window (Figure F), add all the widgets you want for your dashboard.
How to add a disk to openmediavault
At this point, openmediavault isn’t much use, because you need to add the virtual disk (that will then be used to house the filesystem for storage).
1. Add the virtual disk
From the left navigation, click Storage and then click File Systems. In the next window (Figure G), click the + button to add a new file system.
2. Create the disk
From the popup menu, click Create. In the resulting window (Figure H), click the virtual drive you created earlier and click Save.
3. Select the drive and apply changes
Openmediavault will then partition and format the drive. Once that completes, click Close on the popup window and then, back at the File System creation window, select the newly-formatted drive and click Save. You will then be prompted to OK the mounting of the file system, so click Yes. At the top of the window, a yellow bar will appear, requiring you to apply the changes (Figure I).
Click the check and then, when prompted, click the checkbox for Confirm, and click Yes (Figure J).
You now have a file system that can be used by openmediavault. With this new drive added, you can add shared folders, create users/groups, and much more.
With openmediavault as your in-house NAS solution, you have quite a bit of power and flexibility in your hands. And be deploying this as a virtual machine, you can keep adding drives as needed to expand this solution to fit your needs.
Subscribe to TechRepublic’s How To Make Tech Work on YouTube for all the latest tech advice for business pros from Jack Wallen.
Subscribe to the Developer Insider Newsletter
From the hottest programming languages to commentary on the Linux OS, get the developer and open source news and tips you need to know. Delivered Tuesdays and Thursdays