Skip to main content
Welcome guest. | Register | Login | Post

What are the "defaults" for file system options?

16 replies [Last post]
libervisco's picture
Offline
Joined: 2006-05-04

The 11th point here mentions noatime and nodiratime options as good for performance and power consumption.

So curious I looked into my /etc/fstab to see if those options are enabled and if not to put them in. However, since it says defaults under options I am not sure whether these options do or don't fall under these defaults.

The question then is, what options are the default options? Does this differ from distribution to distribution? If yes, I'm on Ubuntu Feisty.

Thanks

dylunio's picture
Offline
Joined: 2005-12-20
From man mount: Quote:

From man mount:

Quote:

defaults
Use default options: rw, suid, dev, exec, auto, nouser,
and async.

libervisco's picture
Offline
Joined: 2006-05-04
Ah I should have looked

Ah I should have looked there. Sticking out tongue

Then it's safe to just add noatime and nodiratime.

The options are the same regardless of the file system (ext3, reiserfs etc.) right?

Thanks

free-zombie's picture
Offline
Joined: 2006-03-08
Those options increase

Those options increase performance, and can just be added. Be sure to note, however, that some tools might work worse with them; For example, I heard that mutt gets confused by noatime. (I have been using noatime for a while without noticing any problems... but they are not completely safe)

tbuitenh's picture
Offline
Joined: 2005-12-21
Andrew Morton
Andrew Morton wrote:

noatime is a superset of nodiratime, btw.

(seen here)

So if you have noatime, nodiratime is not necessary because it is implied by the first.

I also added data=writeback to my fstab, the "risk" of this is that you may end up with old data in a file in case of an OS crash or power failure. The filesystem won't be corrupted, though. Since I don't run any cron jobs or such that *need* to have their data in the right state, this is good enough for me.

Offline
Joined: 2006-03-28
I just added noatime to my

I just added noatime to my fstab (couple of devices) and also made the decision to implement this in EasyLFS, for 0.4 already. It will be an option, but it'll default to on I think.

libervisco's picture
Offline
Joined: 2006-05-04
free-zombie wrote: Be sure
free-zombie wrote:

Be sure to note, however, that some tools might work worse with them; For example, I heard that mutt gets confused by noatime.

I never use mutt. I suppose problems are very rare (which was also indicated in that article) so it should really be safe.

tbuitenh wrote:

So if you have noatime, nodiratime is not necessary because it is implied by the first.

I see, thanks for pointing that out.

tbuitenh wrote:

I also added data=writeback to my fstab, the "risk" of this is that you may end up with old data in a file in case of an OS crash or power failure.

You mean when you save something to a file and there is a crash, it may actually end up showing the old file (previous to the last save) once rebooted?

If it's something much more subtler than that I can live with it, but for now I think it'd be safest without that option.

reptiler wrote:

I just added noatime to my fstab (couple of devices) and also made the decision to implement this in EasyLFS, for 0.4 already.

That sounds great. Smiling

tbuitenh's picture
Offline
Joined: 2005-12-21
a one in a gazillion chance of almost no damage
libervisco wrote:
tbuitenh wrote:

I also added data=writeback to my fstab, the "risk" of this is that you may end up with old data in a file in case of an OS crash or power failure.

You mean when you save something to a file and there is a crash, it may actually end up showing the old file (previous to the last save) once rebooted?

Only when the crash happened while the OS was still busy writing the file to disk. How often does Linux crash anyway?

libervisco's picture
Offline
Joined: 2006-05-04
Ah I see, then it's quite

Ah I see, then it's quite safe. It never crashes really, and in exceptions to that rule the crash is related to a program which doesn't actually save important files, like games. Sticking out tongue

tbuitenh's picture
Offline
Joined: 2005-12-21
... and you shouldn't be

... and you shouldn't be playing games while editing important files anyway Laughing out loud

free-zombie's picture
Offline
Joined: 2006-03-08
Other options I use:

Other options I use: user_xattr,acl

I think user_xattr is there for Git performance. acl is there because POSIX ACLs are a cool feature Eye

libervisco's picture
Offline
Joined: 2006-05-04
What do those

What do those mean?

Actually, to be honest, I don't exactly know what noatime and data=writeback really mean either. I'm asking on behalf of anyone else reading this who may be wondering too. Eye

libervisco's picture
Offline
Joined: 2006-05-04
Problems! Apparently the

Problems! Apparently the data=writeback thing causes some sort of an error on my ext3 root partition causing it to remount as readonly (as set in options). I removed that option now.

free-zombie's picture
Offline
Joined: 2006-03-08
RTFM (it's man

RTFM ;-) (it's man mount)

noatime: don't store access times on disk (-> a read is a read and leaves the FS as it was)
user_xattr: allow users to use custom POSIX extended file attributes. Git uses this to store metadata in the file system and speed itself up.
acl: Enable the use of POSIX ACLs (access control lists), a way to specify more granula file permissions on UNIX systems

libervisco's picture
Offline
Joined: 2006-05-04
Actually I did read man

Actually I did read man mount exactly because I expected someone to suggest me to read the fine manual. Sticking out tongue It's just that explanations there are quite minimal and susceptible to a bit of guesswork to those without deeper understanding of the context.

For user_xattr / nouser_xattr man says: "Support "user." extended attributes (or not)" Now that makes it so very immediately clear. Yeah right. Laughing out loud

For noatime it says "Do not update inode access times on this file system (e.g, for faster access on the news spool to speed up news servers)." I guess that's a bit better, supposing you have any idea what an "inode" might be. Luckily I have only a vague idea.

Your response, however, was better than that. Smiling

Cheers

tbuitenh's picture
Offline
Joined: 2005-12-21
weird. I have reiserfs (can

weird. I have reiserfs (can you tell I haven't installed the distro du jour for a while?), to be honest I don't know if the option actually does something on that fs...

Offline
Joined: 2006-03-28
I switched to noatime on

I switched to noatime on both machines, my LFS-PC and my Fedora-notebook, both run ext3, both have survived the switch without any problems (so far). And for the notebook I can honestly say that now it's booting considerably faster; my PC already was booting pretty quick before, thanks to LFS (GUI-login after around 40 seconds; last time I stopped, which was still with my old hardware).

Comment viewing options