Hikvision and FreeNAS - works

jimmyt

Getting the hang of it
Sep 12, 2014
101
4
I was able to get Hikvision working with FreeNAS - well for the last 24 hours at least :)

It took a while and the fact that I am still a FreeNAS / Linux newbie didnt help. I will post more detailed instructions as time permits -

but in a nutshell, you need to create a dataset under your volume with a quota. In my case, I created a volume called "Volume1" and then created a dataset under it called "Camera1" with a quota of 100gb and allowed all to read / write it. I then shared that dataset "/mnt/Volume1/Camera1" as an NFS share with the specific camera ip as the only authorized IP address. So far it has worked like a champ!

Playback is not an issue either since I play it back through the camera web interface or the hikvision mobile app. The second camera will follow the first with a new dataset of "Camera2" I plan on experimenting to find the sweet spot of how big a drive can be.
 
as far as I can tell - yes. I tried it with just the volume and it would not work (however, freenas newbie here) :)
 
I think the way the Hikvisions try to auto-manage free space on the NAS requires each cam to have its own volume/dataset.
 
just an update.. freenas has been fine. reverted back to windows smb while I take freenas down and try Lime Tech "unRAID"
 
so freenas has been fine but your going to try a closed commercial product with paid support?

To each his own; I run FreeNAS on $50k+ of hardware and it does a superb job.. Until you are deep into six figure storage solutions I doubt you'll find much better performing software.. all the backend services are the same software packages that Amazon/Google and etc all use for serving files.. FreeNAS just puts a nice GUI on it so your not having to learn unix and how to configure these services directly.
 
good points.. didnt realize it was closed until I jumped in without looking - saw the 3 disk version was free didnt realize you had to buy a key for more. The support forums dont really get into that. its definitely easier than freenas, but it does a lot less. already switched back to freenas. my only issue with freenas is (besides the learning curve) the ecc mobo and ram.. gonna jack the cost up more than paying for unraid.. thought about doing it with just regular ram but everything I read says you gotta have ecc.. you concur? right now freenas is running on an old pc. Going to build a new box with a lian li q25 case here soon :)
 
for a personal NAS, you dont need ECC IMHO
 
From what I read about FreeNAS, a memory error can cause you to lose and/or corrupt all your data, and ECC dramatically reduces the chances of this happening.

I've been running FreeNAS on a very competent box for a couple weeks now and it hasn't been entirely problem-free. On one occasion, a couple machines in the house were getting speeds similar to dialup to the NAS (via a CIFS share), when all other network connections were behaving fine. Rebooting those machines solved that. Just today I was trying to create a directory in the same CIFS share and it stopped responding for a good 15 seconds. I then proceeded to copy a handful of Blue Iris recordings to the new folder at full speed... I don't know what to blame for any of this. In general, I've been happy with FreeNAS so far. When it is operating normally, performance is amazing, far outdoing Intel onboard RAID 5 hosted by Windows file sharing.
 
thanks bp and nayer. - the nas will serve as a backup for pics and such, camera files and ripped blue rays and other media.. non ecc makes it a hell of a lot cheaper. Looking at under $350 for non ecc - over $550 with ecc. Both mini itx and without HDD's

bp - what are the specs on your nas box?
 
If you have bad ram yes you could get corrupted data, however.. if you use good hardware, with good power (UPS!) the likelihood of loosing your ram is very low.. anything that could damage it would surely damage the motherboard and/or cpu aswell. If your worried, before you put important data on it let memtest86+ run on the machine for a half dozen passes or so just to make sure your not starting off with bad ram.

A Large point of ECC ram is the system will recover and stay online when ram chips start to fail, the error checking finds problems before they make the whole system unstable.. this is very important on highly available production systems and/or people with data so valuable the cost of the server is negligible.

I blame windows for your CIFS problems, especially if rebooting the windows client fixed the issue... you might search around for performance tweaks to samba3, maby a few settings can fix it..
I dont use the CIFS/Samba stuff much in production, my big badass FreeNAS at work provides iSCSI disks for 8 VM servers (each with dozens of VMs), NFS Shares for Linux boxes, TimeMachine backups for my department's Mac's and what is hosted on a CIFS share is read-only archive of old releases and various software.. its read-only to protect it from an infected Windows computer.
This is the server if anyone is curious: http://www.cisco.com/c/en/us/products/servers-unified-computing/ucs-c3160-rack-server/index.html
 
I was able to get Hikvision working with FreeNAS - well for the last 24 hours at least :)

It took a while and the fact that I am still a FreeNAS / Linux newbie didnt help. I will post more detailed instructions as time permits -

but in a nutshell, you need to create a dataset under your volume with a quota. In my case, I created a volume called "Volume1" and then created a dataset under it called "Camera1" with a quota of 100gb and allowed all to read / write it. I then shared that dataset "/mnt/Volume1/Camera1" as an NFS share with the specific camera ip as the only authorized IP address. So far it has worked like a champ!

Playback is not an issue either since I play it back through the camera web interface or the hikvision mobile app. The second camera will follow the first with a new dataset of "Camera2" I plan on experimenting to find the sweet spot of how big a drive can be.

you have any screen shots of how you have it configed? I can not get mine to connect to it for nothing. Im able to connect from a pc or mac... but not the camera.
 
Im running Openmedia Vault for NAS, I like it better then Freenas, I have not tried to send my camera video there yet.
 
Camera wont connect at all when tested from the Configuration - Advanced - Storage - NAS tab? (image 3)

Make sure your NFS share is setup per image 6. That is what I needed to get the testing to suceed (image 8)

Image 4 shows that I have created 2 volumes. The "Camera" and "Nas" volumes are on separate ZFS pools. There are 2 1tb drives mirrored for the "Camera" volume and 4 4tb drives in ZFS2 for the "Nas" volume.

Image 5 shows the advanced properties of the NFS "Garage" share which is under Camera\ Future cameras will just get a share under camera - ie Front Porch...

Image 7 shows how to do the quota under the volume - Select the volume and then edit options and then click advanced mode to get to that screen.

I hope that gets you started. Let me know if you have any other questions
 

Attachments

  • 7.jpg
    7.jpg
    101.4 KB · Views: 305
  • 6.jpg
    6.jpg
    43.7 KB · Views: 310
  • 5.jpg
    5.jpg
    69.2 KB · Views: 275
  • 4.jpg
    4.jpg
    163.7 KB · Views: 270
  • 3.jpg
    3.jpg
    96.6 KB · Views: 266
  • 2.jpg
    2.jpg
    101.1 KB · Views: 250
+1 for Openmediavault, really solid product. It's been a a while but last time I looked at Freenas its SMB performance was really bad (FreeBSD problem I think)
It may have been resolved by now.
 
I installed my first FreeNAS box about 8 months ago on fairly powerful Xeon hardware with nice new 6 TB Western Digital Red drives and 1 GB memory for every 1 TB of raw disk. Despite this I had intermittent poor performance with SMB/CIFS (a.k.a. Windows File Sharing). I am talking about it sometimes taking 5 to 15 seconds to load a directory listing of 200 files, and sometimes performing just fine. This occurred even after following advice #4 in this thread: https://forums.freenas.org/index.php?threads/cifs-directory-browsing-slow-try-this.27751/

I found that once I updated from FreeNAS 9.2 to 9.3, the feature flags I had added for disabling DOS attributes were gone. So I re-added them as recommended in the thread and finally, for the last month or so, my FreeNAS has performed perfectly.