FSCK.F2FS(8)

okay bestie, welcome to the fsck.f2fs(8) manual page β€” the System Manager's Manual one πŸ’– it's all about checking a Linux F2FS file system, and yes it's exactly as iconic as it sounds.

✨ NAME ✨

fsck.f2fs β€” check a Linux F2FS file system. that's the name, no cap 🫢

πŸŽ€ SYNOPSIS πŸŽ€

fsck.f2fs [ -a enable auto fix ] [ -f enable force fix ] [ -H ] [ -M show file map ] [ -p enable preen mode ] [ -t show stored directory tree ] [ -d debugging-level ] device

πŸ¦‹ DESCRIPTION πŸ¦‹

okay so fsck.f2fs is the bestie that checks an f2fs file system (usually it's hanging out on a disk partition). the device is the special file corresponding to the device, like /dev/sdXX β€” literally that.

the exit code returned by fsck.f2fs is 0 on success and -1 on failure. periodt πŸ’…

🌸 OPTIONS 🌸

  • -a enable auto fix β€” turns on auto-fix mode: it runs the file system check only if a bug was reported by the F2FS kernel module. it's disabled by default, bestie πŸŽ€
  • -f enable force fix β€” enables fixing all the inconsistency in the partition. yes, "inconsistency" β€” keeping the original wording, not me being weird 😭
  • -H β€” specify support write hint. that's the whole vibe ✨
  • -M show files map β€” enables showing all the filenames and inode numbers stored in the image. lowkey useful πŸ‘€
  • -p enable preen mode β€” same as "-a" to support general fsck convention.
  • -t show stored directory tree β€” enables showing every directory entries in the partition. every single one, no skipping πŸ’€
  • -d debugging-level β€” specify the level of debugging options. the default number is 0, which shows basic debugging messages.
  • -N β€” answer "No" for all questsions. (their spelling, not mine 😭)
  • --nolinear-lookup β€” tune linear lookup fallback, must specify an argument: 0 enables linear lookup, 1 disables linear lookup. for android case, it will disable linear lookup by default.
  • --fault_injection=%d enable fault injection β€” enable fault injection in all supported types with specified injection rate.
  • --fault_type=%d configure fault injection type β€” support configuring fault injection type, should be enabled with fault_injection option. fault type value is shown below, and it supports single or combined type πŸ”₯
===========================      ===========
Type_Name                        Type_Value
===========================      ===========
FAULT_SEG_TYPE                   0x00000001
FAULT_SUM_TYPE                   0x00000002
FAULT_SUM_ENT                    0x00000004
FAULT_NAT                        0x00000008
FAULT_NODE                       0x00000010
FAULT_XATTR_ENT                  0x00000020
FAULT_COMPR                      0x00000040
FAULT_INODE                      0x00000080
FAULT_DENTRY                     0x00000100
FAULT_DATA                       0x00000200
FAULT_QUOTA                      0x00000400

πŸ’– AUTHOR πŸ’–

initial checking code was written by Byoung Geun Kim <bgbg.kim@samsung.com>. Jaegeuk Kim <jaegeuk@kernel.org> reworked most parts of the codes to support fixing any corrupted images. kings πŸ‘‘βœ¨

🌈 AVAILABILITY 🌈

fsck.f2fs is available from git://git.kernel.org/pub/scm/linux/kernel/git/jaegeuk/f2fs-tools.git β€” go get it, bestie 🫢

🧚 SEE ALSO 🧚


peace out from the FSCK.F2FS(8) footer, bestie β€” that's the end of the page, signed FSCK.F2FS(8), no extra date shown in the original πŸ’œβœ¨

πŸ“¦ where this page comes from
  • arch rolling: f2fs-tools 1.17.0-1 Β· GPL-2.0-only AND (GPL-2.0-only OR LGPL-2.1-only)
  • πŸ’– girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms