Quantcast
Channel: Beginner Linux Tutorial » Speed Tweaks
Viewing all articles
Browse latest Browse all 4

Speed Up Disk Reads and Writes

$
0
0

Linux Speed TweakThere are many speed tweaks you can do in the Linux operating system to make your Linux computer perform faster. Some of these speed tweaks are as easy as editing a configuration file. In this guide we are going to disable the atime attribute. This will increase your disk performance in Linux.

What is atime Attribute

In Linux your file system will record the time and date a file was created, modified, and last accessed for every file on your Linux computer. Every time you access a file it writes to your disk letting the Linux file system know when it was last accessed. If you edit the file it will keep track of the last time you modified the file. Back to the last access time, just imaging how many files are opened on your computer just at boot time. There are files being accessed that you may not be directly opening, such as libs, configuration files, services, etc. Now your Linux computer will write to the disk for each of those files when they were last accessed. So you could imagine how much processor and disk resources are being used to write all this information.

Do I Need atime Attribute

You do not need atime attribute to run Linux. Nothing is going to fail, crash, or die if you disable the atime attribute. There are no programs that depend on the atime attribute. You may want to use atime attribute yourself if you want to be able to look up a file that you just looked at and don’t remember what it was or maybe even some other reason. For probably 98% of Linux users out there, you can disable atime attribute without any problems.

What File Systems Does this Speed Tweak Work on

I’m not 100% sure on this, but I think that this speed tweak only works on ext2, ext3, and ext4 file systems.  If I am wrong, someone please correct me. I rarely use any other file system besides ext type file systems on my Linux computers.

How to Increase Linux System Performance

You can disable the atime attribute. To disable the atime attribute you need to be root or super user (su|sudo). You need to edit /etc/fstab with your favorite text editor. You can use gedit, vi, nano or which ever text editor you prefer to use. In your /etc/fstab file you want to change the options for your mounts. So in your /etc/fstab file you should see a few lines like this:


/dev/sda1 /boot ext3 noauto,noatime 1 2
/dev/sda2 / ext4 noatime 0 1
/dev/sda3 none swap sw 0 0
/dev/md0 /home ext4 noatime 1 2
proc /proc proc defaults 0 0
shm /dev/shm tmpfs nodev,nosuid,noexec 0 0

As you can see in my /etc/fstab I replaced the defaults option with noatime for my /, /boot, and /home partitions. With this option in your /etc/fstab after the partition is mounted again with the noatime attribute you should notice a difference in your Linux computer’s performance. Mainly in disk usage but some processor resources as well.

This Linux speed tweak is very easy to do as you can see. Just remember to apply this Linux speed tweak to all of your Linux laptops and Linux desktops! Continue reading about more Linux speed tweaks to get the most out of your Linux computer.


Viewing all articles
Browse latest Browse all 4

Latest Images

Trending Articles





Latest Images