FriendlyElec NanoPi Series Software Router Selection and Flashing: R2S Plus + FriendlyWrt in Action
本文最后更新于 315 天前,其中的信息可能已经有所发展或是发生改变,如有失效可到评论区留言。
Article Abstract
Addressing the demand for low-power software routers in home network environments, this article compares the high power consumption of traditional x86 devices and selects the Friendly NanoPi R2S Plus as an alternative. This device adopts the ARM architecture, paired with eMMC storage and FriendlyWrt customized firmware, with power consumption controlled at 4-6W, meeting daily network services and lightweight application needs. After booting FriendlyWrt from an SD card, the Web interface is used to flash the eMMC, solving the issue of insufficient stability when running from a TF card. Practical experience verifies the advantages of the official firmware in driver adaptation and system optimization, while the eFlasher tool is used to complete multi-system image burning, providing a flexible solution for subsequent expansion and deployment. While maintaining low-power characteristics, this solution achieves stable operation of software router functions, making it suitable for scenarios such as scientific internet access and ad filtering in home network environments.
Qwen3-14B · 2026-06-18

1 Introduction

In the previous article (see:Home Data Center Series: Transforming a Retired Mini PC with X-WRT: An Alternative Choice for the Main Router), I used an idle J2900 x86 mini PC to play around with a software router. It ran fine, with performance to spare and a stable system. But the problem was, it wasn't my main device for scientific internet access; it was purely a ”technical experiment”—meaning, the machine was on every day but had almost nothing to do. Yet its standby power consumption was stable at over 20 watts. Watching the electricity meter tick, I felt a bit of pain in my heart.

If this machine were truly the main router, I would accept that little bit of power consumption; but now it's just a side character. To say it's idle, I use it occasionally; to say it's in use, its daily utilization is very low. Running it long-term always feels not worth it, and turning it on and off as needed feels awkward to me. So I started wondering, is there a device that isn't too expensive, is compact in size, has power consumption low enough that I wouldn't mind keeping it on 24 hours a day, and can still run stably, perform well, and be versatile enough for me to tinker with freely?

After searching around the internet, I actually found such a suitable choice:NanoPi R2S/R2S Plus:

image.png

Priced at less than 300 RMB, its power consumption is also very friendly: even with some extra services enabled, the standby power consumption is only 4W ~ 6W, which is on a completely different scale compared to the 20W+ power consumption of the J2900.

Such a tiny box, yet it can support a lightweight but practical network environment, and running it is completely worry-free and energy-efficient. And more importantly, NanoPi itself has prepared exclusive firmware for this type of device — FriendlyWrtThis is much more hassle-free than the general-purpose system X-WRT I used before (of course, you can flash X-WRT if you want). It doesn't require various adaptations, nor does it require messing with drivers and modules. It works out of the box, offering a very complete experience. Honestly, this is the key to truly making this small device ”easy to use.”

2 Introduction to Friendly NanoPi Series Routers

In the software router community, the Friendly NanoPi series routers can be said to be a very frequently seen category of devices. It is a series of compact, open-source ARM platform devices introduced by FriendlyElec, positioned somewhat like the Raspberry Pi, but focusing more on network forwarding and software routing scenarios. Especially in the domestic and international OpenWrt / X-WRT communities, multiple models of NanoPi have received high support and optimization, with a relatively mature hardware and software ecosystem. Here is a brief list of the differences and characteristics of the mainstream models in this series for the reference of friends in need:

image.png

A brief summary of the purchasing logic:

  • Limited budget, light usage: R2S (or R2S Plus) is stable and hassle-free enough;
  • Wanting to expand capabilities slightly, such as running multiple services: R3S is a balanced choice;
  • Need to run multi-user scientific internet access, high-load bypass, ZeroTier, ad filtering, etc.: It is recommended to go straight for R4S or R4SE;
  • High bandwidth requirements, multi-LAN port needs, planning for transparent proxy or software router aggregation in the future: Then consider R5S, which is not cheap but can be used for a long time.

After some consideration, I finally chose the **R2S Plus, not because of how powerful it is, but because it sits in a very comfortable spot. My daily performance requirements for scientific internet access are actually not high—I don't stream videos or watch Netflix (the number of movies on Netflix is too small, and the bitrate is not high, which is useless to me, far inferior to my own collection~), at most, I browse web pages, search on Google, and chat with ChatGPT, with actual bandwidth rarely exceeding a few Mbps. Therefore, performance monsters like R4S and R5S would be a waste of resources for me, and their prices are on another level, making them very uneconomical.

In contrast, the R2S Plus appears lightweight and ”just right”—it handles mainstream home networks with zero pressure in terms of performance, has low power consumption and low heat generation, and is reassuring to run in a corner for a long time. It uses a Type-C interface for power supply, adapts to a wide range of cables, deploys flexibly, and keeps the desktop cleaner. Most importantly, it has built-in eMMC storage and can boot the system from eMMC. I really have little confidence in running a system from a TF card (of course, the price of less than 300 RMB is the killer blow~).

Note: All models of the Friendly NanoPi series routers provide a TF card slot to support booting from a TF card, as models with built-in eMMC are only a subset. If you choose to boot from a TF card, you can also directly deploy X-WRT just like what was discussed in the previous article. The method of burning X-WRT is the same as burning a USB drive in the previous article, just remember to select the image ”X-WRT-25.04-b202506151427-armsr-armv8-generic-ext4-combined-efi.img.gz” under ”Generic EFI Boot”:

image.png

3 Firmware Selection

1 Overview


The Friendly NanoPi series routers are actually very flexible in terms of firmware selection, catering to the needs of different users: if youdo not want to hassle and want out-of-the-box usability, then directly using the official exclusive firmware — FriendlyWrt is the most hassle-free choice. It is essentially a customized version based on OpenWrt, combining Friendly's own driver adaptation, graphical interface optimization, and integration of common plugins. It is fully featured and user-friendly, requiring almost no manual configuration for daily use, making it suitable for users who want ”plug and play.”

Of course, if youprefer controllability and customizability, or if you are already familiar with the OpenWrt ecosystem, you can also flash other community versions of the firmware. For example, X-WRT community、immortalwrt etc., all have very good support for the NanoPi series. These third-party firmwares add more extended functions, plugin platforms, or performance optimizations on top of OpenWrt, offering greater freedom and more room for customization. Especially for models with a large user base like R2S / R4S / R5S, you can find a lot of flashing tutorials and user experiences online, and the adaptation is very mature.

Simply put,if you want stability, use FriendlyWrt; if you want to play around, go with the community version (TF card boot), and the NanoPi series happens to cater to both, which is one of the key reasons for its popularity.


Unlike other general-purpose firmwares (such as X-WRT), the official firmware provided by FriendlyWrt is specific to hardware models and cannot be cross-flashed. Therefore, you first need to find your corresponding model on the official wiki (https://wiki.friendlyelec.com/wiki/index.php/Main_Page) to find the model you purchased. For example, since mine is the R2S Plus, I click to enter my model:

image.png

Then click to enter ”Official Firmware”:
image.png

image.png

Finally, you will get the download links for Baidu Netdisk and Google Drive. Choose the method according to your situation. Once inside, you only need to save the ”01_System Firmware” directory:
image.png

There are 3 subdirectories in the ”01_System Firmware” directory:
image.png

2 Firmware Introduction

2.1 01_SD Card Firmware

All firmwares in this directory are used for the ”booting and running from SD card (TF card)“ scenario, and the naming of the firmware explains its purpose (the official source also provides ready-made options for flashing third-party systems for the NanoPi series routers, such as Debian 12, Ubuntu 24.04, open-source NAS openmediavault, etc.). The detailed description is as follows:

image.png


The full version and minimal version of FriendlyWrtThe biggest difference lies in whether the Docker environment is pre-installed, which is consistent with the difference between the ”full version” and ”minimal version” I mentioned earlier in the X-WRT firmware naming rules. If you only use it as a bypass router or to run some basic services, there is actually not much difference in basic functions, and the system experience is not very different. It should be noted that while the minimal version is smaller in size,it also streamlines some common tools in user space(such as some command-line components, network tools, etc.). Although it does not affect basic functions, users with certain hands-on needs or those who need to manually debug the system may encounter missing tools during use and will need to install them additionally via opkg.

However, I personallydo not highly recommend running Docker on devices with less than 2GB of RAM: First, Docker itself has a non-trivial memory footprint. Even if you only run some small containers, it can easily make the system laggy or even cause OOM (Out of Memory) situations. Secondly, in terms of storage, if you are running it on a TF card, Docker's read and write operations will greatly slow down performance and even accelerate the wear and tear of the card.

Therefore, if you indeed have Docker needs, I suggest meeting at least one of two conditions:

  • Either the device has eMMC storage, which offers relatively much better random I/O and stability;

  • Or mount a USB 3.0 external hard drive or USB flash drive, which can significantly improve read and write bottlenecks;

But these two conditions actually exceed the ”positioning” of many low-end NanoPi models. Therefore, for most entry-level users, instead of chasing the full version, it is better to choose a minimal version. A clean system that runs lightly is actually more in line with the best way to use this type of device. If you really need Docker functionality, it is recommended to go directly for high-end models.


2.2 02_SD Card Flashing Firmware (SD-to-eMMC)

All firmwares in this directory are used for the ”Flashing firmware to eMMC storage after booting from SD card (TF)“ scenario, and the naming of the firmware explains its purpose:

image.png

It can be seen that compared with the naming in the previous section, the filenames here remain basically consistent, with the only difference being an extra keyword—eflasher. So, what is eflasher?

Simply put, eflasher is an image flashing mechanism officially provided by FriendlyELEC, specifically used to write systems to devices via SD cards. Its full name is eMMC flasher, which is an ”eMMC burner”, used to automatically write the system image from the SD card to the device's built-in eMMC storage. Compared to general system images, the eflasher version will run a graphical or command-line flashing tool after booting to guide the user through the installation process.

This mechanism is mainly used formass production of devices或system recoveryscenarios, suitable for initial installation or resetting the system to factory status. The presence of ”eflasher” in the filename means that this image is a version ”for flashing” rather than a version "for direct running".

2.3 03_USB Flashing Firmware (USB-to-eMMC)

All firmwares in this directory are used for the ”Flashing firmware to eMMC storage from a computer via USB cable“ scenario, and the naming of the firmware explains its purpose:

image.png

It can be seen that compared with the image naming of SD card flashing in the previous section, it just changed from ”eflasher” to ”USB”, and everything else is the same.

4 Firmware Flashing

1 Flashing Firmware for TF Card Boot and Run Mode

I don't plan to expand on this part, because it was actually written in detail in the previous article about X-WRT. Simply put, it is about using Balena Etcher and similar tools to write the downloaded .img firmware file directly into the TF card. The operation is very simple and requires no extra settings. For most people, the entire process only takes a few mouse clicks to complete, nothing complicated. Friends who really want to do it can just refer to the previous article.

The only extra reminder here is:The TF card capacity does not need to be too large. I personally recommend choosing a card between 8G and 32G, which is quite enoughThe system image is usually only 200MB ~ 500MB, and the remaining space is basically used as an overlay, which is more than enough even if you install some plugins or run a lightweight service. On the contrary, a card that is too large will bring two unnecessary problems:

  1. Longer flashing time — Especially for some old cards with slow write speeds, flashing a 64G image might take half a day, which is not a good experience;

  2. Easy to waste resources — Using a 64G or 128G high-speed card to run a router system is a bit of an overkill, it would be better to save it for NAS cache or media storage.

Another reminder:The quality of the TF card is more important than its capacity, it is recommended to choose a reliable brand with faster speeds (such as SanDisk's Ultra or higher series), which can effectively reduce subsequent system lag, service latency, and other issues caused by poor I/O performance.

2 Flashing Firmware for eMMC Boot and Run Mode

2.1 Overview

The flashing operation of eMMC is slightly more troublesome than that of a TF card. Although in addition to wire flashing via USB OTG + Windows flashing tools, FriendlyElec also provides two more convenient flashing methods: first, after booting using a TF card, flash through the ”eMMC Flashing Assistant” in the Web page; second, flash the official eFlasher image to a TF card, and then boot using the TF card to flash into eMMC via the graphical interface or VNC operation. The overall process of these methods is actually not complicated, and the operation is not difficult for slightly experienced users.

But no matter which method is used, it essentially belongs to the concept of ”write once and don't touch it often“ — unlike a TF card, where unplugging it to change a card or reflashing a system is very convenient. eMMC is more like a ”fixed disk”, used to carry a system that runs stably for a long time, rather than being repeatedly tinkered with.

More importantly, once there is a problem with the system on the eMMC, even if it's just a broken bootloader, it cannot recover on its own and must rely on external device intervention: either insert a TF card to reboot and flash, or use a USB data cable to connect to a computer to enter maskrom mode for operation, or even in extreme cases, serial debugging may be required. These operation steps are neither user-friendly nor easy. Once you run into a problem, the cost of handling it is much higher than reflashing a TF card.

Therefore, I always recommend treating eMMC as a target disk for ”long-term use after writing”,once the system is flashed, try not to touch it; leave daily testing, changing systems, trying new things, and other tinkering operations to the TF card, which is flexible, worry-free, and less likely to fail.

In addition, please note thatnot all third-party firmwares are fully adapted for eMMC booting, there may be differences in boot methods, driver support, partition layouts, etc. Once flashed incorrectly or improperly adapted, it is easy to encounter boot failures, bricked devices, and other issues, affecting the user experience.

Therefore,I highly recommend prioritizing the official FriendlyWrt firmware when using eMMC boot scenariosIt is essentially a customized version developed based on OpenWrt, specifically optimized for NanoPi series devices (especially models with eMMC). It has a reasonable image structure, perfect driver support, and a stable and mature system. Once flashed, it can basically be used for a long time with peace of mind, which is not only worry-free but also safer.

If you do not plan to use FriendlyWrt, you can also consider several other officially supported firmwares provided on FriendlyElec's official website, such as:

  • buildroot: Suitable for users with strong DIY capabilities to build their own systems, highly customizable;
  • debian-bookworm-core / ubuntu-noble-core: These two are pure Debian and Ubuntu minimal core systems, suitable for scenarios such as lightweight servers, bypass routers, and edge computing gateways. Compared to FriendlyWrt, these systems do not have a Web management interface, are more oriented towards command-line operations, and are more flexible but also more ”bare-bones”;
  • friendlywrt-focal: is a hybrid firmware based on Ubuntu core + OpenWrt upper layer, balancing the Ubuntu software ecosystem and OpenWrt's network management interface, suitable for users who want to use the apt system but do not want to give up LuCI;
  • openmediavault: This is mainly used to run NanoPi as a lightweight NAS. FriendlyElec has made a relatively complete adaptation, and the interface and functions are relatively mature, suitable for storage-oriented usage scenarios.

Of course, if you are an advanced user who is familiar with the OpenWrt architecture and understands the eMMC operation process,flashing other third-party firmwares is not out of the question, but you must make adequate backups, accept the possibility of running into issues, and be prepared for system recovery.

2.2 Booting FriendlyWrt from SD Card (TF Card) and Flashing Firmware into eMMC via Web Page (Recommended)

This should be the easiest way to flash firmware to eMMC: first, use any FriendlyWrt image under the ”01_SD Card Firmware” folder to make a TF card boot card, then boot and run FriendlyWrt normally, and log in to the GUI page. Find and run ”eMMC Flashing Assistant” under the ”System” menu:

image.png

image.png

image.png

Once the flashing is complete, make sure to eject the SD card first. The device will automatically restart and boot the system from eMMC. Do not unplug the power directly, I will explain the reason later:
image.png

Note: I actually thought the ”eMMC Flashing Assistant” feature was removed in the new version at first, because I was using FriendlyWrt booted from eMMC, and I couldn't find it anywhere on the page; only later did I realize that,this feature is only displayed when booting from a TF card, because the system considers that you are booting from an ”external environment” at this time, and only then allows you to operate the eMMC. The design is reasonable, but it is indeed quite easy to cause misunderstanding, as I almost misjudged it.

2.3 Booting from SD Card (TF Card) and Using eFlasher to Flash Firmware into eMMC (SD-to-eMMC)

To flash eMMC firmware in this way, you need to use the official eFlasher mechanismSimply put, it is to write a firmware image with the word “eflasher” to an SD card (TF card), and then use this card to boot the device. At this time, the system will automatically run a VNC server, guiding you to complete the flashing operation through a graphical interface.

By default, the device's VNC service is bound to a fixed IP 192.168.1.231, and the DHCP function is not enabled by default — That is to say, it will not automatically assign an IP address to your computer (this is indeed quite counter-intuitive, a bit of a ”trap”, I struggled for a while, thinking it didn't boot successfully at all~~~~).

Therefore, you need to manually set your computer's wired network card IP to any address in the 192.168.1.x segment (such as 192.168.1.100), and set the subnet mask to 255.255.255.0. At this time, NanoPi's LAN port and WAN port are bridged together, so you can access it by plugging into either port, no need to worry too much.

Then, use a client that supports VNC (RealVNC or UltraVNC is recommended) to connect to 192.168.1.231:5900, and you will see the graphical eFlasher flashing interface. In the interface, you can choose to flash the target system to eMMC. The operation process is very intuitive, basically just a matter of clicking a few buttons. Taking the firmware flashed on the TF card, rk3328-eflasher-multiple-os-20250603-30g.img.gz, as an example:

image.png


This image is about 3GB in the compressed package, but after decompression, it is a large image file of about 30GB (because it contains multiple systems), so when actually flashing the TF card,you must use a card with a capacity greater than 32GB, otherwise flashing tools, such as Etcher, will directly report an error and fail to write. As for why it is so large, it is because it contains multiple systems~):

In addition, one thing to remind you:The flashing process will completely overwrite the original content of the eMMC, so it is recommended to confirm that there is no important data before operating. If you are worried about making a mistake, you can also first save the current system image through the ”Backup eMMC to TF card” function in the graphical interface, just in case:

image.png


After clicking to select FriendlyWrt 24.10, the following interface appears. Keep all options unchecked by default, and then directly click ”Next” in the bottom right corner:

image.png


Regarding the two options “start automatically at startup” and “disable overlay filesystem”, I want to emphasize them,especially the latter, which is very critical, and many people tend to ignore it when flashing for the first time。

  • start automatically at startup: The purpose of this option is to let the system, after inserting the TF card and booting,automatically enter the flashing process or the last state, skipping the main interface interaction. It does not re-flash every time, but is more like ”restoring to the stage where you last stayed” — for example, if you finished flashing last time and stopped at the ”completion page”, the next time you insert the card and boot up, it will directly jump to that page. Therefore, if you are just doing a normal manual flash once, you don't need to check it;It is only recommended to enable it in scenarios such as batch flashing or unattended operations。
  • disable overlay filesystem: This option determines whether the system flashed into the eMMC enables the Overlay file system when running.When unchecked by default, the system will normally mount overlay to the eMMC, which can permanently save all configuration modifications (such as changing passwords, installing plugins), and they can be retained after rebooting. However, if you check this option, overlay will be disabled, causing the system to become pure read-only mode, configuration changes cannot be written to the eMMC, and even some firmwares (especially the minimal version) will directly fail to boot because they cannot find a writable mount point. Simply put:If you want to formally install and use this system for a long time, do not check this option, just keep the default。

Then the flashing of the eMMC begins, which is completed very quickly, but pay attention to the prompt in the bottom left corner:

image.png

Must firsteject the TF card, at this time the device will automatically reboot and boot from the eMMC into the flashed FriendlyWrt system. If you follow this process, basically everything will go smoothly and the experience will be silky smooth.

But if youtry to save trouble, directly unplug the power after flashing, and then eject the TF card— hehe, you will know what it means to doubt your life:No matter how you turn it on, it stubbornly refuses to boot from the eMMC, even if you have unplugged the TF card, the device is just stuck in the silence before booting.

This is because after eFlasher displays ”Flashing successful”, the system does not immediately complete all write operations. At this time, some of the image data on the eMMC may still becached in memory and not yet synchronized (sync) to the disk, and the flashing tool itself alsodoes not automatically unmount the eMMC partition or refresh the boot configuration. Only by clicking the ”Finish” or ”Shutdown” button, or ejecting the TF card, will the system execute the complete wrap-up process, such as:

  • Writing the file system changes of the eMMC to the disk;
  • Unmounting the mounted partitions;
  • Clearing temporary marker files during the flashing process;
  • Refreshing U-Boot's boot parameters or setting the boot order;
  • Executing sync to ensure data writing is completed;
  • Finally, safely rebooting or shutting down.

And if you directly cut off the power to skip these steps,it is equivalent to abruptly cutting it off before the system has time to wrap up. The result is — the system on the eMMC may only be half-written, with incomplete file structures and chaotic states, and even the boot partition is not finished flashing, so naturally, don't expect it to boot smoothly.

This is indeed a painful lesson —I was stuck here for a full three hours. The problem is actually not complicated, but it's all to blame on myself for operating based on experience right from the start, neither looking at the instructions nor reading the help documentation, and directly getting to work, resulting in being deeply trapped. Empiricism is indeed the eternal old rival of tech people.

Note: Also, as a side note,eFlasher also supports installing the system on an external M.2 or USB storage device. You can select ”Boot installation to eMMC (or TF card)” in the graphical interface, and at the same time install part of the system to a USB hard drive or M.2 SSD, which is the next step after selecting the system on the eFlasher start interface, taking flashing Ubuntu as an example:

image.png

Just need to note:The CPU of R2S Plus itself does not support booting directly from USB or M.2, so no matter where the system is installed, the boot must still fall on the eMMC or TF card. Although this way of playing seems quite ”advanced”, it is not necessary for most users, just understand it.

2.4 Flashing Firmware into eMMC via USB from a Computer (USB-to-eMMC)

This method of recognizing the computer as a USB-to-eMMC device through USB and directly flashing the eMMC on the PC,is not highly recommended by me. Although it sounds very advanced, the actual operation processis both tedious and error-prone, requiring entering maskrom mode, installing dedicated flashing tools, and potentially involving driver compatibility, image format conversion, and other issues,which is far less simple and direct than booting eFlasher from a TF card。

Unless you are particularly familiar with this process, or the device can no longer boot normally from the TF card and there is really no other way, it is better to skip this troublesome route for peace of mind and safety.

2.5 Brief Summary

Regarding the flashing methods for eMMC, they can actually be categorized according tocomplexity and recommendation levelroughly into three levels:

  • The most recommendedmethod is to use TF card boot to enter FriendlyWrt, and then operate through the ”eMMC Flashing Helper” in the Web management interface. You only need to upload the image and click confirm, and the flashing will be completed in a few minutes,with almost zero learning cost for the entire process, being both intuitive and stable, which is my personally most recommended method.

  • If you are not booting FriendlyWrt, or wish to have more choices in a graphical interface (such as installing to a USB or M.2 device), you can consider using the official eFlasher image, which boots from the TF card into the built-in flashing interface,supporting local display or remote VNC operation, offering more flexible features but with a slightly more complex process.

  • As for using USB OTG to connect to a computer and use a flashing tool to wire-flash the eMMC, although it is also an officially supported method, the entire process is quite tedious and not very friendly to beginners,and improper operation may even lead to system corruption or bricking. Therefore, I do not highly recommend this method,unless you are familiar with the process or the first two methods are not feasible.

In short,TF card boot + Web flashingis currently the most reliable and simplest mainstream method; other methods can just be understood as alternatives or emergency solutions.

5 Initialization

The LAN port of R2S Plus has DHCP service enabled by default, with an interface IP of 192.168.2.1. You can directly use the address ”http://192.168.2.1“ to log in for management, with the default username and password being root/password:

image.png

After entering, you can see the default status page:
image.png

It is English by default. To change it to Chinese, modify it in ”System” - “system” - “Language and Style”:
image.png

Modify the router password in ”System” - “Administration” - “Router Password”:
image.png

Unlike X-WRT, the SSH function is open by default and does not need to be enabled manually:
image.png

In ”Network” - “Interfaces”, you can set the connection method and address acquisition method for the LAN port and WAN port respectively (note that the WAN port is eth0 and the LAN port is eth1):
image.png

At this point, the initialization of FriendlyWrt is complete.

6 Others

Other options are similar to those of the OpenWrt family. The only thing worth mentioning is the applications provided by default in the ”Services” menu of FriendlyWrt:

image.png

There are also some practical ones; any others that are missing can be found in ”System” - “Software”:
image.png

Or you can install them yourself using the opkg command in the command line:
image.png

Other operations are similar to those of the OpenWrt family, so I won't say much more.

7 Tip 1: Solving the Issue of OpenClash Not Working Properly After Installation

One thing worth mentioning is that when installing OpenClash in FriendlyWrt,it sometimes inexplicably breaks the system's originally normal curl, causing errors such as ”symbol not found” when executing curl in the command line, and at the same time preventing OpenClash from working properly.

The essence of this problem is that in some versions of OpenClash, the installation process may pull a set of dependency packages that are not fully compatible with the current system build environment(such as libcurl, libmbedtls, etc.). Once these libraries are incorrectly overwritten, curl will fail to correctly load the required dynamic symbols, resulting in relocation errors.

What's more troublesome is that if you perform operations like ”dependency repair” or ”update core” through OpenClash's Web UI, this problem is actually more likely to be triggered. Therefore, I personally suggest that for this type of tool,it is best to manually download the .ipk installation package for deployment to avoid the plugin automatically pulling the wrong dependencies. Once a curl error occurs, you usually need to uninstall the relevant components, force clean them, and then reinstall the correct version using opkg to recover. The solution is as follows.

Step 1: Force remove curl and associated libraries (this will also uninstall OpenClash):

opkg remove curl libcurl4 libmbedtls libmbedx509 libmbedcrypto --force-removal-of-dependent-packages

The effect of this command is:
– Uninstall curl and all the dynamic libraries it depends on;
– Remove luci-app-openclash which depends on curl along the way (without affecting other system components);
– Clean up a clean space for curl.

Step 2, reinstall a complete, healthy set of curl:

opkg update
opkg install curl

At this point, curl will automatically pull back its truly matching dependencies like libcurl4, libmbedtls, etc. Then execute:

curl https://www.baidu.com

If this command succeeds, it means your system-level network capabilities (as well as the most basic tools that OpenClash depends on) have been repaired.

Step 3, reinstall OpenClash:

opkg install /tmp/luci-app-openclash*_all.ipk

This issue almost made me doubt my life, causing me to flash the eMMC several times for no reason when I couldn't find the cause at the beginning~.

If you don't want to redo it this way, theoretically you should install all dependencies first, so that the system's own curl library is locked in and won't be messed up or replaced by OpenClash.

Step 1, install all the basic system dependencies first:

opkg update
opkg install curl libcurl4 libmbedtls ipset ip-full iptables iptables-mod-tproxy kmod-tun kmod-inet-diag

If you need to use TUN (requires Clash.Meta / Premium):

opkg install kmod-tun ip-tiny iptables-mod-tproxy

This way, all the dependencies required by system-level curl / wget on your FriendlyWrt are already from the official repository and will not be overwritten by OpenClash again.

Step 2, download and install OpenClash (please modify it to the OpenClash version you need):

cd /tmp
wget https://github.com/vernesong/OpenClash/releases/download/v0.46.086/luci-app-openclash_0.46.086_all.ipk
opkg install ./luci-app-openclash_0.46.086_all.ipk

Then go to LuCI to start OpenClash, and you can download the core online.

8 Tip 2: The Issue of NAT Not Taking Effect in Certain Special Scenarios

This issue really screwed me over... My main router is iKuai, and the network topology looks very reasonable: iKuai's WAN2 is connected to FriendlyWrt's LAN (eth1), and then FriendlyWrt's WAN (eth0) is connected back to iKuai's LAN2. This allows port-based traffic splitting on iKuai, handing off part of the traffic to FriendlyWrt for bypass/proxying. The schematic diagram is as follows:

image.png

But in actual operation, no matter how many times I flashed FriendlyWrt (tried both the slim and full versions), OpenClash never worked properly. Clash could successfully pull the configuration, fake-ip mode seemed completely normal, and there were no errors in the logs, but HTTP/HTTPS requests all timed out.

After troubleshooting for several days, I finally found that the problem was not with my topology or Clash configuration at all, but that FriendlyWrt's NAT was not taking effect at all. Although its /etc/config/firewall had option masq ‘1’ (IP masquerading) written, it was not correctly pushed to the masquerade rules in nftables. As a result, under this architecture, traffic exiting from the WAN was not SNATed, and the "intranet source IP" was directly sent out as-is.

Under this architecture, although the traffic received by FriendlyWrt physically enters through the LAN (eth1/br-lan) interface and the source IP looks like 172.17.100.x, because NAT has already been performed once on iKuai, FriendlyWrt's traffic connection tracking might fail to hit the corresponding NAT rule chain, causing masquerade to not execute at all.

In contrast, if intranet devices directly point their default gateway to FriendlyWrt's LAN (eth1), it can 100% trigger the normal LAN → WAN NAT process, and masquerade will definitely take effect.

So this pitfall is extremely hidden. It seems to have nothing to do with my network planning, but in reality, it is because the system by default did not convert the masquerade option in /etc/config/firewall into valid nft rules, which prevented the traffic from being SNATed. If I hadn't stripped down OpenClash step-by-step to verify the minimal link and test NAT separately, I would probably still be wasting time on upper-layer configurations like fake-ip and redir-host.

To solve the issue of NAT not taking effect in this special scenario, running the following commands can take effect immediately (I use eth0 here because when R2S Plus is flashed with FriendlyWrt, eth0 is the WAN port):

nft add table ip nat 2>/dev/null || true
nft add chain ip nat prerouting '{ type nat hook prerouting priority 0; }' 2>/dev/null || true
nft add chain ip nat postrouting '{ type nat hook postrouting priority 100; }' 2>/dev/null || true
nft add rule ip nat postrouting oifname "eth0" masquerade

To make it permanent, perform the following operations and then restart:

cat >> /etc/firewall.user <<'EOF'
nft add table ip nat 2>/dev/null || true
nft add chain ip nat prerouting '{ type nat hook prerouting priority 0; }' 2>/dev/null || true
nft add chain ip nat postrouting '{ type nat hook postrouting priority 100; }' 2>/dev/null || true
nft add rule ip nat postrouting oifname "eth0" masquerade
EOF

Note: This kind of problem does not occur on mature commercial routers like ASUS, where the firmware has long taken care of various NAT scenarios properly, and the default policies are seamless. But on OpenWrt-based software routers, it's completely unpredictable — different distributions, different firewall solutions (iptables / nftables), and even different configuration wizards will affect the generation of NAT rules. Sometimes, just a few missing masquerade rules will cause the problem to burst out directly, catching you off guard. However, as long as you are not doing multiple NAT, loopback, or extreme transparent proxy experiments, normal home scenarios generally do not need so many modifications, so you naturally won't step into this kind of pitfall.

9 Afterword

All in all, you need to be mentally prepared when tinkering with the FriendlyElec NanoPi series software routers,It is not the kind of off-the-shelf router that works right out of the box and remains stable no matter how you modify it.. You need to spend some time understanding its flashing methods, partition layout, and various small pitfalls (such as flashing the eMMC overlay, choosing the boot method that suits you, etc.).

But precisely because of this, it is actually very suitable for users who like to tinker and want to keep their network completely in their own hands. After all, spending a few hundred yuan gets you a low-power, compact mini gateway with decent performance (much stronger than the MTK chips in common routers), and you can install various OpenWrt derivatives, custom plugins, scientific internet routing, or simply other systems (Debian, Ubuntu, OpenMediaVault) — to be honest, this level of freedom and playability is something the vast majority of commercial routers can never offer.

So, if you approach it with a DIY mindset and play with it as a small server or a small gateway, you will definitely enjoy it; but if you just want a "set-it-and-forget-it home router right out of the box," then it is recommended that you directly choose Asus, Netgear, or higher-end All-in-One devices, to avoid having your mind blown by various strange little problems later on~~.

View Related Categories · 3 Matches
📌 Content Structure Prompt:
This content is part of the following knowledge map, where you can view the complete content path: Blog Knowledge Map。
📎 Related Articles
Share this article
The blog content is original, please indicate the source when reposting! The RSS address of the blog is:https://blog.tangwudi.com/feed, welcome to subscribe; if needed, you can join theTelegram Groupto discuss questions together.

Comments

  1. Heiyu
    Windows Chrome 137.0.0.0
    1 year ago
    2025-7-07 16:32:29

    I feel like these kinds of development boards are quite expensive. The entry-level ones are not much different from second-hand phones or routers, and the high-end ones cost as much as a decent computer; perhaps the advantage lies in the so-called development, with comprehensive surrounding resources.

    • Owner
      Heiyu
      Macintosh Chrome 138.0.0.0
      1 year ago
      2025-7-07 16:34:47

      Yes, buying this kind of R2S Plus is already considered a finished product. Previously, many people just took a development board, plugged in a power supply, and started using it.

  2. Windows Chrome 137.0.0.0
    1 year ago
    2025-7-07 15:08:14

    My first soft router device was also the R2S. Now, because I need to run PT, scientific internet, and Samba to watch movies,
    I upgraded to the R4S, mainly because the R4S has USB 3.0.
    In addition, the TF card will also affect stability, especially the 4K read/write capability of the TF card.

    • Owner
      Hodgepodge
      Macintosh Chrome 138.0.0.0
      1 year ago
      2025-7-07 15:09:58

      Upgraded to R4S, mainly because R4S has USB 3.0

  3. I would never use a TF card under any circumstances; it has to be a model with eMMC... https://www.right.com.cn/forum/thread-4009551-1-1.html

    • Owner
      In addition, the TF card will also affect stability, especially the 4K read/write capability of the TF card
      Macintosh Chrome 138.0.0.0
      1 year ago
      2025-7-07 10:08:24

      Just to correct this, "Laomaozi" firmware should refer to the Padavan firmware modified from Asus router firmware, and has nothing to do with the OpenWrt firmware developed by Lean. Lean developed a set of compilation scripts that simplified the OpenWrt compilation process and made it easy to add a series of functional plugins to the firmware. Therefore, many people on the internet use this set of scripts to compile OpenWrt firmware, which is known as Lean's OpenWrt. For firmware classification, you can refer to this introduction

Send Comment Edit Comment


				
|´・ω・)ノ
ヾ(≧∇≦*)ゝ
(☆ω☆)
(╯‵□′)╯︵┴─┴
 ̄﹃ ̄
(/ω\)
∠( ᐛ 」∠)_
(๑•̀ㅁ•́ฅ)
→_→
୧(๑•̀⌄•́๑)૭
٩(ˊᗜˋ*)و
(ノ°ο°)ノ
(´இ皿இ`)
⌇●﹏●⌇
(ฅ´ω`ฅ)
(╯°A°)╯︵○○○
φ( ̄∇ ̄o)
ヾ(´・ ・`。)ノ"
( ง ᵒ̌皿ᵒ̌)ง⁼³₌₃
(ó﹏ò。)
Σ(っ °Д °;)っ
( ,,´・ω・)ノ"(´っω・`。)
╮(╯▽╰)╭
o(*////▽////*)q
>﹏<
( ๑´•ω•) "(ㆆᴗ
😂
😀
😅
😊
🙂
🙃
😌
😍
😘
😜
😝
😏
😒
🙄
😳
😡
😔
😫
😱
😭
💩
👻
🙌
🖕
👍
👫
👬
👭
🌚
🌝
🙈
💊
😶
🙏
🍦
🍉
😣
Source: github.com/k4yt3x/flowerhd
Kaomoji
Emoji
Little Dinosaur
Flower!
Previous
Next
       

👋 Welcome to “Wudi's Personal Blog”

Here, long-term exploration is mainly carried out around the following directions:

🧱 Personal Digital Infrastructure and Blog System Construction
☁️ Cloudflare and Network Architecture Practice
🧠 AI and Knowledge System Exploration
🛡️ Network Security and Access Optimization
🎵 Music and Sound Cognition
👁️ Cognitive Perspectives and Worldviews