Why is my device unable to connect to my FreeNas Samba drive?
In order to improve the security at home, recently I have decided to install a web surveillance cameras. Most of the consumer grade cameras comes with a micro SD slot. While it is fine to write to the SD card, depending on the storage size of the SD card, one may have to replace the SD card often due to excessive writing onto the sd card. Generally a 128GB micro SD will last longer than a 16GB micro SD as the write operations are evenly spread across all the memory cells which the 128GB micro SD has more.
Alternatively, one can set up a NAS to hold all the recorded videos. In my case, I am using a custom built NAS using the FreeNAS software. Even though there are many consumer grade web surveillance cameras available in the market, most of them does not support recording to external network drives (Enterprised grade surveillance cameras come with NVR support). So I have browsed through all the available cameras that I am able to purchase from physical stores in Singapore, I have finally narrowed down to 1 particular model – DLink DSC-5222LB1. The DLink DSC-5222LB1 is a surveillance camera that comes with many features at affordable price. Not only does it support SMB, it also supports FTP. In addition, it also allows the user to view through the camera via remote connection.
After buying the camera, I went home eagerly to set up the camera. However, when I tried to test the SMB connection with my FreeNAS server, it failed with an error. That got me puzzled as I am able to access my SMB drive via my macbook. At first I tried to tweak my SMB configurations on FreeNAS but that did not work out. Next, I went to check the SMB log files on FreeNAS. Insider the log, I got an error similar to the one below:
[2018/09/16 14:55:56.465368, 3] ../source3/smbd/negprot.c:612(reply_negprot) Requested protocol [NT LM 0.12] [2018/09/16 14:55:56.465426, 3] ../source3/smbd/negprot.c:738(reply_negprot) reply_negprot: No protocol supported ! [2018/09/16 14:55:56.466040, 3] ../source3/smbd/server_exit.c:244(exit_server_common) Server exit (no protocol supported )
With the knowledge of this error message, I went to google for the fix. To my surprise, the latest FreeNAS 11.2 BETA2 has set the default server min protocol for samba to be 2. That means devices that are using SMB1 protocol will not be able to connect to the server. With some time spent on the internet and trying out various suggestions, I managed to find the solution that is able to help me to fix this issue. The solution is to set the aucilliary parameter, server min protocol = NT1, for SMB service under FreeNAS. After restarting the SMB service, everything worked seamless like before.