OESF Portables Forum

Everything Else => Zaurus Distro Support and Discussion => Distros, Development, and Model Specific Forums => Archived Forums => Angstrom & OpenZaurus => Topic started by: markk on October 28, 2004, 12:18:08 pm

Title: e2fsck for ext2 SD cards
Post by: markk on October 28, 2004, 12:18:08 pm
I've been trying to work out the best place to put
Code: [Select]
e2fsck -y /dev/mmcda1in my startup scripts. I think this is necessary as many problems seem to stem from cumulative errors on the SD card.

Various suggestions on the OpenEmbedded Wiki (OpenZaurusFineTuning (http://openembedded.org/oe_wiki/index.php/OpenZaurusFineTuning), How to setup OpenZaurus with SD card as root filesystem (http://openembedded.org/oe_wiki/index.php/How%20to%20se%20up%20OpenZaurus%20with%20SD%20card%20as%20root%20filesystem)) have also implied this, but there doesn't appear to be a definitive answer anywhere.

This proot (http://www.oxstone.com/Z_move_root_to_sdcard/proot) script includes the check, but has the line commented out. Alternatively it could go somewhere in /etc/init.d/mountall.sh or even /etc/init.d/sd.

Any ideas?
Title: e2fsck for ext2 SD cards
Post by: zenyatta on October 28, 2004, 04:12:07 pm
As a general rule, I put my custom startup stuff in separate scripts (I copy something in /etc/init.d and edit). It gives me more flexibility (I can change when the script is to be run) and easier administration (it's easier to remember where I put things and also easier to back up). I suggest you create something like /etc/init.d/sdfsck and put it there.

z.
Title: e2fsck for ext2 SD cards
Post by: oxstone on October 29, 2004, 09:13:42 pm
Quote
I've been trying to work out the best place to put
Code: [Select]
e2fsck -y /dev/mmcda1in my startup scripts. I think this is necessary as many problems seem to stem from cumulative errors on the SD card.

Various suggestions on the OpenEmbedded Wiki (OpenZaurusFineTuning (http://openembedded.org/oe_wiki/index.php/OpenZaurusFineTuning), How to setup OpenZaurus with SD card as root filesystem (http://openembedded.org/oe_wiki/index.php/How%20to%20se%20up%20OpenZaurus%20with%20SD%20card%20as%20root%20filesystem)) have also implied this, but there doesn't appear to be a definitive answer anywhere.

This proot (http://www.oxstone.com/Z_move_root_to_sdcard/proot) script includes the check, but has the line commented out. Alternatively it could go somewhere in /etc/init.d/mountall.sh or even /etc/init.d/sd.

Any ideas?
The problem is that e2fsck isn't included in the default 3.5.1 ROM. That explains why the e2fsck line is commented in the "proot" script you talked about: it's supposed to be ran on a freshly flashed Zaurus.
You could install the e2fsprogs-e2fsck package and un-comment the e2fsck line in the script. Tell us if that works!
Title: e2fsck for ext2 SD cards
Post by: otzenpunk on November 01, 2004, 10:42:51 am
Quote
Quote
I've been trying to work out the best place to put
Code: [Select]
e2fsck -y /dev/mmcda1in my startup scripts. I think this is necessary as many problems seem to stem from cumulative errors on the SD card.

Various suggestions on the OpenEmbedded Wiki (OpenZaurusFineTuning (http://openembedded.org/oe_wiki/index.php/OpenZaurusFineTuning), How to setup OpenZaurus with SD card as root filesystem (http://openembedded.org/oe_wiki/index.php/How%20to%20se%20up%20OpenZaurus%20with%20SD%20card%20as%20root%20filesystem)) have also implied this, but there doesn't appear to be a definitive answer anywhere.

This proot (http://www.oxstone.com/Z_move_root_to_sdcard/proot) script includes the check, but has the line commented out. Alternatively it could go somewhere in /etc/init.d/mountall.sh or even /etc/init.d/sd.

Any ideas?
The problem is that e2fsck isn't included in the default 3.5.1 ROM. That explains why the e2fsck line is commented in the "proot" script you talked about: it's supposed to be ran on a freshly flashed Zaurus.
You could install the e2fsprogs-e2fsck package and un-comment the e2fsck line in the script. Tell us if that works!

How to setup OpenZaurus with SD card as root filesystem (http://openembedded.org/oe_wiki/index.php/How%20to%20se%20up%20OpenZaurus%20with%20SD%20card%20as%20root%20filesystem) has a proot file with the e2fsck line enabled. I use it and it works for me. Obviously you have to install the e2fsprogs-e2fsck package to the original (flash rom) installation and not to the sd card installation. Only thing I had to do was booting without sd card, installing the package to root directory and reboot with the sd card inserted.