This shows you the differences between two versions of the page.
| Next revision | Previous revision | ||
| start:noholesbtrfs [2022/06/30 13:25] – created peter | start:noholesbtrfs [2023/09/14 20:48] (current) – peter | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| + | DATE CHECKED THIS PAGE WAS VALID: 14/ | ||
| + | |||
| If you created your BTRFS filesystem a little while ago you might not have no_holes support which is simply an improvement that can be added and reduces the size metadata consumes on the disk. You can check if your filesystem has it in 2 ways: | If you created your BTRFS filesystem a little while ago you might not have no_holes support which is simply an improvement that can be added and reduces the size metadata consumes on the disk. You can check if your filesystem has it in 2 ways: | ||
| Line 11: | Line 13: | ||
| {{: | {{: | ||
| + | As you can note, NO_HOLES is listed under incompat_flags. | ||
| + | |||
| + | Another method is to check via the UUID in this way: | ||
| + | < | ||
| + | ls / | ||
| + | </ | ||
| + | {{: | ||
| + | |||
| + | As we can see no_holes is also listed here. | ||
| + | |||
| + | To add no_holes support the disk must be UNMOUNTED. This might mean you have to boot off a live CD like an ubuntu live ISO from a USB stick. | ||
| + | |||
| + | Once you have unmounted the filesystem you can easily add no_holes support with the -n flag as such: | ||
| + | < | ||
| + | sudo btrfstune -n / | ||
| + | </ | ||
| + | |||
| + | Note, as that disk housed my root partition I had to use a live CD in order to run the command successfully then reboot back into my system afterwards. | ||
| + | |||
| + | This completes how to add the no_hole improvement to a filesystem made prior to v5.15 when it became the default. | ||
| + | |||
| + | |||
| + | |||