Network file system NFS (Network File System, which allows Xiaomi devices โ whether it's a smartphone, tablet or TV box โ to connect to remote folders as local drives, and it's convenient for streaming movies from the Internet. NAS, backups or files on the server, but standard firmware MIUI Android TV Xiaomi is often deprived of built-in support NFS, This forces users to look for workarounds.
In this guide, we will discuss all ways of installing NFS-client on Xiaomi devices - from manual mounting through Termux to the use of specialized applications. MIUI 14/15 Android TV 12/13, where security constraints can block network connections. FTP Or Samba, this material is for you.
What is NFS and why is it needed by Xiaomi?
NFS โ It was developed in 1984 for Unix systems, but it's still relevant today because of its speed and low network load. SMB (Samba, which is often used in Windows networks, NFS It's optimized for large files and streaming, making it the perfect solution for the world:
- ๐ฌ Media centers based on Xiaomi Mi Box or Mi TV Stick โ Playing movies in the 4K HDR bufferless;
- ๐ฑ Smartphones with limited memory โ storing photos and documents NAS;
- ๐ฅ๏ธ Backup โ Automatically save backups to a network disk;
- ๐ฎ Game consoles (e.g., Xiaomi Game Pad) โ download ROM-s and saves from the server.
The main advantage NFS before alternatives (WebDAV, FTP) โ Minimal reading/write delays, such as when playing a video through Kodi, the difference in penguing between the two NFS And Samba can reach 30-50 MS, which is critical for heavy files:
โ ๏ธ Attention: NFS It doesn't encrypt traffic by default. If your network isn't secure, data can be intercepted. NFS top-up VPN or on a local network with WPA3.
| Protocol | Speed. | Security | Difficulty setting up | Xiaomi support |
|---|---|---|---|---|
| NFS | โญโญโญโญโญ | โญโญ (codeless) | โญโญโญ | Requires manual installation |
| SMB (Samba) | โญโญโญโญ | โญโญโญ (s SMB3) | โญโญ | Built in MIUI |
| WebDAV | โญโญโญ | โญโญโญโญ (HTTPS) | โญโญ | Works through applications |
| FTP | โญโญ | โญ (without TLS) | โญ | Built into the file manager |
Preparing Xiaomi device for installation NFS
Before installing NFS-The client must complete several mandatory steps, and omission of these steps may result in mounting errors or complete protocol failure.
- Check out the Android version: On smartphones: Settings โ The phone. โ Version. MIUI; On TV boxes: Settings โ The device โ About the system.
NFS It works consistently on Android 9+, but MIUI 12 and later additional permits may be required.
Activate the Developer Mode:
Go to Settings. โ About the phone and 7 times click on the version MIUI. In the developer menu (Settings) โ Additionally. โ For developers, turn on:
- ๐ง Debugging by USB;
- ๐ง Allow debugging (only for the purpose of ADB);
- ๐ง Do not turn off the screen during charging (for settings).
- Install Termux (for manual mounting): Download Termux from F-Droid (Google Play version is outdated). After installation, update the packages: pkg update &&pkg upgrade pkg install root-repo
Developer mode is on
Installed by Termux (from F-Droid)
Version of Android (9) tested+)
Backup of important data is made
Unplugged. MIUI Optimization (if any)-->
On Android devices TV (For example, Mi Box S or Mi TV Stick's a bit more complicated because of the interface constraints:
- ๐ฑ๏ธ Connect the mouse to USB/Bluetooth navigationally;
- ๐ Use it. OTG-keyboard;
- ๐ฑ Install Send Files to TV transmit APK-phone-file.
โ ๏ธ Note: Some Xiaomi models (e.g. Redmi Note) 10 Pro MIUI 13) function MIUI Optimization blocks network connections. To turn it off, run it in Termux: su setprop. persist.sys.miui_optimization_disabled 1 Reboot Requires root rights!
Method 1: Installation NFS via Termux (without root)
This method is suitable for most Xiaomi devices based on Android 9-14 We're going to use Termux to edit it. NFS-handball.
Steps:
- Install the necessary packages: pkg install nfs-utils busybox If E: Package not found occurs, update the repositories: pkg update pkg install unstable-repo
- Create a mounting point: mkdir ~/nfs_share This folder will be used to access network files.
- Connect. NFS-mount -t nfs -o soft,intr,rsize=8192,wsize=8192 [IP_server: [path to folder] ~/nfs_share Example NAS Synology: mount -t nfs -o soft 192.168.1.100:/volume1/media ~/nfs_share
To verify the connection successfully, the server must be allowed to NFS-export for your device. edit the file for this. /etc/exports server-side:
/volume1/media 192.168.1.0/24(rw,sync,no_subtree_check,no_root_squash)๐ก
If files are not displayed in Termux after mounting, follow the command ls. -la ~/nfs_share. If the folder is empty, check the permissions on the server or add the nolock option to the mount command.
For automatic connection when starting Termux, add the mount command to the file ~/.bashrc:
- Open the file: nano ~/.bashrc
- Add a line to the end: mount -t nfs -o soft 192.168.1.100:/volume1/media ~/nfs_share
- Save it (Ctrl)+O) and close (Ctrl)+X).
โ ๏ธ Attention: MIUI 14+ Termux can be closed by the system. 5-10 To avoid this, use the command: termux-wake-lock or install the Keep Alive app from F-Droid.
Method 2: Use of client applications (for beginners)
If Termux seems complicated, you can use specialized apps from Google Play that provide a graphical interface for connecting. NFS, but have limitations:
- ๐ Require Android 8+;
- ๐ฐ Some functions are paid;
- ๐ ๏ธ They may not work on MIUI optimised.
The best apps for Xiaomi:
| Annex | Support for NFS | Root | Price. | Reference |
|---|---|---|---|---|
| NFS Manager | โญโญโญโญ | No. | Free (Premium) $2.99) | Google Play |
| Total Commander + Plugin | โญโญโญ | No. | Free of charge. | Google Play |
| FX File Explorer | โญโญโญโญ | No. | $3.99 | Google Play |
| X-plore File Manager | โญโญโญ | No. | Free (Donate) | Google Play |
Let's look at the settings by example. NFS Manager:
- Install the application and open it.
- Click + in the lower right corner and select Add NFS Share.
- Fill in the fields: Server IP: 192.168.1.100 (address NAS); Shared Folder: /volume1/media; Mount Point: /sdcard/nfs_share (folder).
Advanced Options
soft,intr,rsize=8192,wsize=8192Save
Mount
How to check the speed NFS-connection?
For Android. TV (Like the Mi Box. 4K) Use Total Commander with a plugin NFS Plugin:
- Install Total Commander and NFS Plugin via Send Files to TV.
- Open Total Commander, go to the Network โ Add a network connection.
- Choose. NFS and enter the server data.
- Save the connection and check access to the files.
Instructions:
- Check the support NFS at the core: su cat /proc/filesystems | grep nfs If the output is empty, the kernel does not support NFS. In this case, you will need to flash the custom core (for example, FrancoKernel for Poco). F3).
- Create a mounting point: mkdir /data/nfs_share
- Add a line to /etc/fstab: 192.168.1.100:/volume1/media /data/nfs_share nfs rsize=8192,wsize=8192,soft,intr 0 0 To edit fstab, use Root Explorer or the command: su mount -o rw,remount /system nano /etc/fstab
- Apply the changes: mount -a
๐ก
Mounting through /etc/fstab โ It's the most reliable way, but it requires root and caution. A syntax error can lead to bootloop).
For automatic mounting during loading:
- Create a script. /data/local/userinit.sh:
- Make it executable: chmod 755 /data/local/userinit.sh
- Add a script call to the /init.rc (Experience with Android is required!).
โ ๏ธ Attention: On devices with MIUI and active MIUI Optimization system scripts can be blocked before editing. /init.rc disable optimization (see section "Preparation of the device").
Setting up NFS server-side (NAS, Linux, Windows)
So that Xiaomi device can connect to the NFS-So, if you want to do this, you need to set it up properly on the server.
1. Setting up NFS on Synology/QNAP
For NAS synology-based DSM or QNAP QTS:
- Open the control panel. โ Shared folder.
- Select the folder you want to export and click Change.
- Go to the tab. NFS And add a rule: IP-address: 192.168.1.0/24 (your subnet); Privileges: Reading/Write; Root squash: Disable; Asynchronous Recording: Enable.
Apply the changes and restart the service NFS.
2. Setting up NFS Linux (Ubuntu/Debian)
Install the server NFS:
sudo apt update
sudo apt install nfs-kernel-serverEdit the file. /etc/exports:
/media/nfs_share 192.168.1.0/24(rw,sync,no_subtree_check,no_root_squash)Apply the settings:
sudo exportfs -a
sudo systemctl restart nfs-kernel-server3.Tune in. NFS on Windows (through WSL third-party)
Windows does not support NFS-server out of the box, but there are workarounds:
- ๐ช WSL 2 (Windows Subsystem for Linux) โ Install Ubuntu and configure it NFS inside;
- ๐ฅ๏ธ haneWIN NFS Server โ paid software with a graphical interface;
- ๐ FreeNFS โ a free utility for basic configuration.
Synology
QNAP
Own server on Linux
Windows + WSL
Another option-->
After setting up the server, check the availability of the balls from the Xiaomi device:
showmount -e 192.168.1.100If the command returns the list of exported folders, the server is configured correctly.
Addressing common problems with NFS Xiaomi
Even with the right setup NFS Xiaomi can make mistakes. Let's look at typical situations and their solutions.
| Mistake. | Reason. | Decision |
|---|---|---|
| mount: Operation not permitted | Lack of rights or MIUI lock-in | Turn off MIUI Optimization or use root |
| mount: Network is unreachable | Network or firewall problems | Check ping to server, disable firewall on router |
| mount: Access denied | Incorrect access rights on the server | Check it out. /etc/exports and reset NFS-server |
| The folder is mounted, but empty. | Option. no_subtree_check not listed | Add in. no_subtree_check into /etc/exports |
| Low transmission speed | Non-optimal parameters rsize/wsize | Increase the values to 32768 or 65536 |
If NFS connects, but files are not played in the player (for example, in Kodi or in the game). VLC), problem:
- ๐ต Codecs, set up MX Player with support AC3/DTS;
- ๐ถ Buffering โ Increase the cache in the player settings;
- ๐ Access Rights โ Check that files on the server are readable.
How to eliminate stuttering video when playing on NFS?
To diagnose network problems, use the commands in Termux:
ping 192.168.1.100
traceroute 192.168.1.100
nmap -p 2049 192.168.1.100Port 2049 is to be opened on the server.