It DOES work (according to this this post & I also "emergency" tested it on my unit) on openAAF as well (with a little mod or even better by hand using telnet session)
Only issue is that nanddump does NOT have -c option on openAAF image
But we do not need the kernel.bin at all (as it is the same as in installed image - which we have anyway!)
After all it is only a script:
Code:
#!/bin/sh
cd $1
FREESIZE=`df -m "$1" | tr -s " " | tail -n1 | cut -d' ' -f4 | sed "s/Available/0/`
if ! [ "$FREESIZE" -gt "128" ]; then
echo "Das Backupmedium "$1 "wurde nicht gefunden oder freier Speicherplatz reicht nicht aus"
echo "FullBackup wird beendet!!! Bitte Mountpoint eures Sticks überprüfen"
exit 0
else
rm -f $1/burn.bat > /dev/null 2>&1
touch $1/burn.bat
echo "macprog2 $2" > burn.bat
echo "flasherase -all" >> burn.bat
echo "flash -noheader usbdisk0:vmlinux.gz nandflash0.kernel" >> burn.bat
echo "flash -noheader usbdisk0:rootfsn.img nandflash0.avail0" >> burn.bat
echo 'setenv -p STARTUP "boot -z -elf nandflash0.kernel:"' >> burn.bat
echo "boot -z -elf nandflash0.kernel:" >> burn.bat
echo "Erstelle Burn.bat mit der Mac Adresse : $2 ... "
echo "Erstelle Full-Backup auf $1 ... bitte warten"
echo "Dumping kernel ... bitte warten"
/usr/bin/nanddump -n -o -b -c -f $1/kernel.bin /dev/mtd2
chmod 777 $1/kernel.bin
mv $1/kernel.bin $1/vmlinux.gz
mount -t jffs2 /dev/mtdblock0 /mnt/backup
echo "Erstelle Image ... bitte warten"
ddbrootfs -n -l -e131072 -d/mnt/backup -o$1/rootfsn.img
echo "TeamRed "> $1/version.txt
date >> $1/version.txt
umount -f /mnt/backup
echo "FullBackup erfolgreich"
fi