* [f2fs-dev] f2fs node footer data corruption in Android device @ 2025-04-25 5:11 Zhiguo Niu 2025-04-25 5:30 ` Chao Yu via Linux-f2fs-devel 0 siblings, 1 reply; 6+ messages in thread From: Zhiguo Niu @ 2025-04-25 5:11 UTC (permalink / raw) To: Chao Yu, Jaegeuk Kim, linux-f2fs-devel Hi Chao and Jaegeuk, I encountered a problem with node footer data being corrupted on an Android device.(kernel version 6.6 and android version:15) after I merged the following patches, the problem still exists. https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd and there is no nat_bits in mount option. I am still debugging, and would like to ask do you have any other hints or suggestions? The issue seem to be closely related to adb remount. test steps: ping 127.0.0.1 -n 20 > nul adb.exe -s mydevice wait-for-device adb.exe -s mydevice reboot bootloader fastboot -s mydevice erase userdata fastboot -s mydevice erase cache fastboot -s mydevice reboot ping 127.0.0.1 -n 30 > nul adb.exe -s mydevice wait-for-device adb.exe -s mydevice root adb.exe -s mydevice remount adb.exe -s mydevice shell rm -rf /data/somefile/* dmesg: dm-59: userdata partition, dm-7: scratch image partition is for adb remount [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: utf8-12.1.0 with flags 0x0 [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] thanks _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [f2fs-dev] f2fs node footer data corruption in Android device 2025-04-25 5:11 [f2fs-dev] f2fs node footer data corruption in Android device Zhiguo Niu @ 2025-04-25 5:30 ` Chao Yu via Linux-f2fs-devel 2025-04-27 1:49 ` Zhiguo Niu 0 siblings, 1 reply; 6+ messages in thread From: Chao Yu via Linux-f2fs-devel @ 2025-04-25 5:30 UTC (permalink / raw) To: Zhiguo Niu, Jaegeuk Kim, linux-f2fs-devel Zhiguo, On 4/25/25 13:11, Zhiguo Niu wrote: > Hi Chao and Jaegeuk, > > I encountered a problem with node footer data being corrupted on an > Android device.(kernel version 6.6 and android version:15) > after I merged the following patches, the problem still exists. > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd > and there is no nat_bits in mount option. > > I am still debugging, and would like to ask do you have any other > hints or suggestions? > The issue seem to be closely related to adb remount. > > test steps: > ping 127.0.0.1 -n 20 > nul > adb.exe -s mydevice wait-for-device > adb.exe -s mydevice reboot bootloader > fastboot -s mydevice erase userdata > fastboot -s mydevice erase cache > fastboot -s mydevice reboot > ping 127.0.0.1 -n 30 > nul > adb.exe -s mydevice wait-for-device > adb.exe -s mydevice root > adb.exe -s mydevice remount Any change for mount option? Can you provide mount option before/after remount? > adb.exe -s mydevice shell rm -rf /data/somefile/* How about enabling all f2fs tracepoints to catch how target node was updated? Thanks, > > dmesg: > dm-59: userdata partition, dm-7: scratch image partition is for adb remount > [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: > utf8-12.1.0 with flags 0x0 > [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d > [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef > [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > thanks _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [f2fs-dev] f2fs node footer data corruption in Android device 2025-04-25 5:30 ` Chao Yu via Linux-f2fs-devel @ 2025-04-27 1:49 ` Zhiguo Niu 2025-06-05 9:28 ` Chao Yu via Linux-f2fs-devel 0 siblings, 1 reply; 6+ messages in thread From: Zhiguo Niu @ 2025-04-27 1:49 UTC (permalink / raw) To: Chao Yu; +Cc: Jaegeuk Kim, linux-f2fs-devel Hi Chao Chao Yu <chao@kernel.org> 于2025年4月25日周五 13:30写道: > > Zhiguo, > > On 4/25/25 13:11, Zhiguo Niu wrote: > > Hi Chao and Jaegeuk, > > > > I encountered a problem with node footer data being corrupted on an > > Android device.(kernel version 6.6 and android version:15) > > after I merged the following patches, the problem still exists. > > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb > > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea > > https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd > > and there is no nat_bits in mount option. > > > > I am still debugging, and would like to ask do you have any other > > hints or suggestions? > > The issue seem to be closely related to adb remount. > > > > test steps: > > ping 127.0.0.1 -n 20 > nul > > adb.exe -s mydevice wait-for-device > > adb.exe -s mydevice reboot bootloader > > fastboot -s mydevice erase userdata > > fastboot -s mydevice erase cache > > fastboot -s mydevice reboot > > ping 127.0.0.1 -n 30 > nul > > adb.exe -s mydevice wait-for-device > > adb.exe -s mydevice root > > adb.exe -s mydevice remount > > Any change for mount option? Can you provide mount option before/after > remount? > > > adb.exe -s mydevice shell rm -rf /data/somefile/* > > How about enabling all f2fs tracepoints to catch how target node was > updated? Thanks for your quick feedback, this is a useful suggestion. Thanks a lot. > > Thanks, > > > > > dmesg: > > dm-59: userdata partition, dm-7: scratch image partition is for adb remount > > [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: > > utf8-12.1.0 with flags 0x0 > > [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d > > [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef > > [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, > > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > > [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, > > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > > [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, > > node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > > thanks > _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [f2fs-dev] f2fs node footer data corruption in Android device 2025-04-27 1:49 ` Zhiguo Niu @ 2025-06-05 9:28 ` Chao Yu via Linux-f2fs-devel 2025-06-05 10:43 ` Zhiguo Niu 0 siblings, 1 reply; 6+ messages in thread From: Chao Yu via Linux-f2fs-devel @ 2025-06-05 9:28 UTC (permalink / raw) To: Zhiguo Niu; +Cc: Jaegeuk Kim, linux-f2fs-devel On 4/27/25 09:49, Zhiguo Niu wrote: > Hi Chao > > Chao Yu <chao@kernel.org> 于2025年4月25日周五 13:30写道: >> >> Zhiguo, >> >> On 4/25/25 13:11, Zhiguo Niu wrote: >>> Hi Chao and Jaegeuk, >>> >>> I encountered a problem with node footer data being corrupted on an >>> Android device.(kernel version 6.6 and android version:15) >>> after I merged the following patches, the problem still exists. >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd >>> and there is no nat_bits in mount option. >>> >>> I am still debugging, and would like to ask do you have any other >>> hints or suggestions? >>> The issue seem to be closely related to adb remount. >>> >>> test steps: >>> ping 127.0.0.1 -n 20 > nul >>> adb.exe -s mydevice wait-for-device >>> adb.exe -s mydevice reboot bootloader >>> fastboot -s mydevice erase userdata >>> fastboot -s mydevice erase cache >>> fastboot -s mydevice reboot >>> ping 127.0.0.1 -n 30 > nul >>> adb.exe -s mydevice wait-for-device >>> adb.exe -s mydevice root >>> adb.exe -s mydevice remount >> >> Any change for mount option? Can you provide mount option before/after >> remount? >> >>> adb.exe -s mydevice shell rm -rf /data/somefile/* >> >> How about enabling all f2fs tracepoints to catch how target node was >> updated? > Thanks for your quick feedback, this is a useful suggestion. > Thanks a lot. Hi Zhiguo, Can this testcase reproduce the bug stably? and any progress on this issue? Thanks, >> >> Thanks, >> >>> >>> dmesg: >>> dm-59: userdata partition, dm-7: scratch image partition is for adb remount >>> [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: >>> utf8-12.1.0 with flags 0x0 >>> [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d >>> [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef >>> [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>> [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>> [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>> thanks >> _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [f2fs-dev] f2fs node footer data corruption in Android device 2025-06-05 9:28 ` Chao Yu via Linux-f2fs-devel @ 2025-06-05 10:43 ` Zhiguo Niu 2025-06-06 8:19 ` Chao Yu via Linux-f2fs-devel 0 siblings, 1 reply; 6+ messages in thread From: Zhiguo Niu @ 2025-06-05 10:43 UTC (permalink / raw) To: Chao Yu; +Cc: Jaegeuk Kim, linux-f2fs-devel Chao Yu <chao@kernel.org> 于2025年6月5日周四 17:28写道: > > On 4/27/25 09:49, Zhiguo Niu wrote: > > Hi Chao > > > > Chao Yu <chao@kernel.org> 于2025年4月25日周五 13:30写道: > >> > >> Zhiguo, > >> > >> On 4/25/25 13:11, Zhiguo Niu wrote: > >>> Hi Chao and Jaegeuk, > >>> > >>> I encountered a problem with node footer data being corrupted on an > >>> Android device.(kernel version 6.6 and android version:15) > >>> after I merged the following patches, the problem still exists. > >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb > >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea > >>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd > >>> and there is no nat_bits in mount option. > >>> > >>> I am still debugging, and would like to ask do you have any other > >>> hints or suggestions? > >>> The issue seem to be closely related to adb remount. > >>> > >>> test steps: > >>> ping 127.0.0.1 -n 20 > nul > >>> adb.exe -s mydevice wait-for-device > >>> adb.exe -s mydevice reboot bootloader > >>> fastboot -s mydevice erase userdata > >>> fastboot -s mydevice erase cache > >>> fastboot -s mydevice reboot > >>> ping 127.0.0.1 -n 30 > nul > >>> adb.exe -s mydevice wait-for-device > >>> adb.exe -s mydevice root > >>> adb.exe -s mydevice remount > >> > >> Any change for mount option? Can you provide mount option before/after > >> remount? > >> > >>> adb.exe -s mydevice shell rm -rf /data/somefile/* > >> > >> How about enabling all f2fs tracepoints to catch how target node was > >> updated? > > Thanks for your quick feedback, this is a useful suggestion. > > Thanks a lot. > > Hi Zhiguo, > > Can this testcase reproduce the bug stably? and any progress on this issue? Hi Chao, after debug, the reason of the problem is the "case itself" Data encrypted is enabled in android platform, so when full erase userdata partition , the metadat partition is also needed to erase, otherwise there will be probabilistic data decryption issue. cause inode metadata messed up. this issue will no reproduce after add: fastboot -s mydevice erase metadata in scripts. thanks for your suggentions and focus on.^^ > Thanks, > > >> > >> Thanks, > >> > >>> > >>> dmesg: > >>> dm-59: userdata partition, dm-7: scratch image partition is for adb remount > >>> [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: > >>> utf8-12.1.0 with flags 0x0 > >>> [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d > >>> [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef > >>> [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, > >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > >>> [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, > >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > >>> [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, > >>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] > >>> thanks > >> > _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [f2fs-dev] f2fs node footer data corruption in Android device 2025-06-05 10:43 ` Zhiguo Niu @ 2025-06-06 8:19 ` Chao Yu via Linux-f2fs-devel 0 siblings, 0 replies; 6+ messages in thread From: Chao Yu via Linux-f2fs-devel @ 2025-06-06 8:19 UTC (permalink / raw) To: Zhiguo Niu; +Cc: Jaegeuk Kim, linux-f2fs-devel On 6/5/25 18:43, Zhiguo Niu wrote: > Chao Yu <chao@kernel.org> 于2025年6月5日周四 17:28写道: >> >> On 4/27/25 09:49, Zhiguo Niu wrote: >>> Hi Chao >>> >>> Chao Yu <chao@kernel.org> 于2025年4月25日周五 13:30写道: >>>> >>>> Zhiguo, >>>> >>>> On 4/25/25 13:11, Zhiguo Niu wrote: >>>>> Hi Chao and Jaegeuk, >>>>> >>>>> I encountered a problem with node footer data being corrupted on an >>>>> Android device.(kernel version 6.6 and android version:15) >>>>> after I merged the following patches, the problem still exists. >>>>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git/commit/?h=dev-test&id=eba08414c585f90760c4312f57dea78ea45cb5cb >>>>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=19426c4988aa85298c1b4caf2889d37ec5c80fea >>>>> https://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs.git/commit/fs/f2fs?h=dev-test&id=c2ecba026586cda6c7dc0fe9e6e60e7e9386c3bd >>>>> and there is no nat_bits in mount option. >>>>> >>>>> I am still debugging, and would like to ask do you have any other >>>>> hints or suggestions? >>>>> The issue seem to be closely related to adb remount. >>>>> >>>>> test steps: >>>>> ping 127.0.0.1 -n 20 > nul >>>>> adb.exe -s mydevice wait-for-device >>>>> adb.exe -s mydevice reboot bootloader >>>>> fastboot -s mydevice erase userdata >>>>> fastboot -s mydevice erase cache >>>>> fastboot -s mydevice reboot >>>>> ping 127.0.0.1 -n 30 > nul >>>>> adb.exe -s mydevice wait-for-device >>>>> adb.exe -s mydevice root >>>>> adb.exe -s mydevice remount >>>> >>>> Any change for mount option? Can you provide mount option before/after >>>> remount? >>>> >>>>> adb.exe -s mydevice shell rm -rf /data/somefile/* >>>> >>>> How about enabling all f2fs tracepoints to catch how target node was >>>> updated? >>> Thanks for your quick feedback, this is a useful suggestion. >>> Thanks a lot. >> >> Hi Zhiguo, >> >> Can this testcase reproduce the bug stably? and any progress on this issue? > Hi Chao, > after debug, the reason of the problem is the "case itself" > Data encrypted is enabled in android platform, so when full erase > userdata partition , > the metadat partition is also needed to erase, otherwise there will > be probabilistic data decryption issue. > cause inode metadata messed up. > this issue will no reproduce after add: > fastboot -s mydevice erase metadata > in scripts. > thanks for your suggentions and focus on.^^ Zhiguo, Ah, got it, thanks for your explanation. >> Thanks, >> >>>> >>>> Thanks, >>>> >>>>> >>>>> dmesg: >>>>> dm-59: userdata partition, dm-7: scratch image partition is for adb remount >>>>> [ 3.893630] F2FS-fs (dm-59): Using encoding defined by superblock: >>>>> utf8-12.1.0 with flags 0x0 >>>>> [ 3.930213] F2FS-fs (dm-59): Mounted with checkpoint version = 38485b2d >>>>> [ 20.584169] F2FS-fs (dm-7): Mounted with checkpoint version = 42130ef >>>>> [ 38.039122] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>>>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>>>> [ 38.048310] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>>>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>>>> [ 38.051725] F2FS-fs (dm-59): inconsistent node block, nid:1426, >>>>> node_footer[nid:129565021,ino:2756062298,ofs:26782845,cpver:6421703165179826912,blkaddr:3577851147] >>>>> thanks >>>> >> _______________________________________________ Linux-f2fs-devel mailing list Linux-f2fs-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel ^ permalink raw reply [flat|nested] 6+ messages in thread
end of thread, other threads:[~2025-06-06 8:19 UTC | newest] Thread overview: 6+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2025-04-25 5:11 [f2fs-dev] f2fs node footer data corruption in Android device Zhiguo Niu 2025-04-25 5:30 ` Chao Yu via Linux-f2fs-devel 2025-04-27 1:49 ` Zhiguo Niu 2025-06-05 9:28 ` Chao Yu via Linux-f2fs-devel 2025-06-05 10:43 ` Zhiguo Niu 2025-06-06 8:19 ` Chao Yu via Linux-f2fs-devel
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.