Problems with Ext2fs on a CF card.
- From: Mic <michaelzwrk@xxxxxxxxx>
- Date: 20 May 2007 06:59:55 -0700
Hi.
I use a Compact Flash card (SanDisk) to hold an ext2 Linux File System
on an embedded system, running 2.6 Linux.
The CF is connected in true IDE mode.
I have numerous problems running a File System from the CF: mkfs does
not work on partitions, fsck reports errors after booting from the CF
etc. and the FS gets corrupted over time.
Below is the procedure I follow to put the FS on the CF.
Please advise if you recognize any faults in the procedure or have any
idea what else I can check - any help is most welcome.
Here is what I do:
------------------------
Boot over NFS
mkfs.ext2 /dev/hda
mount -t ext2 /dev/hda /mnt/hda/
cd /mnt/hda
tar -xvjf /my_file_system.tar.bz2
Boot over CF.
Notes and Problems I see:
------------------------
1. cannot mkfs partition
if I use fdisk to create partitions (i.e. hda1, hda2), mkfs fails.
That's why I run it straight on /dev/hda.
fdisk:
Disk /dev/hda: 512 MB, 512483328 bytes
16 heads, 63 sectors/track, 993 cylinders
Units = cylinders of 1008 * 512 = 516096 bytes
Device Boot Start End Blocks Id System
/dev/hda1 1 497 250456+ 83 Linux
/dev/hda2 498 993 249984 83 Linux
mkfs.ext2 /dev/hda1
mke2fs 1.38 (30-Jun-2005)
mkfs.ext2: No such file or directory while trying to determine
filesystem size
2. fsck complains right after untar
fsck -t ext2 /dev/hda
fsck 1.38 (30-Jun-2005)
e2fsck 1.38 (30-Jun-2005)
/dev/hda was not cleanly unmounted, check forced.
3. After booting from CF, and rebooting over NFS to run fsck:
3. After reboot from CF, another reset:
fsck -t ext2 /dev/hda
fsck 1.38 (30-Jun-2005)
e2fsck 1.38 (30-Jun-2005)
/dev/hda was not cleanly unmounted, check forced.
Pass 1: Checking inodes, blocks, and sizes
Inode 85069, i_blocks is 16, should be 2. Fix<y>? yes
Free blocks count wrong for group #23 (768, counted=769).
Fix<y>? yes...
Thanks for your help,
Michael
.
- Follow-Ups:
- Re: Problems with Ext2fs on a CF card.
- From: phil-news-nospam
- Re: Problems with Ext2fs on a CF card.
- From: Jim Jackson
- Re: Problems with Ext2fs on a CF card.
- Prev by Date: newbe
- Next by Date: Re: embedded VNC
- Previous by thread: newbe
- Next by thread: Re: Problems with Ext2fs on a CF card.
- Index(es):
Relevant Pages
|