Optimize your apache and myql

To optimize your apache and mysql we recommend editing the config files as show below:

mysql file located at /etc/my.cnf:

[mysqld]
max_connections = 400
key_buffer = 16M
myisam_sort_buffer_size = 32M
join_buffer_size = 1M
read_buffer_size = 1M
sort_buffer_size = 2M
table_cache = 1024
thread_cache_size = 286
interactive_timeout = 25
wait_timeout = 1000
connect_timeout = 10
max_allowed_packet = 16M
max_connect_errors = 10
query_cache_limit = 1M
query_cache_size = 16M
query_cache_type = 1
tmp_table_size = 16M
skip-innodb

[mysqld_safe]
open_files_limit = 8192

[mysqldump]
quick
max_allowed_packet = 16M

[myisamchk]
key_buffer = 32M
sort_buffer = 32M
read_buffer = 16M
write_buffer = 16M


apache config file located at /usr/local/apache/conf/httpd.conf:

Timeout 30
KeepAlive On
MaxKeepAliveRequests 120
KeepAliveTimeout 3
MinSpareServers 1
MaxSpareServers 5
StartServers 1
MaxClients 250
MaxRequestsPerChild 0
  • 1 Users Found This Useful
Was this answer helpful?

Related Articles

4gb seg fixup error messages in console

If you are getting 4gb seg fixup error message in console. Please do the following: Move the...

Invalid license message when accessing cpanel/whm.

If you are loading WHM or C-Panel and it displays an invalid license message, log into ssh and do...

How to install Zend

To install Zend, log in as root and run If using cpanel: wget...

Why do my accounts in whm show 0mb used?

This is currently a bug in cpanel/whm Please run the following in root: /scripts/fixquotas...

Squirrelmail could not find ../config/config.php

If your using squirrel mail and it gives the the following message: An error message saying it...