Namjae Jeon | b59d0ba | 2013-08-04 23:09:40 +0900 | [diff] [blame] | 1 | What: /sys/fs/f2fs/<disk>/gc_max_sleep_time |
| 2 | Date: July 2013 |
| 3 | Contact: "Namjae Jeon" <namjae.jeon@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 4 | Description: Controls the maximum sleep time for gc_thread. Time |
| 5 | is in milliseconds. |
Namjae Jeon | b59d0ba | 2013-08-04 23:09:40 +0900 | [diff] [blame] | 6 | |
| 7 | What: /sys/fs/f2fs/<disk>/gc_min_sleep_time |
| 8 | Date: July 2013 |
| 9 | Contact: "Namjae Jeon" <namjae.jeon@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 10 | Description: Controls the minimum sleep time for gc_thread. Time |
| 11 | is in milliseconds. |
Namjae Jeon | b59d0ba | 2013-08-04 23:09:40 +0900 | [diff] [blame] | 12 | |
| 13 | What: /sys/fs/f2fs/<disk>/gc_no_gc_sleep_time |
| 14 | Date: July 2013 |
| 15 | Contact: "Namjae Jeon" <namjae.jeon@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 16 | Description: Controls the default sleep time for gc_thread. Time |
| 17 | is in milliseconds. |
Namjae Jeon | d2dc095 | 2013-08-04 23:10:15 +0900 | [diff] [blame] | 18 | |
| 19 | What: /sys/fs/f2fs/<disk>/gc_idle |
| 20 | Date: July 2013 |
| 21 | Contact: "Namjae Jeon" <namjae.jeon@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 22 | Description: Controls the victim selection policy for garbage collection. |
Mauro Carvalho Chehab | 54a19b4 | 2020-10-30 08:40:50 +0100 | [diff] [blame] | 23 | Setting gc_idle = 0(default) will disable this option. Setting: |
| 24 | |
| 25 | =========== =============================================== |
| 26 | gc_idle = 1 will select the Cost Benefit approach & setting |
| 27 | gc_idle = 2 will select the greedy approach & setting |
| 28 | gc_idle = 3 will select the age-threshold based approach. |
| 29 | =========== =============================================== |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 30 | |
| 31 | What: /sys/fs/f2fs/<disk>/reclaim_segments |
| 32 | Date: October 2013 |
| 33 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 34 | Description: This parameter controls the number of prefree segments to be |
| 35 | reclaimed. If the number of prefree segments is larger than |
| 36 | the number of segments in the proportion to the percentage |
| 37 | over total volume size, f2fs tries to conduct checkpoint to |
| 38 | reclaim the prefree segments to free segments. |
| 39 | By default, 5% over total # of segments. |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 40 | |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 41 | What: /sys/fs/f2fs/<disk>/main_blkaddr |
Jaegeuk Kim | a4db59a | 2019-11-22 11:53:10 -0800 | [diff] [blame] | 42 | Date: November 2019 |
| 43 | Contact: "Ramon Pantin" <pantin@google.com> |
| 44 | Description: |
| 45 | Shows first block address of MAIN area. |
| 46 | |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 47 | What: /sys/fs/f2fs/<disk>/ipu_policy |
| 48 | Date: November 2013 |
| 49 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 50 | Description: Controls the in-place-update policy. |
| 51 | updates in f2fs. User can set: |
Mauro Carvalho Chehab | 54a19b4 | 2020-10-30 08:40:50 +0100 | [diff] [blame] | 52 | |
| 53 | ==== ================= |
| 54 | 0x01 F2FS_IPU_FORCE |
| 55 | 0x02 F2FS_IPU_SSR |
| 56 | 0x04 F2FS_IPU_UTIL |
| 57 | 0x08 F2FS_IPU_SSR_UTIL |
| 58 | 0x10 F2FS_IPU_FSYNC |
| 59 | 0x20 F2FS_IPU_ASYNC, |
| 60 | 0x40 F2FS_IPU_NOCACHE |
| 61 | ==== ================= |
| 62 | |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 63 | Refer segment.h for details. |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 64 | |
| 65 | What: /sys/fs/f2fs/<disk>/min_ipu_util |
| 66 | Date: November 2013 |
| 67 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 68 | Description: Controls the FS utilization condition for the in-place-update |
| 69 | policies. It is used by F2FS_IPU_UTIL and F2FS_IPU_SSR_UTIL policies. |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 70 | |
Jaegeuk Kim | c1ce1b0 | 2014-09-10 16:53:02 -0700 | [diff] [blame] | 71 | What: /sys/fs/f2fs/<disk>/min_fsync_blocks |
| 72 | Date: September 2014 |
| 73 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 74 | Description: Controls the dirty page count condition for the in-place-update |
| 75 | policies. |
Jaegeuk Kim | c1ce1b0 | 2014-09-10 16:53:02 -0700 | [diff] [blame] | 76 | |
Jaegeuk Kim | 853137c | 2018-08-09 17:53:34 -0700 | [diff] [blame] | 77 | What: /sys/fs/f2fs/<disk>/min_seq_blocks |
| 78 | Date: August 2018 |
| 79 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 80 | Description: Controls the dirty page count condition for batched sequential |
| 81 | writes in writepages. |
Jaegeuk Kim | 853137c | 2018-08-09 17:53:34 -0700 | [diff] [blame] | 82 | |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 83 | What: /sys/fs/f2fs/<disk>/min_hot_blocks |
| 84 | Date: March 2017 |
| 85 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 86 | Description: Controls the dirty page count condition for redefining hot data. |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 87 | |
Chao Yu | a2a12b6 | 2017-10-28 16:52:33 +0800 | [diff] [blame] | 88 | What: /sys/fs/f2fs/<disk>/min_ssr_sections |
| 89 | Date: October 2017 |
| 90 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 91 | Description: Controls the free section threshold to trigger SSR allocation. |
| 92 | If this is large, SSR mode will be enabled early. |
Chao Yu | a2a12b6 | 2017-10-28 16:52:33 +0800 | [diff] [blame] | 93 | |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 94 | What: /sys/fs/f2fs/<disk>/max_small_discards |
| 95 | Date: November 2013 |
| 96 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 97 | Description: Controls the issue rate of discard commands that consist of small |
| 98 | blocks less than 2MB. The candidates to be discarded are cached until |
| 99 | checkpoint is triggered, and issued during the checkpoint. |
| 100 | By default, it is disabled with 0. |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 101 | |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 102 | What: /sys/fs/f2fs/<disk>/discard_granularity |
| 103 | Date: July 2017 |
| 104 | Contact: "Chao Yu" <yuchao0@huawei.com> |
| 105 | Description: Controls discard granularity of inner discard thread. Inner thread |
Chao Yu | 969d1b1 | 2017-08-07 23:09:56 +0800 | [diff] [blame] | 106 | will not issue discards with size that is smaller than granularity. |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 107 | The unit size is one block(4KB), now only support configuring |
| 108 | in range of [1, 512]. Default value is 4(=16KB). |
Chao Yu | 969d1b1 | 2017-08-07 23:09:56 +0800 | [diff] [blame] | 109 | |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 110 | What: /sys/fs/f2fs/<disk>/umount_discard_timeout |
| 111 | Date: January 2019 |
| 112 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 113 | Description: Set timeout to issue discard commands during umount. |
| 114 | Default: 5 secs |
Jaegeuk Kim | 03f2c02 | 2019-01-14 10:42:11 -0800 | [diff] [blame] | 115 | |
Jaegeuk Kim | 3bac380 | 2014-01-09 21:00:06 +0900 | [diff] [blame] | 116 | What: /sys/fs/f2fs/<disk>/max_victim_search |
| 117 | Date: January 2014 |
| 118 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 119 | Description: Controls the number of trials to find a victim segment |
| 120 | when conducting SSR and cleaning operations. The default value |
| 121 | is 4096 which covers 8GB block address range. |
Jaegeuk Kim | cdfc41c | 2014-03-19 13:31:37 +0900 | [diff] [blame] | 122 | |
Chao Yu | 3465557 | 2018-10-25 16:19:28 +0800 | [diff] [blame] | 123 | What: /sys/fs/f2fs/<disk>/migration_granularity |
| 124 | Date: October 2018 |
| 125 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 126 | Description: Controls migration granularity of garbage collection on large |
| 127 | section, it can let GC move partial segment{s} of one section |
| 128 | in one GC cycle, so that dispersing heavy overhead GC to |
| 129 | multiple lightweight one. |
Chao Yu | 3465557 | 2018-10-25 16:19:28 +0800 | [diff] [blame] | 130 | |
Jaegeuk Kim | 9179682 | 2014-03-19 13:40:09 +0900 | [diff] [blame] | 131 | What: /sys/fs/f2fs/<disk>/dir_level |
| 132 | Date: March 2014 |
| 133 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 134 | Description: Controls the directory level for large directory. If a |
| 135 | directory has a number of files, it can reduce the file lookup |
| 136 | latency by increasing this dir_level value. Otherwise, it |
| 137 | needs to decrease this value to reduce the space overhead. |
| 138 | The default value is 0. |
Jaegeuk Kim | 9179682 | 2014-03-19 13:40:09 +0900 | [diff] [blame] | 139 | |
Jaegeuk Kim | cdfc41c | 2014-03-19 13:31:37 +0900 | [diff] [blame] | 140 | What: /sys/fs/f2fs/<disk>/ram_thresh |
| 141 | Date: March 2014 |
| 142 | Contact: "Jaegeuk Kim" <jaegeuk.kim@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 143 | Description: Controls the memory footprint used by free nids and cached |
| 144 | nat entries. By default, 1 is set, which indicates |
| 145 | 10 MB / 1 GB RAM. |
Jaegeuk Kim | bba681c | 2015-01-26 17:41:23 -0800 | [diff] [blame] | 146 | |
Chao Yu | 6f6d9fe | 2017-06-12 09:44:26 +0800 | [diff] [blame] | 147 | What: /sys/fs/f2fs/<disk>/batched_trim_sections |
Jaegeuk Kim | bba681c | 2015-01-26 17:41:23 -0800 | [diff] [blame] | 148 | Date: February 2015 |
| 149 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 150 | Description: Controls the trimming rate in batch mode. |
| 151 | <deprecated> |
Jaegeuk Kim | 60b99b4 | 2015-10-05 14:49:57 -0700 | [diff] [blame] | 152 | |
| 153 | What: /sys/fs/f2fs/<disk>/cp_interval |
| 154 | Date: October 2015 |
| 155 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 156 | Description: Controls the checkpoint timing, set to 60 seconds by default. |
Chao Yu | ea1a29a0 | 2015-10-12 17:08:48 +0800 | [diff] [blame] | 157 | |
Jaegeuk Kim | d0239e1 | 2016-01-08 16:57:48 -0800 | [diff] [blame] | 158 | What: /sys/fs/f2fs/<disk>/idle_interval |
| 159 | Date: January 2016 |
| 160 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 161 | Description: Controls the idle timing of system, if there is no FS operation |
| 162 | during given interval. |
| 163 | Set to 5 seconds by default. |
Sahitya Tummala | a7d10cf | 2018-09-19 14:18:47 +0530 | [diff] [blame] | 164 | |
| 165 | What: /sys/fs/f2fs/<disk>/discard_idle_interval |
| 166 | Date: September 2018 |
| 167 | Contact: "Chao Yu" <yuchao0@huawei.com> |
| 168 | Contact: "Sahitya Tummala" <stummala@codeaurora.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 169 | Description: Controls the idle timing of discard thread given |
| 170 | this time interval. |
| 171 | Default is 5 secs. |
Sahitya Tummala | a7d10cf | 2018-09-19 14:18:47 +0530 | [diff] [blame] | 172 | |
| 173 | What: /sys/fs/f2fs/<disk>/gc_idle_interval |
| 174 | Date: September 2018 |
| 175 | Contact: "Chao Yu" <yuchao0@huawei.com> |
| 176 | Contact: "Sahitya Tummala" <stummala@codeaurora.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 177 | Description: Controls the idle timing for gc path. Set to 5 seconds by default. |
Jaegeuk Kim | d0239e1 | 2016-01-08 16:57:48 -0800 | [diff] [blame] | 178 | |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 179 | What: /sys/fs/f2fs/<disk>/iostat_enable |
| 180 | Date: August 2017 |
| 181 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 182 | Description: Controls to enable/disable IO stat. |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 183 | |
Chao Yu | ea1a29a0 | 2015-10-12 17:08:48 +0800 | [diff] [blame] | 184 | What: /sys/fs/f2fs/<disk>/ra_nid_pages |
| 185 | Date: October 2015 |
| 186 | Contact: "Chao Yu" <chao2.yu@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 187 | Description: Controls the count of nid pages to be readaheaded. |
| 188 | When building free nids, F2FS reads NAT blocks ahead for |
| 189 | speed up. Default is 0. |
Chao Yu | 2304cb0 | 2016-01-18 18:32:58 +0800 | [diff] [blame] | 190 | |
| 191 | What: /sys/fs/f2fs/<disk>/dirty_nats_ratio |
| 192 | Date: January 2016 |
| 193 | Contact: "Chao Yu" <chao2.yu@samsung.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 194 | Description: Controls dirty nat entries ratio threshold, if current |
| 195 | ratio exceeds configured threshold, checkpoint will |
| 196 | be triggered for flushing dirty nat entries. |
Shuoran Liu | 8f1dbbb | 2016-01-27 09:57:30 +0800 | [diff] [blame] | 197 | |
| 198 | What: /sys/fs/f2fs/<disk>/lifetime_write_kbytes |
| 199 | Date: January 2016 |
| 200 | Contact: "Shuoran Liu" <liushuoran@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 201 | Description: Shows total written kbytes issued to disk. |
Chao Yu | 5641289 | 2017-06-12 22:30:44 +0800 | [diff] [blame] | 202 | |
Eric Biggers | 9ac19fa | 2018-04-23 10:26:30 -0700 | [diff] [blame] | 203 | What: /sys/fs/f2fs/<disk>/features |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 204 | Date: July 2017 |
| 205 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 206 | Description: Shows all enabled features in current device. |
Chao Yu | b32d73a | 2017-10-28 16:52:29 +0800 | [diff] [blame] | 207 | |
Chao Yu | 5641289 | 2017-06-12 22:30:44 +0800 | [diff] [blame] | 208 | What: /sys/fs/f2fs/<disk>/inject_rate |
| 209 | Date: May 2016 |
| 210 | Contact: "Sheng Yong" <shengyong1@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 211 | Description: Controls the injection rate of arbitrary faults. |
Chao Yu | 5641289 | 2017-06-12 22:30:44 +0800 | [diff] [blame] | 212 | |
| 213 | What: /sys/fs/f2fs/<disk>/inject_type |
| 214 | Date: May 2016 |
| 215 | Contact: "Sheng Yong" <shengyong1@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 216 | Description: Controls the injection type of arbitrary faults. |
| 217 | |
| 218 | What: /sys/fs/f2fs/<disk>/dirty_segments |
| 219 | Date: October 2017 |
| 220 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 221 | Description: Shows the number of dirty segments. |
Chao Yu | daeb433 | 2017-06-26 16:24:41 +0800 | [diff] [blame] | 222 | |
| 223 | What: /sys/fs/f2fs/<disk>/reserved_blocks |
| 224 | Date: June 2017 |
| 225 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 226 | Description: Controls target reserved blocks in system, the threshold |
| 227 | is soft, it could exceed current available user space. |
Yunlong Song | 80d4214 | 2017-10-27 20:45:05 +0800 | [diff] [blame] | 228 | |
| 229 | What: /sys/fs/f2fs/<disk>/current_reserved_blocks |
| 230 | Date: October 2017 |
| 231 | Contact: "Yunlong Song" <yunlong.song@huawei.com> |
| 232 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 233 | Description: Shows current reserved blocks in system, it may be temporarily |
| 234 | smaller than target_reserved_blocks, but will gradually |
| 235 | increase to target_reserved_blocks when more free blocks are |
| 236 | freed by user later. |
Jaegeuk Kim | d9872a6 | 2017-08-06 22:09:00 -0700 | [diff] [blame] | 237 | |
| 238 | What: /sys/fs/f2fs/<disk>/gc_urgent |
| 239 | Date: August 2017 |
| 240 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 241 | Description: Do background GC agressively when set. When gc_urgent = 1, |
| 242 | background thread starts to do GC by given gc_urgent_sleep_time |
Daeho Jeong | 0e5e811 | 2020-07-02 13:14:14 +0900 | [diff] [blame] | 243 | interval. When gc_urgent = 2, F2FS will lower the bar of |
| 244 | checking idle in order to process outstanding discard commands |
| 245 | and GC a little bit aggressively. It is set to 0 by default. |
Jaegeuk Kim | d9872a6 | 2017-08-06 22:09:00 -0700 | [diff] [blame] | 246 | |
| 247 | What: /sys/fs/f2fs/<disk>/gc_urgent_sleep_time |
| 248 | Date: August 2017 |
| 249 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 250 | Description: Controls sleep time of GC urgent mode. Set to 500ms by default. |
Sheng Yong | f6df8f2 | 2017-11-22 18:23:38 +0800 | [diff] [blame] | 251 | |
| 252 | What: /sys/fs/f2fs/<disk>/readdir_ra |
| 253 | Date: November 2017 |
| 254 | Contact: "Sheng Yong" <shengyong1@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 255 | Description: Controls readahead inode block in readdir. Enabled by default. |
| 256 | |
| 257 | What: /sys/fs/f2fs/<disk>/gc_pin_file_thresh |
| 258 | Date: January 2018 |
| 259 | Contact: Jaegeuk Kim <jaegeuk@kernel.org> |
| 260 | Description: This indicates how many GC can be failed for the pinned |
| 261 | file. If it exceeds this, F2FS doesn't guarantee its pinning |
| 262 | state. 2048 trials is set by default. |
Chao Yu | 846ae67 | 2018-02-26 22:04:13 +0800 | [diff] [blame] | 263 | |
| 264 | What: /sys/fs/f2fs/<disk>/extension_list |
| 265 | Date: Feburary 2018 |
| 266 | Contact: "Chao Yu" <yuchao0@huawei.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 267 | Description: Used to control configure extension list: |
| 268 | - Query: cat /sys/fs/f2fs/<disk>/extension_list |
| 269 | - Add: echo '[h/c]extension' > /sys/fs/f2fs/<disk>/extension_list |
| 270 | - Del: echo '[h/c]!extension' > /sys/fs/f2fs/<disk>/extension_list |
| 271 | - [h] means add/del hot file extension |
| 272 | - [c] means add/del cold file extension |
Daniel Rosenberg | 4d3aed7 | 2019-05-29 17:49:06 -0700 | [diff] [blame] | 273 | |
| 274 | What: /sys/fs/f2fs/<disk>/unusable |
| 275 | Date April 2019 |
| 276 | Contact: "Daniel Rosenberg" <drosen@google.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 277 | Description: If checkpoint=disable, it displays the number of blocks that |
| 278 | are unusable. |
xuyehan | c67c8c0 | 2021-02-23 09:31:43 +0800 | [diff] [blame] | 279 | If checkpoint=enable it displays the number of blocks that |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 280 | would be unusable if checkpoint=disable were to be set. |
Daniel Rosenberg | 5aba543 | 2019-07-23 16:05:28 -0700 | [diff] [blame] | 281 | |
| 282 | What: /sys/fs/f2fs/<disk>/encoding |
| 283 | Date July 2019 |
| 284 | Contact: "Daniel Rosenberg" <drosen@google.com> |
Hridya Valsaraju | f5fa7c8 | 2020-01-22 10:49:20 -0800 | [diff] [blame] | 285 | Description: Displays name and version of the encoding set for the filesystem. |
| 286 | If no encoding is set, displays (none) |
Hridya Valsaraju | fc7100e | 2020-01-22 10:51:16 -0800 | [diff] [blame] | 287 | |
| 288 | What: /sys/fs/f2fs/<disk>/free_segments |
| 289 | Date: September 2019 |
| 290 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 291 | Description: Number of free segments in disk. |
| 292 | |
| 293 | What: /sys/fs/f2fs/<disk>/cp_foreground_calls |
| 294 | Date: September 2019 |
| 295 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 296 | Description: Number of checkpoint operations performed on demand. Available when |
| 297 | CONFIG_F2FS_STAT_FS=y. |
| 298 | |
| 299 | What: /sys/fs/f2fs/<disk>/cp_background_calls |
| 300 | Date: September 2019 |
| 301 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 302 | Description: Number of checkpoint operations performed in the background to |
| 303 | free segments. Available when CONFIG_F2FS_STAT_FS=y. |
| 304 | |
| 305 | What: /sys/fs/f2fs/<disk>/gc_foreground_calls |
| 306 | Date: September 2019 |
| 307 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 308 | Description: Number of garbage collection operations performed on demand. |
| 309 | Available when CONFIG_F2FS_STAT_FS=y. |
| 310 | |
| 311 | What: /sys/fs/f2fs/<disk>/gc_background_calls |
| 312 | Date: September 2019 |
| 313 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 314 | Description: Number of garbage collection operations triggered in background. |
| 315 | Available when CONFIG_F2FS_STAT_FS=y. |
| 316 | |
| 317 | What: /sys/fs/f2fs/<disk>/moved_blocks_foreground |
| 318 | Date: September 2019 |
| 319 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 320 | Description: Number of blocks moved by garbage collection in foreground. |
| 321 | Available when CONFIG_F2FS_STAT_FS=y. |
| 322 | |
| 323 | What: /sys/fs/f2fs/<disk>/moved_blocks_background |
| 324 | Date: September 2019 |
| 325 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 326 | Description: Number of blocks moved by garbage collection in background. |
| 327 | Available when CONFIG_F2FS_STAT_FS=y. |
| 328 | |
| 329 | What: /sys/fs/f2fs/<disk>/avg_vblocks |
| 330 | Date: September 2019 |
| 331 | Contact: "Hridya Valsaraju" <hridya@google.com> |
| 332 | Description: Average number of valid blocks. |
| 333 | Available when CONFIG_F2FS_STAT_FS=y. |
Jaegeuk Kim | a7e679b | 2020-02-25 19:08:16 -0800 | [diff] [blame] | 334 | |
| 335 | What: /sys/fs/f2fs/<disk>/mounted_time_sec |
| 336 | Date: February 2020 |
| 337 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 338 | Description: Show the mounted time in secs of this partition. |
Jaegeuk Kim | da9953b | 2020-04-02 09:32:35 -0700 | [diff] [blame] | 339 | |
| 340 | What: /sys/fs/f2fs/<disk>/data_io_flag |
| 341 | Date: April 2020 |
| 342 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 343 | Description: Give a way to attach REQ_META|FUA to data writes |
| 344 | given temperature-based bits. Now the bits indicate: |
Mauro Carvalho Chehab | 54a19b4 | 2020-10-30 08:40:50 +0100 | [diff] [blame] | 345 | |
| 346 | +-------------------+-------------------+ |
| 347 | | REQ_META | REQ_FUA | |
| 348 | +------+------+-----+------+------+-----+ |
| 349 | | 5 | 4 | 3 | 2 | 1 | 0 | |
| 350 | +------+------+-----+------+------+-----+ |
| 351 | | Cold | Warm | Hot | Cold | Warm | Hot | |
| 352 | +------+------+-----+------+------+-----+ |
Daeho Jeong | 2bc4bea | 2020-03-30 03:30:59 +0000 | [diff] [blame] | 353 | |
Jaegeuk Kim | 32b6aba | 2020-06-04 11:49:43 -0700 | [diff] [blame] | 354 | What: /sys/fs/f2fs/<disk>/node_io_flag |
| 355 | Date: June 2020 |
| 356 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 357 | Description: Give a way to attach REQ_META|FUA to node writes |
| 358 | given temperature-based bits. Now the bits indicate: |
Mauro Carvalho Chehab | 54a19b4 | 2020-10-30 08:40:50 +0100 | [diff] [blame] | 359 | |
| 360 | +-------------------+-------------------+ |
| 361 | | REQ_META | REQ_FUA | |
| 362 | +------+------+-----+------+------+-----+ |
| 363 | | 5 | 4 | 3 | 2 | 1 | 0 | |
| 364 | +------+------+-----+------+------+-----+ |
| 365 | | Cold | Warm | Hot | Cold | Warm | Hot | |
| 366 | +------+------+-----+------+------+-----+ |
Jaegeuk Kim | 32b6aba | 2020-06-04 11:49:43 -0700 | [diff] [blame] | 367 | |
Daeho Jeong | 2bc4bea | 2020-03-30 03:30:59 +0000 | [diff] [blame] | 368 | What: /sys/fs/f2fs/<disk>/iostat_period_ms |
| 369 | Date: April 2020 |
| 370 | Contact: "Daeho Jeong" <daehojeong@google.com> |
| 371 | Description: Give a way to change iostat_period time. 3secs by default. |
| 372 | The new iostat trace gives stats gap given the period. |
Jaegeuk Kim | 1020856 | 2020-12-03 09:52:45 -0800 | [diff] [blame] | 373 | What: /sys/fs/f2fs/<disk>/max_io_bytes |
| 374 | Date: December 2020 |
| 375 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 376 | Description: This gives a control to limit the bio size in f2fs. |
| 377 | Default is zero, which will follow underlying block layer limit, |
| 378 | whereas, if it has a certain bytes value, f2fs won't submit a |
| 379 | bio larger than that size. |
Chao Yu | 0bfe9f7 | 2021-01-14 09:41:27 +0800 | [diff] [blame] | 380 | |
| 381 | What: /sys/fs/f2fs/<disk>/stat/sb_status |
| 382 | Date: December 2020 |
| 383 | Contact: "Chao Yu" <yuchao0@huawei.com> |
| 384 | Description: Show status of f2fs superblock in real time. |
| 385 | |
| 386 | ====== ===================== ================================= |
| 387 | value sb status macro description |
| 388 | 0x1 SBI_IS_DIRTY dirty flag for checkpoint |
| 389 | 0x2 SBI_IS_CLOSE specify unmounting |
| 390 | 0x4 SBI_NEED_FSCK need fsck.f2fs to fix |
| 391 | 0x8 SBI_POR_DOING recovery is doing or not |
| 392 | 0x10 SBI_NEED_SB_WRITE need to recover superblock |
| 393 | 0x20 SBI_NEED_CP need to checkpoint |
| 394 | 0x40 SBI_IS_SHUTDOWN shutdown by ioctl |
| 395 | 0x80 SBI_IS_RECOVERED recovered orphan/data |
| 396 | 0x100 SBI_CP_DISABLED CP was disabled last mount |
| 397 | 0x200 SBI_CP_DISABLED_QUICK CP was disabled quickly |
| 398 | 0x400 SBI_QUOTA_NEED_FLUSH need to flush quota info in CP |
| 399 | 0x800 SBI_QUOTA_SKIP_FLUSH skip flushing quota in current CP |
| 400 | 0x1000 SBI_QUOTA_NEED_REPAIR quota file may be corrupted |
| 401 | 0x2000 SBI_IS_RESIZEFS resizefs is in process |
| 402 | ====== ===================== ================================= |
Daeho Jeong | e659206 | 2021-01-21 22:45:29 +0900 | [diff] [blame] | 403 | |
| 404 | What: /sys/fs/f2fs/<disk>/ckpt_thread_ioprio |
| 405 | Date: January 2021 |
| 406 | Contact: "Daeho Jeong" <daehojeong@google.com> |
| 407 | Description: Give a way to change checkpoint merge daemon's io priority. |
| 408 | Its default value is "be,3", which means "BE" I/O class and |
| 409 | I/O priority "3". We can select the class between "rt" and "be", |
| 410 | and set the I/O priority within valid range of it. "," delimiter |
| 411 | is necessary in between I/O class and priority number. |
Jaegeuk Kim | 0823427 | 2021-03-01 17:28:16 -0800 | [diff] [blame] | 412 | |
| 413 | What: /sys/fs/f2fs/<disk>/ovp_segments |
| 414 | Date: March 2021 |
| 415 | Contact: "Jaegeuk Kim" <jaegeuk@kernel.org> |
| 416 | Description: Shows the number of overprovision segments. |
Daeho Jeong | 5ac443e | 2021-03-15 17:12:33 +0900 | [diff] [blame] | 417 | |
| 418 | What: /sys/fs/f2fs/<disk>/compr_written_block |
| 419 | Date: March 2021 |
| 420 | Contact: "Daeho Jeong" <daehojeong@google.com> |
| 421 | Description: Show the block count written after compression since mount. Note |
| 422 | that when the compressed blocks are deleted, this count doesn't |
| 423 | decrease. If you write "0" here, you can initialize |
| 424 | compr_written_block and compr_saved_block to "0". |
| 425 | |
| 426 | What: /sys/fs/f2fs/<disk>/compr_saved_block |
| 427 | Date: March 2021 |
| 428 | Contact: "Daeho Jeong" <daehojeong@google.com> |
| 429 | Description: Show the saved block count with compression since mount. Note |
| 430 | that when the compressed blocks are deleted, this count doesn't |
| 431 | decrease. If you write "0" here, you can initialize |
| 432 | compr_written_block and compr_saved_block to "0". |
| 433 | |
| 434 | What: /sys/fs/f2fs/<disk>/compr_new_inode |
| 435 | Date: March 2021 |
| 436 | Contact: "Daeho Jeong" <daehojeong@google.com> |
| 437 | Description: Show the count of inode newly enabled for compression since mount. |
| 438 | Note that when the compression is disabled for the files, this count |
| 439 | doesn't decrease. If you write "0" here, you can initialize |
| 440 | compr_new_inode to "0". |