Do you have a question? Post it now! No Registration Necessary
September 12, 2006, 9:04 am

i have a cramfs image, which is my rootfs(/ partition) on flash. i
found some discussions which say that upgrading it while mounted was
prone to errors. however if i am doing the upgrade only in my
shutdown scripts (so that most applications are killed by this time)
like this:
mount -o loop -t cramfs rootfs.img /tmp/somedir
eraseall /dev/mtd2
cp rootfs.img /dev/mtd2
export PATH=/tmp/somedir/bin:/tmp/somedir/sbin...
export LD_LIBRARY_PATH=/tmp/somedir/lib
reboot
is there anything that could go wrong? All further programs(with their
libs) should be executed from the
loop mounted rootfs.
or else can i do something like
mount -o loop ...
cd /tmp/somedir
pivot_root . tmp
eraseall, copy
reboot
Since i am upgrading just before reboot only these scripts would be
running. Is there a risk in
either/both of these methods.
Thanks
Ganesh
found some discussions which say that upgrading it while mounted was
prone to errors. however if i am doing the upgrade only in my
shutdown scripts (so that most applications are killed by this time)
like this:
mount -o loop -t cramfs rootfs.img /tmp/somedir
eraseall /dev/mtd2
cp rootfs.img /dev/mtd2
export PATH=/tmp/somedir/bin:/tmp/somedir/sbin...
export LD_LIBRARY_PATH=/tmp/somedir/lib
reboot
is there anything that could go wrong? All further programs(with their
libs) should be executed from the
loop mounted rootfs.
or else can i do something like
mount -o loop ...
cd /tmp/somedir
pivot_root . tmp
eraseall, copy
reboot
Since i am upgrading just before reboot only these scripts would be
running. Is there a risk in
either/both of these methods.
Thanks
Ganesh
Site Timeline
- » Q: IXP425 CPU (over) clock ?
- — Next thread in » Embedded Linux
-
- » how to build JRTPLIB for IXP425 embedded motovista
- — Previous thread in » Embedded Linux
-
- » Crosscompiling for ARM: reloc type R_ARM_ABS32 is not supported for PIC - ...
- — Newest thread in » Embedded Linux
-
- » Ten 860v Electric Eels Wire Themselves In Series
- — The site's Newest Thread. Posted in » Hobby Electronics Basics
-