Dear all,
i am running kernel 3.17.0 (migrating from 3.5.1) on an am1808 (arm)
based custom board, with a microsd card formatted ext4.
Strangely, starting from a new formatted ext4 partition (mkfs.ext4)
after some files are written from a running application, i getseveral
errors trying fsck.ext4 or trying to remove the files manually (rm):
[root@barix media]# fsck.ext4 /dev/mmcblk0p1
e2fsck 1.42.4 (12-June-2012)
ext2fs_check_desc: Corrupt group descriptor: bad block for block bitmap
fsck.ext4: Group descriptors look bad... trying backup blocks...
/dev/mmcblk0p1 was not cleanly unmounted, check forced.
Resize inode not valid. Recreate<y>? Automount: /dev/mmcblk0p1 inserted
Automount: DEVICE LOCK found quiting...
[root@barix mmcsd0p1]# rm -r soundscape/
EXT4-fs error (device mmcblk0p1): ext4_lookup:1441: inode #260611: comm
rm: 'streams' linked to parent dir
rm: can't stat 'EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad
directory (dir #260611) - no `.' or `..'
soundscape/set_1/configuration/streams/streams': Input/output error
EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad directory (dir
#260618) - no `.' or `..'
EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad directory (dir
#260615) - no `.' or `..'
EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad directory (dir
#260616) - no `.' or `..'
EXT4-fs error (device mmcblk0p1): ext4_lookup:1448: inode #260617: comm
rm: deleted inode referenced: 260611
rm: can't stat 'EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad
directory (dir #260617) - no `.' or `..'
soundscape/set_1/firmware/streams': Input/output error
EXT4-fs error (device mmcblk0p1): ext4_lookup:1448: inode #260619: comm
rm: deleted inode referenced: 260611
rm: can't stat 'EXT4-fs warning (device mmcblk0p1): empty_dir:2520: bad
directory (dir #260619) - no `.' or `..'
soundscape/set_1/schedule/streams': Input/output error
EXT4-fs error (device mmcblk0p1): ext4_lookup:1448: inode #260610: comm
rm: deleted inode referenced: 260611
rm: can't stat 'soundscape/downloads/streams': Input/output error
rm: can't remove 'soundscape/downloads': Directory not empty
rm: can't remove 'soundscape': Directory not empty
[root@barix mmcsd0p1]#
I cannot reproduce these errors on kernel 3.5.1.
Every help is very appreciated.
Angelo
Hi,
still fighting on this.
I am trying now with a simple mkfs.ext3 on the mmc card, verifying just
after with
fsck.ext3.
On kernel 3.5.1 the fsck get a "clean" state, on 3.17.0 i am full of errors.
[root@barix ~]# fsck.ext3 /dev/mmcblk0p1
e2fsck 1.42.4 (12-June-2012)
ext2fs_check_desc: Corrupt group descriptor: bad block for block bitmap
fsck.ext3: Group descriptors look bad... trying backup blocks...
Superblock has an invalid journal (inode 8).
Clear<y>? Automount: /dev/mmcblk0p1 inserted
Automount: DEVICE LOCK found quiting...
yes
*** ext3 journal has been deleted - filesystem is now ext2 only ***
/dev/mmcblk0p1 was not cleanly unmounted, check forced.
Resize inode not valid. Recreate<y>? yes
Pass 1: Checking inodes, blocks, and sizes
The bad block inode looks invalid. Clear<y>? yes
Root inode is not a directory. Clear<y>? yes
Inode 5 has EXTENTS_FL flag set on filesystem without extents support.
Clear<y>? yes
Inode 6 has EXTENTS_FL flag set on filesystem without extents support.
Clear<y>? yes
Inode 8 has EXTENTS_FL flag set on filesystem without extents support.
Clear<y>? yes
Inode 9 has EXTENTS_FL flag set on filesystem without extents support.
Clear<y>? yes
Inode 10 has EXTENTS_FL flag set on filesystem without extents support.
Clear<y>?
.... (continue)
The card is detected correctly, exactly at the same way on both kernels
mmc0: host does not support reading read-only switch. assuming write-enable.
mmc0: new high speed SDHC card at address 0002
mmcblk0: mmc0:0002 SD 7.46 GiB
mmcblk0: p1
But, mkfs.ext3 gives different output:
|kernel 3.5.1 |
||
|[root@barix ~]# mkfs.ext3 /dev/mmcblk0p1 |
|mke2fs 1.42.4 (12-June-2012) |
|Filesystem label= |
|OS type: Linux |
|Block size=4096 (||log||=2) |
|Fragment size=4096 (||log||=2) |
|Stride=0 blocks, Stripe width=0 blocks |
|488640 inodes, 1952881 blocks |
|97644 blocks (5.00%) reserved ||for||the super user |
|First data block=0 |
|Maximum filesystem blocks=2000683008 |
|60 block groups |
|32768 blocks per group, 32768 fragments per group |
|8144 inodes per group |
|Superblock backups stored on blocks: |
|||32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632 |
||
|Allocating group tables: done |
|Writing inode tables: done |
|Creating journal (32768 blocks): done |
|Writing superblocks and filesystem accounting information: done |
||
|kernel 3.17.0 |
||
|[root@barix ~]# mkfs.ext3 /dev/mmcblk0p1 |
|mke2fs 1.42.4 (12-June-2012) |
|Filesystem label= |
|OS type: Linux |
|Block size=4096 (||log||=2) |
|Fragment size=4096 (||log||=2) |
|Stride=0 blocks, Stripe width=0 blocks |
|240000 inodes, 959232 blocks |
|47961 blocks (5.00%) reserved ||for||the super user |
|First data block=0 |
|Maximum filesystem blocks=985661440 |
|30 block groups |
|32768 blocks per group, 32768 fragments per group |
|8000 inodes per group |
|Superblock backups stored on blocks: |
|||32768, 98304, 163840, 229376, 294912, 819200, 884736 |
||
|Allocating group tables: done |
|Writing inode tables: done |
|Creating journal (16384 blocks): done |
|Writing superblocks and filesystem accounting information: done
The recent 3.17.0 kernel shows
- about half of |||"Maximum filesystem blocks"
- |||8000 inodes per group instead of 8144 on 3.5.1
- about half of the inodes.
Could this be the reason of the mmc issues i am having ?
many thanks
|
The I/O errors, the "automount: inserted" message, the fact that it
shows up on ext3 and ext4, makes it smell very much like a hardware
problem (or possibly a mmc device driver problem). It could be caused
by a fake mmc card that (if you bought it from a street vendor or some
the micro center discount bin at the checkout counter, try getting a
brand name flash from a reputable source --- you get what you pay
for).
It could be caused by flaky hardware, or a MMC drive; it could be
caused by an MMC driver problem. It doesn't seem like it's a file
system problem.
Regards,
- Ted
Hi Theodore,
thanks for the hints
well, i have same board with old kernel 3.5.1 perfectly working,
so i can exclude hardware issues.
Same for card issues, same card moved on kernel 3.5.1 board
behave correctly.
Strangely, seems i have "write" issues, if i format the card on PC
and put it back on the soc board, i get no errors on fsck.
If i format on soc board, and fsck from PC i get errors.
I am now moving the discussion to linux-mmc,
Regards,
angelo
On 19/11/2014 14:50, Theodore Ts'o wrote:
> The I/O errors, the "automount: inserted" message, the fact that it
> shows up on ext3 and ext4, makes it smell very much like a hardware
> problem (or possibly a mmc device driver problem). It could be caused
> by a fake mmc card that (if you bought it from a street vendor or some
> the micro center discount bin at the checkout counter, try getting a
> brand name flash from a reputable source --- you get what you pay
> for).
>
> It could be caused by flaky hardware, or a MMC drive; it could be
> caused by an MMC driver problem. It doesn't seem like it's a file
> system problem.
>
> Regards,
>
> - Ted