ext4 (fourth extended file system) is an open source disk filesystem and most recent version of the extended series of filesystems. It is the primary file system in use by many Linux systems rendering it to be arguably the most stable and well tested file system supported in Linux.
Activate the following kernel options for ext4 support:
File systems ---> <*> The Extended 4 (ext4) filesystem
Support for optional ext4 features:
File systems ---> [*] Ext4 POSIX Access Control Lists [*] Ext4 Security Labels [ ] EXT4 debugging support
|Ext4 POSIX Access Control Lists||Enable ACL permissions.|
|Ext4 Security Labels||Enable POSIX capabilities support.|
|EXT4 debugging support||(Not recommend) Use when debugging ext4 (advanced users only).|
Large drive support
When the system has large disks (2 TB or greater) and a 32-bit (x86) kernel is being used, the following option must be enabled:
-*- Enable the block layer ---> [*] Support for large (2TB+) block devices and files
USE flags for sys-fs/e2fsprogs Standard EXT2/EXT3/EXT4 filesystem utilities
||Build fuse2fs, a FUSE file system client for ext2/ext3/ext4 file systems||local|
After setting the USE flag update the system so the changes take effect:
emerge --ask --changed-use --deep @world
The mkfs.ext4 command irreversibly destroys any content of the partition it is told to format. Be sure to select the right partition!
To create an ext4 filesystem on the /dev/sda1 partition:
Please replace /dev/sda1 with the actual partition to format.
By default, 5% of available disk space is reserved for the root user. This is usually a good thing for the partition where the / directory is mounted, but it may be not desirable on other partitions. To lose reserve disk space for the root user use mkfs.ext4's
-m 0 option:
mkfs.ext4 -m 0 /dev/sda1
- JFS - A GPL licensed, 64-bit journaling filesystem developed by IBM.
- Btrfs - A copy-on-write B-tree filesystem with advanced features (an entirely open source licensed ZFS alternative).
- XFS - A GPL licensed, 64-bit journaling filesystem created by Silicon Graphics.
- F2FS - A Flash-Friendly File System created by Samsung for the Linux kernel.
- http://ext4.wiki.kernel.org - The second, third, and fourth extended file system wiki.