Reduce Disk Writes With noatime, nodiratime and relatime in Linux

noatime, nodiratime and relatime are disk mount options to disable access time information updates onto every file or directory the system access. By using these options, disk writing activity can be reduce significantly. This is useful for Solid State Drive (SSD) or to encourage Hard Disk Drive (HDD) to spin down and save power.
  • noatime - Disable access time update of files in HDD.
  • nodiratime - Disable access time update of directories in HDD
  • relatime - Update access time relative to modify or change time. Access time is only updated if the previous access time was earlier than the current modify or change time.
Example:
Open /etc/fstab for edit.
sudo gedit /etc/fstab
Append the options to one of the mounted drives.
# <file system> <mount point> <type> <options> <dump> <pass>
/dev/sda / ext4 errors=remount-ro,noatime,nodiratime 0 0


Comments

  1. Why set nodiratime when its implied within the noatime setting?

    ReplyDelete
  2. Hi, i am not sure if nodiratime is implied in noatime. Could you point me to a resource that says that?

    Thanks.

    ReplyDelete
  3. "Does noatime imply nodiratime?" - http://lwn.net/Articles/245002/

    ReplyDelete

Post a Comment

Popular posts from this blog

City Code Table for Casio SGW300HD-1AV Watch

How to force only 4G or LTE network connection for Samsung Galaxy Note 4

Mounting NFS share directory from D-link DNS 320L on Ubuntu 12.04 LTS