Login  Register

Re: what does Factory restore work?

Posted by hans2 on Feb 27, 2016; 12:31am
URL: https://itus.accessinnov.com/what-does-Factory-restore-work-tp182p186.html

/etc/itus/factory_reset.sh is:
if [[ `df | grep -c overlay` == "1" ]]; then
        umount /overlay
fi
sleep 1
mkdir -p /factory_reset
sleep 1
mount /dev/mmcblk0p1 /factory_reset
sleep 1
cd /factory_reset
sleep 1
rm ItusrouterImage
sleep 5
rm ItusbridgeImage
sleep 5
rm ItusgatewayImage
sleep 5
cp ItusrestoreImage ItusrouterImage
sleep 10
cp ItusrestoreImage ItusgatewayImage
sleep 10
cp ItusrestoreImage ItusbridgeImage
sleep 10
cd /
sleep 1
umount /factory_reset
sleep 1
umount -a
sleep 1
reboot -f

in other words, ItusrestoreImage is just the source of the router, gateway and bridge images.

The boot segment should look like:
-rwxr-xr-x    1 root     root      35862152 Nov 26 03:04 ItusbridgeImage
-rwxr-xr-x    1 root     root      58078856 Nov 26 03:02 ItusgatewayImage
-rwxr-xr-x    1 root     root      58144392 Nov 26 03:01 ItusrouterImage
-rwxr-xr-x    1 root     root      40859016 Nov 27 13:08 ItusrestoreImage
-rwxr-xr-x    1 root     root        470976 Mar 27  2015 octboot2.bak
-rwxr-xr-x    1 root     root        470976 Mar 27  2015 octboot2.bin
-rwxr-xr-x    1 root     root       1138416 May 27  2015 u-boot-octeon_rhino_itus7x.bin
No more: Shield Pro v1, Chaos Calmer, FW 1.51 SP1