The build directories that Netbeans uses are pounded a lot, and chances are you have enough ram to leverage tmpfs. Let do it! Start with our /etc/rc.local file:
echo deadline > /sys/block/sda/queue/scheduler echo 1 > /sys/block/sda/queue/iosched/fifo_batch D=/home/jreynolds/.cache/netbeans rm -rf $D/* mount $D chown -R jreynolds:jreynolds $D D=/home/jreynolds/NetBeansProjects/MyProject/build rm -rf $D/* mount $D # dont furgit the ram directory wants to be regularly deleted by netbeans mkdir $D/ram chown -R jreynolds:jreynolds $D D=/home/jreynolds/build/build-lib/ rm -rf $D/* mount $D mkdir $D/jar mkdir $D/classes chown -R jreynolds:jreynolds $D exit 0
Next we make our /etc/fstab match:
none /var/tmp tmpfs defaults,noatime 0 0 none /tmp tmpfs defaults,noatime 0 0 none /home/jreynolds/.cache/chromium tmpfs noatime,noexec 0 0 none /home/jreynolds/.cache/netbeans tmpfs noauto,noatime 0 0 none /home/jreynolds/NetBeansProjects/MyProject/build tmpfs defaults,noatime,noauto 0 0 none /home/jreynolds/.mozilla/firefox/0m31s0ag.default/Cache tmpfs defaults,noatime,noexec 0 0 none /home/jreynolds/build/myproject-lib tmpfs noauto,noatime 0 0