[Solved] How I got fsck.f2fs to get unstuck and fix not booting PP
#1
My PinePhone (v1.2, 3GB running Mobian testing from eMMC) was low on battery and the red USB C cable was not perfectly plugged so it got unplugged, the PP abruptly turned off and ... it would not boot again Confused . That was the first time ever I got this problem, in 11 months of daily driving (no other phone), and a lot of drained batteries (thats bad, I know...).


tldr: to fix it I flashed Mobian on a micro sd card, then fsck.f2fs was not working but after I mounted / unmounted /dev/mmcblk2p2 I retried fsck.f2fs which then surprisingly worked and apparently fixed any problem left.


More details:

First log I got using the UART cable:


Quote:(initramfs) Begin: Will now check root file system ... fsck from util-linux 2.37.3
[/sbin/fsck.f2fs (1) -- /dev/mmcblk2p2] fsck.f2fs -a /dev/mmcblk2p2
Info: Fix the reported corruption.
Info: Segments per section = 1
Info: Sections per zone = 1
Info: sector size = 512
Info: total sectors = 60022751 (29307 MB)
Info: MKFS version
  "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
Info: FSCK version
  from "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
    to "Linux version 5.15-sunxi64 (salsaci@runner-2v5hjq-3-project-17289439-concurrent-0) (gcc (Debian 11.2.0-14) 11.2.0, GNU ld (GNU Binutils for Debian) 2.37.50.20220106) #1 SMP Fri Jan 21 03:21:56 UTC 2022"
Info: superblock features = 0 :
Info: superblock encrypt level = 0, salt = 00000000000000000000000000000000
Info: total FS sectors = 60022744 (29307 MB)
Info: CKPT version = 5439e3cc
[f2fs_do_mount:3563] record_fsync_data failed
fsck exited with status code 255
done.
Failure: File system check of the root filesystem failed
The root filesystem on /dev/mmcblk2p2 requires a manual fsck


After that here is what I would got when running fsck:


Quote:fsck /dev/mmcblk2p2
fsck from util-linux 2.37.3
Info: Segments per section = 1
Info: Sections per zone = 1
Info: sector size = 512
Info: total sectors = 60022751 (29307 MB)
Info: MKFS version
  "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
Info: FSCK version
  from "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
    to "Linux version 5.15-sunxi64 (salsaci@runner-2v5hjq-3-project-17289439-concurrent-0) (gcc (Debian 11.2.0-14) 11.2.0, GNU ld (GNU Binutils for Debian) 2.37.50.20220106) #1 SMP Fri Jan 21 03:21:56 UTC 2022"
Info: superblock features = 0 :
Info: superblock encrypt level = 0, salt = 00000000000000000000000000000000
Info: total FS sectors = 60022744 (29307 MB)
Info: CKPT version = 5439e3cc
[f2fs_do_mount:3563] record_fsync_data failed


Then I was able to mount then unmount /dev/mmcblk2p2 from Mobian running on sdcard, and I got fsck to work:


Quote:fsck from util-linux 2.37.2
Info: Segments per section = 1
Info: Sections per zone = 1
Info: sector size = 512
Info: total sectors = 60022751 (29307 MB)
Info: MKFS version
  "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
Info: FSCK version
  from "Linux version 5.9.0-5-amd64 (debian-kernel@lists.debian.org) (gcc-10 (Debian 10.2.1-1) 10.2.1 20201207, GNU ld (GNU Binutils for Debian) 2.35.1) #1 SMP Debian 5.9.15-1 (2020-12-17)"
    to "Linux version 5.10-sunxi64 (builder@mobian) (gcc (Debian 10.2.1-6) 10.2.1 20210110, GNU ld (GNU Binutils for Debian) 2.35.2) #1 SMP PREEMPT Sat Aug 7 12:10:38 UTC 2021"
Info: superblock features = 0 :
Info: superblock encrypt level = 0, salt = 00000000000000000000000000000000
Info: total FS sectors = 60022744 (29307 MB)
Info: CKPT version = 5439e436
Info: checkpoint state = 45 :  crc compacted_summary unmount
[FSCK] Unreachable nat entries                        [Ok..] [0x0]
[FSCK] SIT valid block bitmap checking                [Ok..]
[FSCK] Hard link checking for regular file            [Ok..] [0xa]
[FSCK] valid_block_count matching with CP            [Ok..] [0x27997d]
[FSCK] valid_node_count matching with CP (de lookup)  [Ok..] [0x2522a]
[FSCK] valid_node_count matching with CP (nat lookup) [Ok..] [0x2522a]
[FSCK] valid_inode_count matched with CP              [Ok..] [0x24c4d]
[FSCK] free segment_count matched with CP            [Ok..] [0x148d]
[FSCK] next block offset is free                      [Ok..]
[FSCK] fixing SIT types
[FSCK] other corrupted bugs                          [Ok..]

Done: 132.889887 secs


Then the PP was booting fine  Smile
  Reply


Messages In This Thread
[Solved] How I got fsck.f2fs to get unstuck and fix not booting PP - by gab - 02-07-2022, 04:46 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
Wink PINEPHONE not booting Touchwood 2 1,285 02-23-2024, 07:27 AM
Last Post: Touchwood
  Dual booting usagi 7 5,933 08-17-2022, 03:51 AM
Last Post: shulamy
  [solved]no more call received [ModemManager, QMI protocol error] alexandre 1 3,244 04-19-2021, 05:57 AM
Last Post: alexandre
  Booting from micro SD card? ryo 2 3,694 11-27-2020, 11:50 AM
Last Post: ak42
  [SOLVED] bluetooth issues ak42 0 2,123 11-11-2020, 07:45 PM
Last Post: ak42
  [SOLVED] Brand new pinephone bricked almost immediately out of box... Cree 9 15,541 07-31-2020, 01:51 PM
Last Post: wibble

Forum Jump:


Users browsing this thread: 3 Guest(s)