I have just wasted a few hours of my life wrestling with SMB/CIFS formatting issues with my Hikvision DS-2CD2332-I v5.2.5 build 141201 and since the information required to fix it was scattered across the entire Internet I thought I'd create a post to consolidate it all to hopefully save others the same pain in future.
I am by no means an expert at this and I've only ever setup one camera, so please feel free to contribute with either additional tips, or corrections if you think I have my facts wrong! All constructive input gladly accepted! If any new / corrected information comes to light I will update this post to make it as accurate as possible.
This information may be relevant to Hikvision models other than mine, but I can't confirm / test this.
kyphos has written up a great guide for OSX users which builds on this information.
The Unbendable Rules
1) You must use a drive which is dedicated to the camera recordings. (Also see 'Flexible Rule' #2)
- If any changes are made to the amount of free space on the recordings drive, other than by the camera, the storage status will revert to 'uninitialized'.
- NOTE: In this case, 'drive' refers to a 'logical' drive, not necessarily an entire 'physical' drive, ie; you can use a partition which is part of a larger drive if you like.
- NOTE 2: As per rpc's suggestion, you can also use virtual drives such as a VHD or VHDX volume in Windows, which allows for additional flexibility and removes the requirement to dedicate an entire physical volume or partition for recording.
2) To successfully 'format' a target storage 'HDD', the camera must be able to delete ALL files and folders underneath the shared folder to make it COMPLETELY EMPTY.
- This means that the target share on a Windows system cannot be the root of the drive, because there are hidden system folders which the camera can't delete and so the format will fail.
- NOTE: The 'Format' process won't actually wipe the entire logical drive, but it WILL DELETE ALL FILES AND FOLDERS under the target share, including previous recordings!
- NOTE 2: Another reason why a format might fail is that the user you have configured on the camera doesn't have at least 'Modify' permissions on the target share and or folder and all it's sub-folders (if any).
- Also see 'Flexible Rule' #2
3) You must refer to the share name on your target system with a leading backslash '\'.
- Apparently this should be a forward slash '/' if your target system is linux based, but I can't confirm this.
- You must use a IP address or DNS resolvable name to refer to your target system. NetBIOS / WINS / Workgroup machine names will not work. If in doubt, use an IP.
4) If you make any changes to the setup of your 'NAS' configuration profile, you will need to re-enter the password (even if it 'shows' as dots in the password field).
- If the 'HDD' connect test doesn't pass, there's something wrong.
- NOTE: Don't forget to save using the 'Save' button after any changes!
- NOTE 2: If in doubt, or if it's just not working, despite all entries being correct, 'delete' the 'NAS' HDD profile (see #6)
5) If you make any changes to the target system's storage configuration, you will need to delete the 'NAS' HDD profile (see #6)
6) To 'Delete' a 'NAS' HDD profile, you need to delete all text from all the fields, set the Mounting Type to 'NFS', and save using the 'Save' button. (Also see 'Flexible Rule' #1)
7) Quotas (set on the 'Storage Management' page, are not able to be changed after the 'HDD' has been 'Formatted', they must be changed before the 'Format' is started to be effective.
The Flexible Rules
1) To refresh a screen / tab (especially the 'Storage Management', one), I have found that you need to click on another tab and wait for 5 seconds. Refreshing the browser page may also work.
2) While there seems to be no conclusive consensus about the size limitations of a target drive, the following is the closest I could find:
- Minimum size: 10GB
- Maximum size: 'just under' 250GB*
- Symptoms due to violation of these size limits include being unable to 'Format' the 'HDD', or reversion to 'Uninitialized' status after a period of time, after an apparently successful 'Format'.
- * NOTE: This limitation may be able to be overcome by using the '525 NAS Patch' (origins unknown) which can be found here. While I have installed this patch, I haven't tested it beyond my 249GB recording drive, but there are reports of others using this successfully with up to 4TB drives.
Hopefully this helps someone out in future!
Please let me know if anyone has anything to add / correct!
I am by no means an expert at this and I've only ever setup one camera, so please feel free to contribute with either additional tips, or corrections if you think I have my facts wrong! All constructive input gladly accepted! If any new / corrected information comes to light I will update this post to make it as accurate as possible.
This information may be relevant to Hikvision models other than mine, but I can't confirm / test this.
kyphos has written up a great guide for OSX users which builds on this information.
The Unbendable Rules
1) You must use a drive which is dedicated to the camera recordings. (Also see 'Flexible Rule' #2)
- If any changes are made to the amount of free space on the recordings drive, other than by the camera, the storage status will revert to 'uninitialized'.
- NOTE: In this case, 'drive' refers to a 'logical' drive, not necessarily an entire 'physical' drive, ie; you can use a partition which is part of a larger drive if you like.
- NOTE 2: As per rpc's suggestion, you can also use virtual drives such as a VHD or VHDX volume in Windows, which allows for additional flexibility and removes the requirement to dedicate an entire physical volume or partition for recording.
2) To successfully 'format' a target storage 'HDD', the camera must be able to delete ALL files and folders underneath the shared folder to make it COMPLETELY EMPTY.
- This means that the target share on a Windows system cannot be the root of the drive, because there are hidden system folders which the camera can't delete and so the format will fail.
- NOTE: The 'Format' process won't actually wipe the entire logical drive, but it WILL DELETE ALL FILES AND FOLDERS under the target share, including previous recordings!
- NOTE 2: Another reason why a format might fail is that the user you have configured on the camera doesn't have at least 'Modify' permissions on the target share and or folder and all it's sub-folders (if any).
- Also see 'Flexible Rule' #2
3) You must refer to the share name on your target system with a leading backslash '\'.
- Apparently this should be a forward slash '/' if your target system is linux based, but I can't confirm this.
- You must use a IP address or DNS resolvable name to refer to your target system. NetBIOS / WINS / Workgroup machine names will not work. If in doubt, use an IP.
4) If you make any changes to the setup of your 'NAS' configuration profile, you will need to re-enter the password (even if it 'shows' as dots in the password field).
- If the 'HDD' connect test doesn't pass, there's something wrong.
- NOTE: Don't forget to save using the 'Save' button after any changes!
- NOTE 2: If in doubt, or if it's just not working, despite all entries being correct, 'delete' the 'NAS' HDD profile (see #6)
5) If you make any changes to the target system's storage configuration, you will need to delete the 'NAS' HDD profile (see #6)
6) To 'Delete' a 'NAS' HDD profile, you need to delete all text from all the fields, set the Mounting Type to 'NFS', and save using the 'Save' button. (Also see 'Flexible Rule' #1)
7) Quotas (set on the 'Storage Management' page, are not able to be changed after the 'HDD' has been 'Formatted', they must be changed before the 'Format' is started to be effective.
The Flexible Rules
1) To refresh a screen / tab (especially the 'Storage Management', one), I have found that you need to click on another tab and wait for 5 seconds. Refreshing the browser page may also work.
2) While there seems to be no conclusive consensus about the size limitations of a target drive, the following is the closest I could find:
- Minimum size: 10GB
- Maximum size: 'just under' 250GB*
- Symptoms due to violation of these size limits include being unable to 'Format' the 'HDD', or reversion to 'Uninitialized' status after a period of time, after an apparently successful 'Format'.
- * NOTE: This limitation may be able to be overcome by using the '525 NAS Patch' (origins unknown) which can be found here. While I have installed this patch, I haven't tested it beyond my 249GB recording drive, but there are reports of others using this successfully with up to 4TB drives.
Hopefully this helps someone out in future!
Please let me know if anyone has anything to add / correct!
Last edited: