Sign up for PayPal and start accepting credit card payments instantly.

Thursday, June 2, 2011

Swap memory from hard disk to RAM
One bottleneck of Linux the use of swap file on the hard disk instead of RAM. Since the hard disk is 100 times slower than internal memory, this can slow things down considerably.
Swap file is controlled by a variable called “swappiness” and higher the number, greater the tendency to go to the disk.
  • Find out the system swappiness by using the command below. Go to Applications > Accessories > Terminal to execute the command.
         sudo cat /proc/sys/vm/swappiness

       
         
  • Lower that to 10 by typing this in the terminal window. $ sudo sysctl -w vm.swappiness=10
        
  • To make sure the system always uses a swappiness of 10 on every boot, we’ll need to edit the sysctl.conf file in the etc directory. Type this in the terminal

    $ sudo gedit /etc/sysctl.conf
         
  • In the popup window, search for text "vm.swappiness" and edit 60 to 10. Save and close the file.
          

No comments:

Post a Comment