What is the best mysql configuration of My.cnf?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rahulephp
    New Member
    • Sep 2009
    • 59

    #1

    What is the best mysql configuration of My.cnf?

    Hi all,

    First of all I am new with server using.
    Below my virtual private server details:

    • Processor : 2.8 GHz Dual Core
    • Processor Cores: 2
    • RAM Memory : 4GB
    • Apache Version: Apache/2.2.3 (CentOS)
    • PHP Version 5.1.6
    • MySQL Version: 5.0.77
    • HDD: 100GB
    • Bandwidth: Unlimited



    Due to 3GB of database size, server may not respond some times and working very slow even if good server configuration.
    Website is running good on our local computers.
    I think, I need to change the mysql configuration settings for online server.


    Please help me out to set the best configuration of my.cnf for above server specially following settings:
    (Table type is MyISAM)
    • connect_timeout = 20
    • key_buffer_size = 64M
    • max_allowed_pac ket = 2G
    • table_cache = 100M
    • wait_timeout= 360
    • interactive_tim eout = 360
    • key_buffer = 16M
    • sort_buffer_siz e = 512K
    • net_buffer_leng th = 8K
    • read_buffer_siz e = 256K
    • read_rnd_buffer _size = 512K
    • myisam_sort_buf fer_size = 8M


    Thanks in advance
  • mwasif
    Recognized Expert Contributor
    • Jul 2006
    • 802

    #2
    What is the size of your database indexes? You are running multiple services on this server. How much RAM you can give to MySQL?

    Comment

    Working...