Setting up NAS on Xiaomi cameras: the full guide

Modern video surveillance systems require a secure archive space, and cloud services may not always boast an affordable price or no subscription fee. Which is why the question of how to set up a NAS on a Xiaomi camera becomes a priority for many owners of the smart home ecosystem. Local storage allows you to save records directly to the hard drive of a computer or network drive, bypassing paid subscriptions and Internet speed restrictions.

Owners of Xiaomi brand devices and Imilab sub-brand often face the need to expand the functionality of the basic microSD card (NAS) provides not only more volume, but also increased reliability of data, since hard disks in the RAID-Arrays are less prone to sudden failures than flash memory, but the integration process requires an understanding of network protocols and the correct configuration of the router.

In this article, we will discuss in detail the algorithm of actions necessary for successful pairing. IP-You'll learn about protocol nuances. SMB, access features FTP And the key is to use the protocol to solve common connection errors. SMBv1 The old camera models, as the modern standards SMBv2/v3 may not be supported by the device.

Preparation of network environment and equipment

Before you start setting up your software, you need to make sure that the storage is physically available for the camera. Both devices must be on the same LAN, that is, connected to the same router. Xiaomi cameras usually only work in the 2.4 GHz band, so make sure that your NAS or computer with a shared folder also has access to this network.

It is important to reserve static in advance. IP-address for your storage in the router settings. NAS It will change after each router restart, the camera will lose its way to the archive, and the recording will be interrupted. DHCP Server and tether MAC-address of your storage device to a permanent IP.

You should also check the permissions to access the folder you plan to use to record video, which must be available for recording over the network. Often security systems block external connections by default, so you may need to create a separate user with limited rights specifically for the security camera.

  • πŸ“‘ Make sure that the camera and NAS are in the same subnet (for example, 192.168.1.x).
  • πŸ”’ Create a separate account on NAS read-write.
  • πŸ“‚ Create a dedicated folder for the video archive and open it to the network access.
  • πŸ”Œ Check connection stability by pinging the storage address from another device.

⚠️ Note: Using a Guest account on a network storage often leads to login errors. Xiaomi cameras require login and password entry even if the folder is open to everyone.

πŸ“Š What type of storage you plan to use?
Separate NAS (Synology/QNAP)
Shared folder on PC
router USB-port
Cloud Server (VPS)

Selection of data transfer protocol: SMB or FTP

The main choice that users face is between protocols. SMB (Server Message Block and FTP (File Transfer Protocol. SMB It is the standard for Windows local area networks and most of them. NAS-It's more sensitive to versions and security settings, and cameras from different years of release can support different versions of this protocol.

Protocol FTP It is considered lighter and more versatile, it less often causes compatibility problems on older camera firmware. FTP Transmits data in plain form (if not configured) FTPS), This is a theoretically less secure thing, although within a home network, it's rarely a critical issue. FTP-server NAS usually takes less time.

For modern models, such as Xiaomi Mi Home Security Camera 360Β° 2K Pro, it is preferable to use SMB, as it better handles connection interrupts and allows the camera control system to see the status of disk occupancy. FTP often works in blind recording mode, and the free space check may not be displayed correctly in the application.

Why can't the camera see SMB v2/v3?
Many of Xiaomi’s budget cameras are built on older Linux kernels that don’t have built-in libraries to run the plucked-down versions of the SMB protocol (v2 and v3). If your NAS requires encryption, the camera simply won’t be able to log in, so the solution is to enable SMBv1 support in the NAS (File Services section) settings or use FTP.

Step-by-step configuration instructions via the Mi Home app

The configuration process takes place directly in the Mi Home mobile app. After logging into your camera interface, you need to click on three dots in the upper right corner to enter the settings menu, then select the item associated with data storage, which can be called "Storage settings" or "Memory Card Settings".

In the menu that opens, find the switch"NAS Network Storage" or "Network Storage. "When you first turn on, the system will ask you to add a new device. IP-Your storage address, username and password from a user you created earlier.

β˜‘οΈ Checking connection settings

Done: 0 / 1

Once you enter the data, press the check or save button, the camera will try to establish a connection to the address specified. If all parameters are correct, you will see the status "Connected" and the information about the free space. Otherwise, an error message will appear that will help diagnose the problem.

Importantly, some models require manually specifying the path to the folder in a format that is understandable to Linux (e.g. /volume1/video). In other cases, simply specify the root shared folder. Experiment with paths if the automatic definition fails.

Compatibility table and port parameters

It is critical to use the right ports to connect successfully. Standard values can be changed by the network administrator, which will make it impossible to connect. Below is a table with typical parameters for different configurations.

ProtocolStandard port.Type of connectionNote
SMB v1445Local.Required for old cameras
SMB v2/v3445Local.Supported by new models
FTP21Local/ExternalThe greatest compatibility
FTPS990Protected.Rarely supported by cameras

If you have changed standard ports to NAS for security purposes, be sure to include them in the camera settings if the interface allows. In most cases, Xiaomi camera applications involve using standard ports and do not have a field to change them, which requires configuring port port rollover on the router or returning standard values on the server.

πŸ’‘

Use static. IP-Addresses for all surveillance devices. Dynamic address change (DHCP) This will result in the loss of the archive in a few days.

Solving Connection Problems and Errors

One of the most common problems is the β€œUnconnected” error, often because the Windows computer has turned off network detectability. Go to Control Panel β†’ Network Control Center β†’ Change additional sharing settings and enable network discovery for the current network.

Another common cause is antivirus or firewall blocking. Security software may perceive the camera's attempts to write a file as suspicious activity. Add an exception to the firewall for SMB ports or server process.

If the camera says "Authorization Error," double-check the password. Some older versions of the camera firmware don't support complex passwords with special characters. Try using a combination of letters and numbers only. Also make sure that the NAS itself allows this user to record (Write permission).

⚠️ Note: When updating the firmware NAS (for example, Synology DSM or QTS) setting SMB They are often reset to more secure but less compatible values.

Alternative methods: RTSP and third-party software

If the usual means to configure the recording on the NAS can not, you can use the RTSP protocol. Xiaomi cameras broadcast a video stream that can be captured by third-party programs on a computer connected to the storage. To do this, you need to activate RTSP in the camera settings (often you need to change the region to China in the Mi Home application).

Received reference of the type rtsp://username:password@ip_address:port/stream You can insert a recorder program such as VLC, OBS It's called Blue Iris, or iSpy, which can stream directly to a computer's hard drive or network folder.

This method is more resource-intensive for a computer, since video decoding takes place on a PC processor rather than inside the camera, but it gives maximum flexibility in setting up a recording schedule, motion detection, and archive management.

πŸ’‘

Staffing setup NAS in the Mi Home application, it is preferable for the battery life of the camera, since it does not require a computer to be permanently turned on. RTSP It is suitable for advanced users who create a unified security system.

Frequently Asked Questions (FAQ)

Can I use the usual one? USB-A flash drive connected to a router, like NAS?
Many modern routers (Keenetic, ASUS, TP-Link has a function USB-host and built-in server Samba/FTP. You can connect an external hard drive or flash drive to USB-port router, share folder and connect the camera according to the instructions above. NAS.
Why did the camera stop writing on the NAS after the reboot?
Probably changed. IP-your storage address, unless static binding has been configured (Static) DHCP). The camera has memorized the old address and can't find the device. IP post MAC-address NAS, Then reconfigure the camera.
Does all Xiaomi cameras support recording to a network drive?
No, not all models have NAS support. Budget versions like Xiaomi Mi Home Security Camera Basic can have a stripped-down functionality and only support writing on a microSD card. Check the specification of your model on the official website.
How to increase the speed of recording video on NAS?
Make sure both devices are connected via an Ethernet cable rather than Wi-Fi. A wireless connection, especially in the 2.4GHz band, often doesn't provide stable speeds for high-resolution (2K/4K) streaming, which results in frame skipping.