Solved

set new default value for max_heap_table_size

Posted on 2012-04-08
7
846 Views
Last Modified: 2012-04-09
hello experts,
i want to set new value to the max_heap_table_size variable.
i know how to do this, and i know how to set the global variable, but how can i set the default value.
so when the server start-up i want that the new value take place instead of the default value.

so assuming that mysql default value is 16M i want to change it to 32M..

how do i do it?? how do i change the DEFAULT value, not session or global, DEFAULT.
is there a file that i should edit?

thanks ahead :)
0
Comment
Question by:Puzatiy
  • 3
  • 2
  • 2
7 Comments
 
LVL 17

Expert Comment

by:Anuroopsundd
ID: 37821591
to view max_heap_table_size
select @@max_heap_table_size;

And then you can run a query to set it higher:

set @@max_heap_table_size=NUMBER_OF_BYTES
0
 
LVL 17

Expert Comment

by:Anuroopsundd
ID: 37821600
Modify the contents of the /etc/my.cnf file under the [mysqld] section.

max_heap_table_size=524288000


http://web3us.com/drupal6/how-create-web-site-handbook/how-setup-mysql/tuning-mysql
0
 
LVL 3

Author Comment

by:Puzatiy
ID: 37821826
but im running the server in wamp server for windows...
so is there any file that simular to the my.cnf file.. thanks ahead
0
PRTG Network Monitor: Intuitive Network Monitoring

Network Monitoring is essential to ensure that computer systems and network devices are running. Use PRTG to monitor LANs, servers, websites, applications and devices, bandwidth, virtual environments, remote systems, IoT, and many more. PRTG is easy to set up & use.

 
LVL 24

Expert Comment

by:johanntagle
ID: 37822009
I don't know where it is actually located as I don't use windows but look for a my.ini file
0
 
LVL 3

Author Comment

by:Puzatiy
ID: 37823359
yes i know where this file is, however i have no idea what i should edit there.
i know there is a lot of variables there but no max_heap_table_size..
0
 
LVL 24

Accepted Solution

by:
johanntagle earned 500 total points
ID: 37825402
As anuroopsundd said, just add the line under the [mysqld] section.
0
 
LVL 24

Expert Comment

by:johanntagle
ID: 37826019
Thanks but you should have given most of the points to anuroopsundd
0

Featured Post

Free learning courses: Active Directory Deep Dive

Get a firm grasp on your IT environment when you learn Active Directory best practices with Veeam! Watch all, or choose any amount, of this three-part webinar series to improve your skills. From the basics to virtualization and backup, we got you covered.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

When we want to run, execute or repeat a statement multiple times, a loop is necessary. This article covers the two types of loops in Python: the while loop and the for loop.
This article discusses four methods for overlaying images in a container on a web page
The viewer will learn how to clear a vector as well as how to detect empty vectors in C++.
The viewer will be introduced to the technique of using vectors in C++. The video will cover how to define a vector, store values in the vector and retrieve data from the values stored in the vector.

809 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question