slowpc

apt-get install cpufrequtils preload

in /etc/sysctl.conf

vm.swappiness=10
vm.vfs_cache_pressure=100
vm.dirty_expire_centisecs = 1000
vm.dirty_writeback_centisecs = 500
vm.dirty_background_ratio = 5
vm.dirty_ratio = 10
vm.overcommit_ratio=99
vm.overcommit_memory=2

in rc.local

By default this script does nothing.

echo noop > /sys/block/$DEVICE/queue/scheduler
echo 2 > /sys/block/sda/queue/rq_affinity
echo 0 > /sys/block/sda/queue/add_random
for each in 0 1; do echo performance > /sys/devices/system/cpu/cpu$each/cpufreq/scaling_governor; done

exit 0