Differences
This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision Next revisionBoth sides next revision | ||
| docs:user-guide:filesystems-and-partitions [2017/10/30 20:40] – editing the page to better fit its new role of informative article bobafetthotmail | docs:guide-user:storage:filesystems-and-partitions [2024/09/04 08:37] – [btrfs] artoria2e5 | ||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Filesystems ====== | ====== Filesystems ====== | ||
| - | This page contains | + | This page contains |
| - | A filesystem | + | OpenWrt |
| - | Windows, macOS/OSX and LEDE (Linux) use different default filesystems, | + | |
| - | LEDE is a Linux-based system, so it can read and write data written in Windows and macOS filesystems, | + | |
| - | In case you wonder, the reason for this lack of performance/ | + | |
| - | ===== Currently supported | + | Installing these additional |
| - | To see what filesystems can be read by the firmware currently installed, write '' | + | |
| - | This is an example output from a LEDE x86 Virtual Machine, it can read many filesystems as space is not an issue for this target. | + | |
| - | For most devices, you will have to choose what filesystems you need to be able to access, | + | |
| - | < | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | nodev bpf | + | |
| - | nodev | + | |
| - | nodev | + | |
| - | ext3 | + | |
| - | ext2 | + | |
| - | ext4 | + | |
| - | squashfs | + | |
| - | nodev | + | |
| - | btrfs | + | |
| - | f2fs | + | |
| - | xfs | + | |
| - | vfat</ | + | |
| - | ===== LEDE/Linux filesystems ===== | + | ==== Check available filesystems ==== |
| - | There are 2 main filesystems | + | To see what filesystems can be read currently, enter '' |
| - | In short:\\ | + | |
| - | * ext4 is best suited for hard drives | + | A full list of filesystems available in OpenWrt can be obtained by writing\\ |
| - | * f2fs is best suited for flash drives | + | '' |
| + | |||
| + | The tools for the filesystem of your choosing can be found by writing\\ | ||
| + | '' | ||
| + | |||
| + | OpenWrt has drivers and filesystem tools available for ext2/3/4, f2fs, btrfs, and many other filesystems supported by Linux. | ||
| + | |||
| + | ===== OpenWrt/Linux filesystems ===== | ||
| + | The two most common Linux filesystems are [[wp> | ||
| + | |||
| + | * ext4 is well suited for HDDs and SSDs (using TRIM) and is the default filesystem of most desktop Linux distributions. | ||
| + | * f2fs is well suited for flash (SSDs or USB thumbdrives). The format can be incompatible between kernel versions, requiring some time for " | ||
| + | * btrfs is the default filesystem for more cutting-edge Linux distributions. It is considered the sucessor to ext4, with the author stating "there will be no ext5". It has some more advanced features such as checksumming. | ||
| + | |||
| + | ==== ext4 ==== | ||
| - | ==== Setup ext4 ==== | ||
| This command will download the tools needed to create and fix ext4 (and older versions)\\ | This command will download the tools needed to create and fix ext4 (and older versions)\\ | ||
| '' | '' | ||
| Line 46: | Line 32: | ||
| '' | '' | ||
| - | ==== Setup f2fs ==== | + | ==== f2fs ==== |
| This command will download the tools needed to create and fix f2fs\\ | This command will download the tools needed to create and fix f2fs\\ | ||
| '' | '' | ||
| Line 53: | Line 39: | ||
| '' | '' | ||
| - | ===== Other filesystems (for advanced users) ===== | + | ==== btrfs ==== |
| - | a full list of filesystems available in LEDE can be obtained by writing\\ | + | This command will download the tools needed to create and fix btrfs\\ |
| - | '' | + | '' |
| - | the tools for the filesystem | + | If in the list of supported filesystems in your device you don't see btrfs, you must install also the driver itself\\ |
| - | '' | + | '' |
| + | |||
| + | ===== Windows filesystems ===== | ||
| + | |||
| + | The two most common filesystems used by Windows are [[wp> | ||
| + | |||
| + | ==== NTFS ==== | ||
| + | |||
| + | NTFS is the primary Windows filesystem and is available via the '' | ||
| + | |||
| + | Download and install via the NTFS-3G driver\\ | ||
| + | '' | ||
| + | |||
| + | This command will download | ||
| + | '' | ||
| + | |||
| + | See [[docs: | ||
| + | |||
| + | ===== Apple filesystems ===== | ||
| + | In Apple land you have [[wp> | ||
| + | |||
| + | ==== HFS and HFS+ ==== | ||
| + | This command will download | ||
| + | '' | ||
| + | |||
| + | If in the list of supported filesystems in your device you don't see **hfs** and **hfsplus**, | ||
| + | '' | ||
| - | As of this writing (2017) LEDE has drivers and filesystem tools for ext2/3/4, f2fs, xfs and btrfs, and drivers for most other filesystems supported by Linux. | ||
| ===== Multiplatform filesystems ===== | ===== Multiplatform filesystems ===== | ||
| - | The only filesystem that is recommended for drives you will use for multiplatform usage is [[wp> | ||
| - | Its main drawback (for a data drive) is that it cannot store a file bigger than 3.9 GiB even if the drive itself is bigger than that. | ||
| - | It is also prone to corruption if the device is disconnected while still writing, which can lead to data loss if the device is written again without running a filesystem check. | ||
| - | ==== Setup FAT32 ==== | + | ==== FAT32 ==== |
| - | this command will download the tools needed to create and fix FAT32 (and older versions)\\ | + | [[wp> |
| - | '' | + | |
| + | This command will download the tools needed to create and fix FAT32 (and older versions)\\ | ||
| + | '' | ||
| If in the list of supported filesystems in your device you don't see **vfat**, you must install also the driver itself\\ | If in the list of supported filesystems in your device you don't see **vfat**, you must install also the driver itself\\ | ||
| '' | '' | ||
| - | ==== Available NLS files ==== | + | === Available NLS files === |
| - | For some filesystems, | + | Some filesystems, |
| '' | '' | ||
| means that you need NLS codepage 437, and a message like\\ | means that you need NLS codepage 437, and a message like\\ | ||
| Line 82: | Line 92: | ||
| means that you need NLS ISO 8859-1. | means that you need NLS ISO 8859-1. | ||
| - | Available NLS files and their packages can be listed by writing '' | + | Available NLS packages can be listed by writing '' |
| ^ Name ^ Description | ^ Name ^ Description | ||
| Line 90: | Line 100: | ||
| | kmod-nls-cp775 | | kmod-nls-cp775 | ||
| | kmod-nls-cp850 | | kmod-nls-cp850 | ||
| - | | kmod-nls-cp852 | ||
| | kmod-nls-cp866 | | kmod-nls-cp866 | ||
| | kmod-nls-iso8859-1 | | kmod-nls-iso8859-1 | ||
| - | | kmod-nls-iso8859-13 | Kernel module for NLS ISO 8859-13 (Latin 7; Baltic) | ||
| - | | kmod-nls-iso8859-15 | Kernel module for NLS ISO 8859-15 (Latin 9) | | ||
| - | | kmod-nls-iso8859-2 | ||
| | kmod-nls-koi8r | | kmod-nls-koi8r | ||
| | kmod-nls-utf8 | | kmod-nls-utf8 | ||
| - | ===== Windows filesystems | + | ==== exFAT ==== |
| - | The only filesystem used on Windows PC is [[wp> | + | |
| - | Another filesystem that is used on newer SD cards bigger than 32 GiB is [[wp> | + | |
| - | ==== Setup NTFS ==== | + | exFAT is commonly used by OEMs for external SSDs and SD cards. The downside |
| - | This command will download the tools needed | + | |
| - | '' | + | |
| - | + | ||
| - | If in the list of supported filesystems in your device you don't see **ntfs**, you must install also the driver itself\\ | + | |
| - | '' | + | |
| - | + | ||
| - | ==== Setup exFAT ==== | + | |
| - | This command | + | |
| - | '' | + | |
| - | + | ||
| - | '' | + | |
| - | ===== Apple filesystems ===== | + | As of Linux kernel 5.4 there is a [[https:// |
| - | In Apple land you have [[wp>HFS]], [[wp> | + | |
| - | APFS is too new (as of 2017) and there is no support at all for it in LEDE (nor in Linux) | + | |
| - | + | ||
| - | ==== Setup HFS and HFS+ ==== | + | |
| - | This command | + | |
| - | '' | + | |
| - | + | ||
| - | If in the list of supported filesystems in your device you don't see **hfs** and **hfsplus**, you must install also the drivers\\ | + | |
| - | '' | + | |
| + | This will install the driver to use exFAT and the tool to be able to run check disk if needed:\\ | ||
| + | '' | ||
| + | Under Windows, exFAT does not support TRIM; but under Linux/ | ||
| - | ======Partitions ===== | + | ===== Partitions ===== |
| - | A partition is a way to split the storage space in more different sections, each using its own independent filesystem. | + | A [[wp> |
| - | This can be useful to separate different types of data, like for example to keep your expanded firmware | + | This can be useful to separate different types of data, for example to keep your expanded firmware |
| - | Discussing advanced partitioning is beyond the scope of this article, as LEDE uses the same commandline tools used by any other Linux system. | + | Discussing advanced partitioning is beyond the scope of this article, as OpenWrt |
| **fdisk** tool is used to create/ | **fdisk** tool is used to create/ | ||
| **gdisk** tool is used to create/ | **gdisk** tool is used to create/ | ||