CreateBootableMedia


#!/bin/sh
unset LANG LC_ALL
LC_ALL=C
export LC_ALL
cp -p fdboot.img fdbootbu.img
mount -o loop fdbootbu.img /mnt
rm -fr DIR-ROM
mkdir DIR-ROM
url=""
url="${url}http://dlcdnet.asus.com/pub/ASUS/EeePC/EeePC1000H/"
url="${url}1000H-ASUS-2102.zip"
( cd DIR-ROM && wget "${url}" )
( cd DIR-ROM && unzip 1000H-ASUS-2102.zip )
cp DIR-ROM/1000H-ASUS-2102.ROM /mnt/1000H.ROM
rm -fr DIR-EXE
mkdir DIR-EXE
url=""
url="${url}http://trweb.cwsurf.de/wordpress_301-de/wordpress/wp-content/uploads/2011/04/"
url="${url}AFUDOS241-ENGINEERING_EDITION.zip"
( cd DIR-EXE && wget "${url}" )
( cd DIR-EXE && mv AFUDOS241-ENGINEERING_EDITION.zip AFUDOS241-ENGINEERING_EDITION.zip.gz )
( cd DIR-EXE && gzip -d AFUDOS241-ENGINEERING_EDITION.zip.gz )
( cd DIR-EXE && unzip AFUDOS241-ENGINEERING_EDITION.zip )
cp DIR-EXE/AFUDOS241.exe /mnt/AFUDOS.EXE
ls -al /mnt
md5sum fdboot.img /mnt/1000H.ROM /mnt/AFUDOS.EXE | sort -k2 > md5sums.cur
diff md5sums.cur md5sums.ref && echo MD5SUMS good || echo MD5SUMS bad
rm md5sums.cur
rm -fr DIR-ROM DIR-EXE
umount /mnt
ls -al fdboot.img fdbootbu.img
cat /proc/partitions
echo "Be sure that there are no mounts w.r.t. /dev/sdb*"
echo dd if=fdbootbu.img of=/dev/sdb bs=512

Stephan K.H. Seidl