FreeNAS is a distribution based on the free UNIX system that provides online storage services. NAS comes from the abbreviation of the English language, which means “online storage”. Configuring FreeNAS gives new life to old equipment, turning it into storage media. In a business environment, this system is used to store copies, virtual images and other purposes. As for the home environment, you can use it to save copies of photos and music, to connect the TV and access via the Network to its contents, thus allowing you to enjoy your favorite TV shows and movies that have been saved.
FreeNAS Operating System
Installation and configuration of FreeNAS can be performed on almost any hardware platform for sharing data storage over a computer network. It is based on the FreeBSD distribution, hence the name. This is free software because it uses BSD licenses. The project was born in 2005, designed to store data at no cost and is not limited to licenses. Behind it is a mature community and a team of experienced developers.
Key features of the FreeNAS setup:
- Replication. The ZFS file system is used, which allows the use of snapshots and their replication in other systems. In the event of a ZFS system failure, any snapshot can be restored.
- Data protection is used to maintain its integrity. RAID-Z has unique parity protection in RAID-5.
- Encryption when setting up FreeNAS. Encrypted data can only be read by FreeNAS containing the volume key. If desired, the user can implement a passphrase to increase the level of protection.
- Pictures. The system allows you to take pictures of the entire system at any time, which allows administrators to return to their previous state as necessary. They can be made manually or programmed with a time algorithm.
- File sharing. The main advantage of FreeNAS is file sharing over the Web.
- Web interface - the ability to control from the web. Creating volumes when setting up FreeNAS 11 and permissions is done in a simple way using a powerful shell or command line.
- Third-party plugins extend the functionality of FreeNAS. Among them are Bacula Backup Service, BitTorrent Download Service, and Cloud Cloud Storage.
Benefits of setting up FreeNAS 11:
- Based on FreeBSD, it allows you to create flexible storage devices for business data.
- ZFS supports snapshots and encryption, useful features in a business environment.
- RaidZ (software RAID solution) provides data protection without the problems and limitations of a traditional RAID configuration.
- Configuring FreeNAS SMB supports all of the most common file sharing protocols, such as Apple AFP, NFS, CIFS / SMB, and iSCSI.
Equipment admission rules
For installation, you can use any 32/64 bit PC with a single-core or multi-row CPU. In different schemes of mounted NAS are used: Atom 330, Celeron, Athlon XP, Pentium 2, Pentium 3, Pentium 4, AMD64 Socket 939, Intel E8500 and other devices similar in performance. The most sensitive elements that ensure the system’s operability are the network interface or Ethernet card and the compatibility of the motherboard chipset for the hard disk controller.
FreeNAS software includes drivers for the most common chipset. When buying a network card, you need to be careful with the type of connector on the motherboard: ISA or PCI. If the user has problems with the controllers of the hard drive of the motherboard, they are damaged or need more ports to install additional hard drives, you can resort to an external controller, for example, Promise SATA300 TX4 with 4 SATA ports. When you purchase these additional components, they provide a socket interface on the motherboard.
512 MB of RAM is sufficient for FreeNAS version 0.7.x, however, 1 GB is recommended for setting up FreeNAS 11 NAS.
List of required devices:
- ATOM 330 board with 4 GB of RAM, integrated graphics card, Ethernet Gigabit.
- Power supply ANTEC 450 W.
- 4 hard drives with a capacity of 1 TB.
- A memory card reader and compact flash memory into which the NAS operating system will be installed, thus using the total capacity of the hard drives.
Next, to install and configure FreeNAS 11 2, select the type of configuration and download the version corresponding to the NAS equipment.
There are two versions of the FreeNAS operating system that differ in the type of processor used by the computer: Intel (i386) or AMD (amd64).
These two branches use two forms: an embedded image and an advanced version (LiveCD). The differences between them are that the built-in image takes up less space in the CF or USB NAS, but does not allow you to make changes or install additional programs.
Experts recommend working with an extended version corresponding to the processor model used by the motherboard. If the processor is 32-bit, install the Intel i386 version, and if the processor is 64-bit, the amd64 version.
To set the extended image, burn the ISO to CD. To do this, it is better to use a CD / DVD player with USB, since then you do not need to install a recorder in FreeNAS.
Choosing a motherboard processor
Before you install the program and configure FreeNAS 11, analyze the server hardware. The first component to analyze on the motherboard is the processor. To work, you do not need all the power of the quad-core processor, on the contrary, this will lead to an unreasonable increase in power consumption. Optimization of the PC is performed by reducing the CPU clock frequency, changing the multiplier values in the BIOS of the motherboard, and then lowering the CPU voltage to avoid excessive power consumption.
For example, the NAS P4 3.0 GHz with Prescott core has a power dissipation of 90 watts. If the NAS is placed, decreasing the CPU multiplier, a frequency reduction is obtained. The supply voltage can be reduced by 30%. In this case, the dissipated power will be only about 33 W, which is acceptable for CPUs with NAS. If the motherboard supports the ACPI (Advanced Energy Management Interface) standard, the FreeNAS-based FreeBSD operating system will be able to manage CPU and system usage cycles, helping the user optimize power consumption.
Installing a distribution kit to create a NAS
To create their own custom NAS create a virtual machine, preferably with 4 virtual disks to simulate the overall configuration of the NAS. Installation Algorithm:
- Download FreeNAS from the official site and save it to a CD / DVD or use a virtual disk.
- Start the car from CD / DVD.
- Select the “Install / Update” function.
- Select the device in which the operating system will be installed (partition without shared access).
- It is recommended that you use a flash drive of at least 8 GB or a hard drive.
- Confirm the steps to create your own NAS, click "Yes."
- Specify the root password.
- Remove the CD / DVD and restart the system.
- Now FreeNAS is active and functioning. The shell informs about the assignment of an IP address.
- If the networks are running Active Directory Domain Services, configure the domain controller as a DNS server.
- To configure FreeNAS Active Directory, select option 6.
Network configuration:
- Indicate the DNS domain and IP server.
- Open the FreeNAS interface.
- To access the web user interface, use the IP address of the PC and specify the root credentials.
- The setup wizard starts.
- Select the default volume.
- Specify domain administrator credentials.
- Configure FreeNAS to send notifications to your email account.
- Create the volume where the data will be entered.
- Go to the storage section and click on Volume Manager.
- With 4 drives available, the RaidZ configuration offers the best balance between security, storage capacity and performance.
Creating a volume will take several minutes.
Creating an iSCSI Target
Among many options, FreeNAS offers full iSCSI support. Configuring FreeNAS iSCSI will achieve the result with a few simple steps:
- Enable iSCSI service.
- Open the Control Services tab in the Services menu and start the service.
- Go to the lock menu (iSCSI).
- On the Portals tab, click Add Portal.
- You can configure a network interface with a user IP address.
- Go to the "Target" tab and click "Add".
- Select the portal group ID.
- The degree is shared block memory through iSCSI. You can use a physical device or file, such as Extent.
- The file is configured - a virtual drive present in the raid z volume.
- Configuration completed. Now you can connect your PC to a Windows server by opening the iSCSI initiator in the control panel.
- Specify the IP address used when configuring the portal, and click "Quick Connect".
- Go to the “Volumes and devices” tab and click “Auto configuration”.
- A new iSCSI volume that you can use appears.
Server initiator and extent
To create an iSCSI portal, click Portals> Add Portal. To add an initiator, click Initiator> Add Initiator. The initiator serves to restrict the servers to view the LUN. You can configure the IQN or IP address for several, separated by commas. So that all servers on the same network can use the LUN, enter "ALL". The same parameter applies to the authorized network field.
To find out what the IQN and IP address are, check the target server: VMware ESXi, Microsoft Hyper-V, and Citrix XenServer. Now they create a target and associate with the identifier of the portal group and initiator group. To do this, click Goals> Add Goal.
To create the extent, click Extents> Add Extent. Link the target to the extent by clicking Link Targets> Add Target / Extent. The LUN ID parameter does not end automatically, so experts advise you to pay special attention to it so as not to duplicate LUN identifiers.
Now configure ESXi to view LUNs on FreeNAS. After ESXi recognizes the FreeNAS LUN, new data warehouses are created.
Plex Media Server Features
FreeNAS can be used to exchange data over the Web as a backup device, as well as to stream TV shows, music or movies to almost any device by installing the Plex Media Server plug-in.
Before installing Plex on a FreeNAS system, you must ensure that your equipment meets the following minimum requirements:
- 2.4 GHz dual-core processor or higher (Intel recommended).
- 8 GB of RAM.
- At least 1 hard drive with enough memory to store all media.
If you need new hardware, you can create your own system or purchase an existing NAS compatible with FreeNAS.
The IP method is set to a static address, for example, 192.168.1.222. This makes it easy to connect to the device, as the address does not change during reboot.
PLEX FreeNAS configuration algorithm:
- Open a browser, enter the IP address of the FreeNAS server, and then login credentials.
- If the user logs in for the first time, he will be asked to assign a password, and then the setup wizard will be launched.
- Add a storage volume. Before installing the Plex Media Server plug-in, the user must have created a ZFS volume for storing the plug-ins, for example, a mirrored volume from 2 x 1 TB hard drives.
- Click on the "Storage" menu item at the top.
- Click “Volume Manager” to open the window.
- Enter the name of the volume.
- Click “+” to add disks.
- Install Plex on FreeNAS, click on the plugins menu item at the top.
- They go down and click on the Plex Media Server plugin.
- Click “Install” and then “OK” in the confirmation window.
- The plugin will be downloaded and installed.
- The following steps create a new data set for storing music.
- Click on the "Storage" menu item at the top.
- Select the volume of the disk that you created earlier and click the "Create Dataset" icon.
- When the “Create Dataset” window opens, enter the name of the dataset, for example, “Music”.
- Set the “Record” checkbox opposite the other column.
- Check the resolution of "Set recursively."
- Click the "Change" button to apply the permissions.
Assign a Music data set for Plex Media Server by following these steps:
- Click on the Jails menu at the top.
- Go to the "Storage" tab.
- Click "Add storage."
- Click “OK” to complete the process.
Transmission Privacy Protection
It is currently advisable to protect privacy when downloading torrents on the Web. It is known that many lawsuits were filed by companies against Internet providers with claims for damages from users downloading illegal content. Many of these lawsuits were designed to force ISPs to publish lists of client IP addresses along with relevant activity logs.
Using Sick Rage, Transmission, and Couch Potato plug-ins, the NAS is more closed than ever. You can easily import ZFS raid disks from the old N4F server by easily installing OpenVPN. FreeNAS Transmission ensures that only secure traffic passes through the client.
The server can be adapted to work with Torguard and with other VPN providers. It is assumed that the user has the Freenas server configured and running, as well as the Transmission plugin. Currently, most users use Torguard for VPN.
VPN operation on FreeNas 11.1 server
In order to make FreeNas work on VPN, you need a Torguard provider, SSH, IP address and hostname. Install Bash, the system may offer to confirm the solution several times - answer "Y", each time pressing on the input. Install nano and go to the folder etc. Get Portsnap through portsnap fetch, loading will take some time. Next, extract the ports in usr / ports and do a clean installation with the password file option. A blue screen should appear, press the “DOWN” and “SPACEBAR” arrows to make sure that there is an “X” sign next to PW Save.
In recent versions of openvpn, you cannot get option 5, as described above, but in any case, the program reads passwords from a text file, so you can skip this step.
Go to the root directory, create a directory for OpenVPN and the files that will be downloaded from Torguard:
- Add lines to rc.conf so that OpenVPN starts when the jail is opened, using “Ctrl + o” to write the file, and “Ctrl + X” will complete the process.
- Go to a new folder, get Torguard files. You will need to capture them manually and install them through the FreeNas GUI, since Torguard does not allow the transfer of wget files.
- If the Transmission repository is correctly created, you can drag and drop Torguard files into the downloads NAS shared folder and see them using symbolic links in the media directory.
- Next, you will need to log in to check Torguard and select “Standard Port 443 / TCP Config” in the OpenVPN Config Files and Scripts section.
Unzip openvpn Torguard files to the Media folder:
- Create a pass.txt file to store the username and password.
- Press “Ctrl + o”, call pass.txt, then “Ctrl + X”.
- Configure the .ovpn file of the selected server.
- In the line auth-user-pass add pass.txt.
- Press “Ctrl + o” to name the file, for example, Your_Selected.ovpn, then enter “Ctrl + X”.
- Move Torguard fixed files to the folder you just created.
- Rename the .ovpn file to .conf.
- Start the OpenVPN server.
Troubleshooting tips
After the FreeNAS box is configured, it will need the attention of the user only in case of a hardware failure or update. The dashboard has built-in telemetry, so it is possible to monitor the use of a disk, network or processor.
Alternatively, they use built-in notifications to send an email if one of the drives fails. However, users may encounter a problem when setting up the FreeNAS network when they receive the message: This is a FreeNAS data disk and can not boot system. System halted.
Simple troubleshooting tips:
- Install the new version of FreeNAS on the machine.
- Connect both devices to the FreeNAS machine, load it.
- Press F12 to select the boot device and transition disk.
- When the installation screen opens, select "install / upgrade", and then install FreeNAS on an empty drive to go.
- They give the device a root password, choose to install FreeNAS with a BIOS boot.
- After the installation is complete, choose to restart the computer and remove the disk with the FreeNAS installer.
- To check the installation failure, you need to check the VPN tunnel.
The user will not be able to automatically update the Transmission client from the graphical interface. , Transmission jail, .
FreeNAS Transmission:
- openvpn.
- openvpn.
- Restart openvpn.
- Secure network VPN tunnel.
- Request the entire Freenas network.
- Stop all openvpn processes.
- If it still does not work as it should, check the log files in Freenas.
Thus, we can say that the free open-source operating system FreeNAS is designed to create a personalized NAS network storage using a powerful ZFS file system. It can be used to exchange data over the Web as a backup device, as well as to stream TV shows, music or movies to any device that supports modern Internet standards.