November 16, 20241 yr I am at a loss here. I created a share in Unraid. I can access the share with the username and password given from my computer with no issues. I typed the same IP address, username, and password in Protect and I keep getting Failed to connect to server. Has anyone been successful connect Protect to Unraid for backup? I see a bunch of stuff around Synology but not much around Unraid. To add, the username and password have no special characters or uppercase, everything is lowercase.
November 19, 20241 yr Community Expert Connecting Unifi Protect to an Unraid SMB share for backup can be tricky due to differences in how Unifi Protect and Unraid handle SMB configurations. Here's a step-by-step guide to help you troubleshoot and establish the connection: Verify SMB Share Configuration in Unraid Check Share Settings: Go to Shares in the Unraid web GUI. Select the share you created for Unifi Protect backups. Ensure the following: Export: Set to Yes (SMB) Security: Set to Public, Secure, or Private: For testing, start with Public to rule out permission issues. If using Secure or Private, ensure the correct user permissions are set. Verify SMB Service: Go to Settings > SMB and confirm that the SMB service is enabled and running. Optional: Enable SMBv1 compatibility if Unifi Protect requires it (some older firmware may). Create a Dedicated User: Create a dedicated Unraid user for Unifi Protect: Go to Users in Unraid. Add a user (e.g., unifiprotect) with a simple, lowercase password. Test the Share from Another Machine: From a Windows or macOS device, connect to the share using the same credentials you configured in Unifi Protect: \\<Unraid-IP>\ShareName Confirm read/write access. #if you cant do this then you need to fix permission... cd /path touch file.txt echo hi >> file.txt cat file.txt rm file.txt #fix permissins: cd /path chmod 777 -R * chown nobody:nogroup 2. Configure Unifi Protect Backup Access Unifi Protect Settings: In the Unifi Protect web interface, go to Settings > Backup > Backup to Network Storage. Enter the Share Details: 3. Troubleshooting Failed Connections a. Check Unifi Protect Logs: If the test fails, check the Protect logs for detailed error messages. This can help identify issues like authentication or path format problems. b. Enable Extended SMB Logging on Unraid: Go to Settings > SMB > SMB Extras and add the following: [global] log level = 3 This will enable detailed logging for SMB access attempts. Check /var/log/samba/log.smbd for errors. c. DNS or Network Issues: Ensure the Unifi Protect device can resolve the Unraid server's IP or hostname. Test using both IP address and hostname for the share path. d. SMB Protocol Mismatch: Unifi Protect may require specific SMB versions. To enforce compatibility: Go to Settings > SMB > SMB Extras in Unraid. [global] server min protocol = SMB2 server max protocol = SMB3 Restart the SMB service. e. Permissions Issue: If using Secure or Private share security, ensure the Unraid user has read/write access to the share. 4. Advanced Workarounds (I wouild write my own smb conf...) try nfs? If the direct connection fails after troubleshooting: NFS Share: Unifi Protect supports NFS in some cases. Export the share using NFS: In Unraid, go to Shares > Your Share > NFS Security Settings. Enable NFS export. nfs://<Unraid-IP>/mnt/user/<ShareName> Manually Mount on Protect Device: SSH into the Unifi Protect device and test the SMB connection manually smbclient -U <username> //<Unraid-IP>/<ShareName> 5. Verify Backup Process After establishing the connection: Ensure backups are being created in the Unraid share. Check file permissions and available space in the share.
October 14, 2025Oct 14 I just attempted this because I've had a neighbour dispute and I wanted to dump the last week of footage from 2 cameras to my unraid NAS for long term storageIt just kept creating .partial files over and over like it was stuck in a loop[global] server min protocol = SMB2 server max protocol = SMB3This seems to have done the trick now.The export on unifi is very slow, takes about 5-10 minutes for each 1 hour chunk to "Prepare" but I haven't had a failed .partial since I made that change so just letting it churn throughI know this is digging up an old thread, but thank you ☺️
March 11Mar 11 On 11/19/2024 at 11:56 AM, bmartino1 said:my ownSorry for digging up old thread. Anyone manage to link unifi protect to unraid share drive? I’m currently able to connect to the NAS IP and select the share folder but the storage status shows 0b.
March 11Mar 11 Community Expert 6 hours ago, Enjawd said:Sorry for digging up old thread. Anyone manage to link unifi protect to unraid share drive?I’m currently able to connect to the NAS IP and select the share folder but the storage status shows 0b.Depends on what you're trying to do now with it. Like explained in the above post...Unify United system and unified protect requires smb2 protocol On unraid you have to turn off the array, go to settings SMB and add these lines to the SMB extra..[global]server min protocol = SMB2server max protocol = SMB3This seems to have done the trick now....Is noted above...With this, your UniFi NVR device and your cameras can point to the network share on unraid so where samba and copy the data off and into the share. Otherwise you install a VM. You install Debian And you install UniFi protect and the UniFi console in a VM. And using Debbie and samba connection you connect to your your virtual iofs and/SMB tonu raid And use the UniFi console and even if I protect on that VM...with the release of unfi OS for a VM I would recemd runing a debain VM and ther unfi stack there any more...ITAdOn IT SolutionsUbiquiti introduces UniFi OS Server for self-hostingUbiquiti has just launched the UniFi OS Server in Early Access, enabling users to self-host the full UniFi network stack on their own hardware.And data here GitHubGitHub - lemker/unifi-os-server: Run UniFi OS Server in D...Run UniFi OS Server in Docker or Kubernetes. Contribute to lemker/unifi-os-server development by creating an account on GitHub.
March 12Mar 12 11 hours ago, bmartino1 said:Depends on what you're trying to do now with it.Like explained in the above post...Unify United system and unified protect requires smb2 protocolOn unraid you have to turn off the array, go to settings SMB and add these lines to the SMB extra..[global]server min protocol = SMB2server max protocol = SMB3This seems to have done the trick now....Is noted above...With this, your UniFi NVR device and your cameras can point to the network share on unraid so where samba and copy the data off and into the share.Otherwise you install a VM. You install DebianAnd you install UniFi protect and the UniFi console in a VM.And using Debbie and samba connection you connect to your your virtual iofs and/SMB tonu raid And use the UniFi console and even if I protect on that VM...with the release of unfi OS for a VM I would recemd runing a debain VM and ther unfi stack there any more...ITAdOn IT SolutionsUbiquiti introduces UniFi OS Server for self-hostingUbiquiti has just launched the UniFi OS Server in Early Access, enabling users to self-host the full UniFi network stack on their own hardware.And data hereGitHubGitHub - lemker/unifi-os-server: Run UniFi OS Server in D...Run UniFi OS Server in Docker or Kubernetes. Contribute to lemker/unifi-os-server development by creating an account on GitHub.Hi hi!Thanks for your reply.I've added this line in unraid setting (see screenshot)Uploading Attachment...For Unifi protect, see attach screenshot, seems like it can connect to unraid and select share folder but it just reflect as 0 bUploading Attachment...So im not sure what is wrong.
March 12Mar 12 Community Expert your pictures broke up let me retest and re go over an example setup. To be clear You shouldn't need to replace samba!I replace unraid samba for my own.as seen here:idealy you will need to seutp a unfi protect share:in my case I'm also using zfszfs create data/unifi-protectas I'm using my own smb extra and not using unraid shares:example share data:[samba] create mask = 0775 force create mode = 0777 force directory mode = 0777 force group = root force user = root guest ok = Yes map hidden = Yes map system = Yes path = /host/samba read only = No fruit:encoding = nativeSo, I will make a new share with my own custom settings. that can be saved with the global smb2 info under the smb extra options...root@OMV:/host# lsDockers/ PBS/ PVE/ TimeMachine/ Users/ samba/ unifi-protect/root@OMV:/host#and since I'm overiding unraids config:root@OMV:/boot/config# lsBasic.key domain.cfg go machine-id plugins/ random-seed share.cfg ssh/default/ drift go~ modprobe.d/ plugins-error/ savedpcidata.json shares/ ssl/disk.cfg editor.cfg hosts network.cfg plugins-removed/ secrets.tdb smb-override.conf super.datdocker.cfg forcesync ident.cfg passwd pools/ shadow smbpasswd wireguard/root@OMV:/boot/config# nano smb-override.confif using the user script to make your own share for all... I would add my own custom share setting...*this is the same samba I'm running and shared in the user scripts forum post above...You shouldn't have to replace samba and you can't use unraids share setting for the share for the same item... instead you can add this to the smb extra and use that to make a custom share for unifiexample:confirm withroot@OMV:~# testparmso now I have a share called unifi from my unraid system...Since your seeing a connect but no data... you may need to fix / set permissions...root@OMV:/host# chmod 777 -R unifi-protect/root@OMV:/host# chown nobody:users -R unifi-protect/You should now see a unifi share in unraid:Now on unifi:in unifi protect go to settings:I first go to add accountthen select nas:and fill in data:*Connect with a made unraid user.. made in the users tab in web ui:choose the share:with that the nas folder is linked:then enable Continuous Archiving and add the cameras you want data saved to protect:select dection....click apply0b is normal to see...as the Continuous Archiving kicks in once the unifi device hits its limit on space / quota..seehttps://community.ui.com/questions/UniFi-Protect-with-external-NAS/c6f24e56-f650-4bf6-818b-0323aa927257?reply=2andhttps://community.ui.com/questions/Archiving-ALL-Detections-to-NAS/74fb9819-d8d3-42af-a0c8-b3410f725c86so I think your confused as you seem to have the share setup corectly... abd are corecty connected and unifi when it hits the camera space and detection at next run will save when unifi storage quota is hit and it will move/save the data on the nas before erasing...I'm not aware of any other issue and this has been the sucessful setup betweeen other unfi setups i've done int eh past with unraid..othewise i just finsihed adding unfi server os where you can run unifi protect via docker on unraid and have protect conect and save data on unraid via docker volume pathing... Edited March 12Mar 12 by bmartino1 data - typo
March 12Mar 12 Community Expert you can test archive by foring a archive...go to playback and select a detection..and with the selection hit archive to nas ip / unraid...it...thats it you will then see the detection on the unraid nas...so the 0 bytes is noraml .. and current detections need archived and new should auto once quot/retention is hit.takes a while for it to report and update data... if you manualy sent detections... Edited March 12Mar 12 by bmartino1
March 12Mar 12 Silly question, does this only works with Unifi cameras? or Onvif camera works as well? Cause I notice based on screenshot, seems like we need to select with camera with detection.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.