|
Home > Archive > MySQL ODBC Connector > January 2006 > max_connections
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Asad Habib 2006-01-26, 4:56 pm |
| Are there any statistics that I can use to determine how high or low I
should set max_connections? I am using MySQL as the backend for a Java web
application that will need to accommodate a moderate amount of traffic.
Also, if max_connections is set too high relative to the needs of the
application, does this waste system resources? In other words, does MySQL
reserve system resources based on the value of max_connections or does it
dynamically reserve/release system resources based on what the
application's current needs are? The application itself uses a connection
pool and hence idle connections are recycled and reused. Any help would be
appreciated. Thanks.
- Asad
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw
| |
| Kishore Jalleda 2006-01-26, 4:56 pm |
| as somebody in the list already pointed out it all depends on the
amount of RAM you have , the formula has been taken from Jeremy's book
, high performance Mysql
Expressed mathematically, that is:
min_memory_needed =3D global_buffers + (thread_buffers * max_connections)
where thread_buffers includes the following:
sort_buffer
myisam_sort_buffer
read_buffer
join_buffer
read_rnd_buffer
and global_buffers includes:
key_buffer
innodb_buffer_pool
innodb_log_buffer
innodb_additional_me
m_pool
net_buffer
and as far as I know mysql does not reserve system resources based on
max_connections, it will use/release RAM based on the current
connections ....
Kishore Jalleda
On 1/25/06, Asad Habib <ahabib@engin.umich.edu> wrote:
> Are there any statistics that I can use to determine how high or low I
> should set max_connections? I am using MySQL as the backend for a Java we=
b
> application that will need to accommodate a moderate amount of traffic.
> Also, if max_connections is set too high relative to the needs of the
> application, does this waste system resources? In other words, does MySQL
> reserve system resources based on the value of max_connections or does it
> dynamically reserve/release system resources based on what the
> application's current needs are? The application itself uses a connection
> pool and hence idle connections are recycled and reused. Any help would b=
e
> appreciated. Thanks.
>
> - Asad
>
> --
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe: http://lists.mysql.com/mysql? unsub...ma
il.co=
m
>
>
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql? unsub...sie.nctu.edu.tw
|
|
|
|
|