OK I have some cumulative experience to report:
1. For language hacked Chinese ver. camera with stock firmware (sticker) version between 5.2.5 and 5.3.0:
- You also need to get a dump of /dev/mtdblock1, and check address 0x0000C and 0x8000C, make sure it is 0x02
- Otherwise the camera will fail to upgrade, refuse to prepare initrd with misleading error message "Junk in compressed archive"
- Original source:
How to upgrade a 5.25 mtd hack firmware ?
2. If you have a working Chinese ver. camera mounted 20ft above ground, AND you have no way to provide CIFS share on the network, the following trick can save you hours of efforts:
- Get a unix like shell environment with standard
tools, if you are on Windows, the easiest way I know is to install Git and run Git bash.
- Web downgrade to 5.2.5 if you are on higher version, this is VERY IMPORTANT, otherwise a few minutes later you will be dragging your sorry butt up 20ft to retrieve your $100 paper weight.
- Enable SSH, log on, and prepare the mtd dumps:
-- Run prtHardInfo, note the devtype, and copy the serial number, e.g. DS-2CD2532F-IS2015xxxxx
-- If you have SD card, you can make use of it; otherwise, you will need to use tmpfs (haven't explored this part)
--- cd /mnt/mmc01
--- mkdir DS-2CD2532F-IS2015xxxxx
--- cd DS-2CD2532F-IS2015xxxxx
--- cat /dev/mtdblock5 > mtd5
--- cat /dev/mtdblock6 > mtd6
--- (optional) cat /dev/mtdblock1 > mtd1
--- cd ..
- Now, open your shell environment, e.g. Git bash
-- Download a custom compiled busybox, source:
HIKVISION tweaking - CCTV Forum
-- Upload the file to your SD card storage
--- cat busybox | ssh admin@<your-camera-ip> 'cat > /mnt/mmc01/busybox'
-- Retrieve the dumped mtd files
--- ssh admin@<your-camera-ip> 'cd /mnt/mmc01 && ./busybox tar c DS-2CD2532F-IS2015xxxxxx | ./busybox bzip2 -z | ./busybox base64' > base64 -d | bzip2 -d | tar x
-- After this command, you should have a copy of the dumped mtd files on your local computer, in the folder "DS-2CD2532F-IS2015xxxxxx"
- Make a backup of the files, then perform the mtd hacks
- When you are done, check again, this your last chance avoiding that 20ft up trip. Make sure all the steps checks out exactly right!
- When are are absolutely sure, then in your shell environment
-- tar c DS-2CD2532F-IS2015xxxxx | bzip2 -z | base64 | ssh admin@<your-camera-ip> 'cd /mnt/mmc01 && ./busybox base64 -d | ./busybox bzip2 -d | ./busybox tar xv'
-- After this command, you should have your modified mtd files uploaded to your camera's SD card storage
- Now go to your ssh terminal with the camera
-- Double, triple check that you have firmware version 5.2.5 or below (prtHardInfo will tell you, you can also check Web GUI). Remember, you don't want the $100 paper weight, especially that you will have to climb 20 ft to get it!
-- When are are absolutely sure, then:
--- cd /mnt/mmc01
--- cd DS-2CD2532F-IS2015xxxxx
--- cat mtd5 > /dev/mtdblock5
--- cat mtd6 > /dev/mtdblock6
--- (optional, if changed) cat mtd1 > /dev/mtdblock1
- Reboot and cross your fingers, if you have done everything right, you should get your camera back running in ~1 minute
-- Perform Web upgrade to 5.4.41, this reboot after upgrade will be a bit longer, probably because configuration upgrades
-- Perform Web upgrade to 5.4.5, now you have a much safer firmware version!