You are not logged in.

#1 2023-11-19 12:39:33

ke
Member
Registered: 2023-11-13
Posts: 12

[SOLVED] Filesystems

Hello fellow Arch GNU/Linux users! I like tinkering with low level stuff such as filesystems etc. This might sound insane, but do any of you use an ext2 or ext3 formatted root partition on your main pc (ext4 I assume being the standard for pc:s among the ext* filesystems)? Is it feasible and if so, what issues do you have?

Last edited by ke (2023-11-23 17:29:24)

Offline

#2 2023-11-19 12:56:31

seth
Member
Registered: 2012-09-03
Posts: 59,718

Offline

#3 2023-11-19 13:06:57

mpan
Member
Registered: 2012-08-01
Posts: 1,343
Website

Re: [SOLVED] Filesystems

ke: filesystems, which were formatted in times of ext2 and ext3, are handled by the ext4 module. I am not sure, if all of the characteristics of ext2/ext3 may be set with mkfs.ext4. But, if your concern were differences by how kernel handles them, there is none. And both mkfs.ext2 and mkfs.ext3 are also exactly the same binary as mkfs.ext4:

$ sha1sum /usr/bin/mkfs.ext{2,3,4}
e54f7977e643ea2396bf2770b037dadb47adb936  /usr/bin/mkfs.ext2
e54f7977e643ea2396bf2770b037dadb47adb936  /usr/bin/mkfs.ext3
e54f7977e643ea2396bf2770b037dadb47adb936  /usr/bin/mkfs.ext4

So only options differ, depending on which name is used for invocation.

Encrypted swap with UUID/LABEL uses mkfs.ext2, as it does not really need the filesystem, but a stub with LABEL/UUID.

Last edited by mpan (2023-11-19 13:10:18)


Sometimes I seem a bit harsh — don’t get offended too easily!

Offline

#4 2023-11-19 13:14:30

Scimmia
Fellow
Registered: 2012-09-01
Posts: 12,169

Re: [SOLVED] Filesystems

MANY of us were using ext2 before ext3 came out, and ext3 before ext4 came out. What are you concerns, specifically? The features added in each generation are good, but volume and file size are probably the only things that could be considered critical to making things work.

Online

#5 2023-11-20 13:44:18

ke
Member
Registered: 2023-11-13
Posts: 12

Re: [SOLVED] Filesystems

Ok! Thanks for the answers. I see using ext2/3 over ext4 mostly has disadvantages for desktop /. I might disable my journal on my ext4 / as the wiki describes for improved performance (knowing the risks).

Offline

#6 2023-11-20 13:53:16

graysky
Wiki Maintainer
From: :wq
Registered: 2008-12-01
Posts: 10,645
Website

Re: [SOLVED] Filesystems

On a modern system/SSD it's probably not noticeable.  I'd keep it.


CPU-optimized Linux-ck packages @ Repo-ck  • AUR packagesZsh and other configs

Offline

#7 2023-11-20 16:53:06

ke
Member
Registered: 2023-11-13
Posts: 12

Re: [SOLVED] Filesystems

Ok, with an nvme I guess it is not worth the risks and better just stick with vanilla ext4 then.

Offline

#8 2023-11-21 06:07:10

mpan
Member
Registered: 2012-08-01
Posts: 1,343
Website

Re: [SOLVED] Filesystems

Neither file contents nor journal go directly to persistent storage. There is still cached in RAM. By default it is at least 5 seconds: see the `commit` entry in ext4 documentation. So, unless your run out of cache space due to heavy I/O, your performance shouldn’t be severely affected even on spinning rust. That starts to matter, if you quickly transfer gigabytes of data or run a database doing a ton of small writes interleaved with explicit flushing.


Sometimes I seem a bit harsh — don’t get offended too easily!

Offline

#9 2023-11-21 09:21:10

ke
Member
Registered: 2023-11-13
Posts: 12

Re: [SOLVED] Filesystems

In that case to make things even less problematic, one should make sure to enable a good amount of swap to improve cache hit rate. See https://chrisdown.name/2018/01/02/in-de … -swap.html.

Offline

Board footer

Powered by FluxBB