Featured Posts

Tips to Reduce Your Customer Support Costs When hosting websites, whether as a mainstream hosting provider, a hobby, or to supplement another service, it's your job to make sure your customers have access to technical support in case they need...

Read more

Roundcube: MySQL or SQLite? cPanel 11.25 introduces a new feature: The ability to have RoundCube use SQLite instead of MySQL. After benchmarking resource usage and performance, I've come to the conclusion that SQLite is definitely...

Read more

Simple Bash Script to Fix Account Permissions This is a simple bash script I wrote to fix the permissions and ownership of files within a cpanel account. To use, simply copy the script your server, chmod 755, and pass the usernames as arguments: ./fixperms...

Read more

Re-Installing Auxiliary cPanel Software Cpanel has a lot of supporting software that you may be using on your server. In case something goes amiss, here is a list of scripts that reinstall cpanel-provided software on your system. For most all...

Read more

10 Free Monitoring Solutions to Consider Server and network monitoring can be crucial to a host's success. I mean, how embarrassing is it when your customers are aware of downtime before you are? You don't have to pay big bucks or spend loads...

Read more

The cPanel Admin Rss

Performance Tip: Disable Optimizefs

Posted by Vanessa | Posted in Misc | Posted on June 22, 2010

1

CPanel utilizes a script called “optimizefs” that removes the atime attribute from certain files on the system. For larger servers, this can create a lot of i/o load for a problem that can be fixed simply by mounting your file systems with the noatime flag if your file system is ext2 or higher.

The atime attribute is used by Linux to mark when a file was last accessed, and is understood to be a resource drain when enabled for an entire filesystem.  cPanel attempts to address this by removing atime attributes from a specific list of files.  You may see a command like this in your root crontab:

45 */8 * * * /usr/bin/test -x /usr/local/cpanel/bin/optimizefs && /usr/local/cpanel/bin/optimizefs

This cron basically applies the following command to a number of files and directories:

chattr +A /path/to/file/or/directory

Instead of using cPanel’s band-aid fix, it’s preferred to remove the atime attribute from the filesystem altogether. To do this, add noatime to the file system properties for each usable partition listed in /etc/fstab. For example:

LABEL=/ /  ext3    defaults,usrquota,noatime 0 0
/tmp /var/tmp ext3    defaults,usrquota,bind,noauto,noatime 0 0

Then remount each file system. For the example above using the root partition ( / ):

mount -o remount /

*In some cases, a reboot may be necessary

Now, you can remove the cron job and still get the same benefits of not having your operating system record file access times:

sed ‘/optimizefs/d’ -i /var/spool/cron/root && service crond reload

Additional Resources:

http://www.faqs.org/docs/securing/chap6sec73.html

10 Free Monitoring Solutions to Consider

Posted by Vanessa | Posted in Misc | Posted on January 17, 2010

1

Server and network monitoring can be crucial to a host’s success. I mean, how embarrassing is it when your customers are aware of downtime before you are? You don’t have to pay big bucks or spend loads of time setting up monitoring for your server. We’ve compiled a list of free monitoring solutions you can use to guarantee minimal downtime for your users, and show customers how reliable your service is!