Hey,

On 2023-11-05 04:12, Hervé Werner wrote:
> I faced this issue on real data but I struggled to find a reliable scenario 
> to reproduce it. Here is what I just came up with:
>   sudo mkfs -t ext4 -O fast_commit,inline_data /dev/sdb
>   sudo mount /dev/sdb /mnt/
>   sudo install -d -o myuser /mnt/annex
>   cd /mnt/annex
>   git init && git annex init
>   for i in {1..2}; do
>     for i in {1..10000}; do
>       dd if=/dev/urandom of=file-${i} bs=1K count=1 2>/dev/null
>     done
>     git annex add -J cpus . >/dev/null && git annex sync -J cpus && git annex 
> fsck -J cpus >/dev/null
>     git rm * && git annex sync  && git annex dropunused all
>   done
> 
> Then at some point the following error appears:
>   EXT4-fs error (device sdb): ext4_map_blocks:577: inode #3942343: block 4: 
> comm git-annex:w: lblock 1 mapped to illegal pblock 4 (length 1)

Just a quick note to confirm that I can reliably reproduce the issue
using a USB stick and the above script on Bookworm. After running the
reproducer for a few minutes I start getting the following in dmesg:

kernel: EXT4-fs error (device sdf): ext4_map_blocks:607: inode #9971675: block 
4: comm git-annex:w: lblock 1 mapped to illegal pblock 4 (length 1)

uname -a is:
Linux ariel 6.1.0-21-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.90-1 (2024-05-03) 
x86_64 GNU/Linux

Reply via email to