View Single Post
Posts: 2,152 | Thanked: 1,490 times | Joined on Jan 2006 @ Czech Republic
#2
Originally Posted by crackhead View Post
1. I have read (notably here) that one caveat of booting off mmc is the propensity for the card to be get corrupted, and that a "fsck -fy /dev/mmcblk0p2" needs to be run every now and again. If that is the case, is it a bad idea to simply run this command on every boot, especially since I hardly ever turn off/reboot the device? Will it be painfully slow? If it's not a bad idea, is there a boot script that would be an ideal place to run the command?
It is easier to use ext3. it is not needed then and result is same or better. Try to search this forum I think I explained few times how to do it.

As for fsck, well there is no fsck in initfs (which mounts the ext2 rootfs) and when the system already boots into rootfs where fsck.ext2 may be available, it is too late. You could remount rootfs read only and then run it and them probably reboot if it did some modifications (not sure how to check for this, probably some fsck exit code). fsck.ext2 could be added to initfs but using ext3 is better idea.
Originally Posted by crackhead View Post
Am I even correct in assuming that saving the contents of the FAT partition will enable me to get back to a default state quickly? I believe I read that as one of the benefits somewhere.
Booting from mmc does not use FAT partition at all (except optional swapfile), did you mean EXT2 instead of FAT? Best for rootfs backup is to use GNU tar in case your rootfs is ext2/3 (i.e. mmc) and mkfs.jffs2 for rootfs in flash -then you can just reflash with the backup jffs2 image. Again search this forum for 'mkfs.jff2' or 'sumtool' for guide how to make backup image of flash directly on device. As for transferring backup to computer, both tar and mkfs.jffs2 could be run over ssh to backup directly to file on the PC or you could just copy it later over USB if you backup to file on FAT partition.