OriginalTechnology

My journey with my first NAS

2,186 words5 minute0 views0 likes

Summary

Starting from curiosity, the author built his first NAS, which implemented core functions such as private cloud disk, film and television platform, private photo album, and small server. After trying solutions such as Hyper-V virtual machine, notebook + hard disk cage, etc., the TerraMaster F2-221 finished chassis was finally adopted, paired with Feiniu system, using RAID0 mode, and achieving remote access through ipv6 domain name resolution and frp port forwarding. The article summarizes the advantages and disadvantages of each solution, emphasizes the precautions for power consumption, hard disk interface and network configuration, and provides a practical reference for hands-on enthusiasts.

Achievements display

Why set up a NAS?

I was more curious. In fact, I didn’t understand the advantages of NAS at the beginning, but there was no reason to worry about it, so I went to Bilibili and Douyin to conduct the first research. The following is my understanding of NAS.

  • A private cloud disk of your own
  • A film and television platform of its own
  • A private photo album of your own
  • A little server of your own

The above functions have satisfied my reasons for setting up NAS.

Construction process-preparation work

So what do you need to prepare to set up a NAS?

  • Small host/nas host/own computer/idle notebook
  • System (Feiniu, Black Qunhui, Greenlink)
  • harddisk

Construction process-scheme selection

I will be a little more verbose here, because I have many ways to implement it. I went through many, many solution considerations before finally deciding how to configure my NAS. There are many advantages and disadvantages that need to be studied. From the beginning of the system, I decided on Feiniu.

Solution 1: Hyper-V+sata interface hard disk (deprecated)

  • Use Windows Hyper-V to build a virtual machine and install the Feiniu system

In Control Panel-Programs and Features-Turn Windows features on or off-check Hyper-V

image-20241206145824361

  • Mount the target hard disk in the virtual machine, or virtualize the hard disk

Create a new virtual machine: directly mount the Feiniu image to DVD and start the installation. It is no different from the Windows system installation method.

Disadvantages of plan one

The power consumption is very high. The power consumption of any desktop computer starts at at least 350W, not to mention the foreign garbage I use. The NAS must be turned on before it can be used, and the NAS built with a virtual machine requires the virtual machine software to be turned on. One problem is the network port. My computer only has one network port. There is a problem with the IP assigned by the virtualized network card, and it is not very friendly to IPv6. My desktop computer also uses frp intranet penetration, which will cause IP conflicts between the two machines.

Solution 2: Laptop + hard drive cage (deprecated)

I've been looking at hard drive cages for a long time in Xianyu. The price is between 300-500. I happen to have a laptop limit, and the configuration is not low. It can run the NAS system very quickly.

Disadvantages of option two

The power consumption of notebooks is around 40 watts, and the hard disk cage needs to be powered separately, and it can only be powered by USB. I gave up on this plan immediately, even though the system was installed.

Option 3: Purchase a finished NAS chassis (currently in use)

In the end, I decided to buy a finished NAS chassis. The advantages are low power consumption and hot-swappable hard drives, which is more convenient.

The model I bought here is TerraMaster F2-221, the price is between 400-600, and the quality is very good, so it cost me 540 yuan.

A very good advantage of this product is that it supports soft routing because it has two network card interfaces. Although I haven't implemented it yet, I can try it out after I move to a new house.

image-20241206154257274

Configuration information:

  • TerraMaster F2-221
  • reid1 scheme
  • Seagate 4T surveillance disk
  • Hard drive box with independent power supply and USB port connection

The reason for using "hard disk box with independent power supply and USB port connection" is that this motherboard does not support the m2 interface, which is really uncomfortable. I just started using a 64G Kingston U disk to install the system, but I was worried that the U disk would not last long so I changed to a new solution. I directly copied all sectors to the new hard disk, which was a perfect solution.

Although the power supply problem of the final solution did not reach the ideal state, it was already satisfactory.

Feiniu system installation process

Taking my device as an example, of course it is recommended that you operate it according to my operation method.

Preparation

  1. Insert the two 4T hard drives into the NAS, but do not insert them completely. Leave them in an unconnected state, as long as they are not recognized.
  2. Download the image of Feiniu fnOS from the official website

Feiniu Private Cloud official website

image-20241206155633667

  1. Download the U disk boot tool (ventoy-1.0.99) installation image

image-20240826144432487

  1. Start the nas, press the del key on the keyboard, select the U disk to start, and install the system
  2. Select the graphical interface installation method (keep clicking Next)

img_v3_02eb_e43e6332-03f4-46ba-bbb7-873970e5e62g

  1. Set up the network (remember this IP in this step, enter the IP for configuration after successful installation)

img_v3_02e1_8f1fe992-40c3-40c4-817f-6e3ad9d3e04g

  1. Restart successfully and enter the terminal: when you see the following interface, it means it has been successfully run.

image-20240823180036795

Configuration tutorial:

Enter the IP address during installation in the browser to enter the system configuration interface.

img_v3_02e1_bfbf7b0c-7610-49da-85bb-2e96aec09eag

  • Device name
  • account
  • password

Follow the above steps to configure. Pay attention when the following interface appears. Be sure to click Wait, and then we will shut down the device in the lower left corner.

After shutting down, push the hard drive in, and then turn on the computer to enter the system interface.

img_v3_02e1_135625eb-c2ae-4de2-8d51-2483703d470g

I have configured it here. The first installation will prompt the installation raid mode. Here I choose raid 0. If there are two hard disks, it supports 1 and 0. 0 is the superposition of the space and transmission speed of the two hard disks, but the data is not safe. The 1 method is to use one of the hard disks for redundancy, which results in only half the space.

image-20241206160752268

extended configuration

The above is the implementation method of the intranet. What should we do if we are outside? What I use here is the two solutions, both are enabled.

IPv6 resolution domain name configuration

Search the software "ddns-go" in the app store. The official ddns parsing configuration is not used here, because ddns-go can set how many seconds to check, because the lease period of ipv6 changes once a week.

image-20241206161425146

The advantage of ipv6 is that it is fast. My broadband is 1000M, so my download speed is 1000M.

The disadvantage of ipv6 is that it is troublesome. Both devices must support the ipv6 network for access.

  • Open ddns-go configuration parsing
  • You only need to fill in the corresponding information. You can register a domain name at will. No registration is required.

image-20241206161500084

This completes the domain name access to your nas.

frp port forwarding

You can use frp to forward the local port to the public network server for access. I happen to have a domestic physical machine. The advantage of this solution is that it can be accessed as long as there is a network, without supporting the ipv6 protocol.

The disadvantage is that the transmission speed depends on the bandwidth of your public network server.

Operation steps:

  1. Enable SSH function in Feiniu system settings

image-20241206161816700

  1. Open the xshell software and enter the local IP to connect. The account and password are the administrator information that you just started configuring the system.
  2. Unzip the frp client file in the directory and start after configuring the information.

image-20241206161954131

  1. In order to keep running here, use the following startup command
nohup ./frpc -c ./frpc.toml  > frpc.log 2>&1 &

Important tips

When using frp to forward, you must pay attention to forwarding port 5666. Other software can use whatever port it needs. However, it is still not ideal. I hope that ipv6 can be fully covered as soon as possible.

The final installation still went to USB. It is recommended that you choose a motherboard with an m3 interface when choosing. Don't be passive like me.

It’s better to find movie resources to download by yourself, it’s not convenient to share.

Loading comments…
Related articles

Related articles