Maybe this blog will help.

http://www.mysqlperformanceblog.com/2006/11/12/are-php-persistent-connections-evil/

<http://www.mysqlperformanceblog.com/2006/11/12/are-php-persistent-connections-evil/>
Cheers,

Jimmy

On Sat, Jul 17, 2010 at 1:39 PM, Anuerin Diaz <[email protected]> wrote:

>
>
> On Fri, Jul 16, 2010 at 1:14 AM, Allen Umlas <[email protected]>wrote:
>
>> Hi Guys,
>>
>>          I have some sort of problem with mysql server, time_wait
>> connections is reach too much high. It might be some application not closing
>> in certain time probably might be a reason.So i did set max_connections to
>> 500 but still it reach. How can i made a bash or any script that will send
>> me an email if that time_wait connection reaches certain define number that
>> i might be aware.I usually use this command to monitor time_wait and counts
>> for particular connection.
>>
>> netstat -ant |grep ":3306" |awk '/tcp/ && /TIME_WAIT/ {print
>> $6,$4}'|sort|uniq -c
>>
>>
>>
> i dont see any reason stopping you from putting that command in a script
> file, capture the output to a variable, check if the count is greater than X
> times and if so send a simple mail to you (via the mail/mailx command).
>
> http://tldp.org/LDP/abs/html/
>
> that however is a reactive stance. the mysql gurus would probably have some
> tips to avoid it having to reach that state (like shortening the idle
> timeout except if your application is doing connection pooling).
>
> ciao!
>
>
> --
> "Programming, an artform that fights back"
>
> Anuerin G. Diaz
> Registered Linux User #246176
> Friendly Linux Board @ http://mandrivausers.org/index.php
> http://ramfree17.net/capsule , when you absolutely have nothing else
> better to do
>
> _________________________________________________
> Philippine Linux Users' Group (PLUG) Mailing List
> http://lists.linux.org.ph/mailman/listinfo/plug
> Searchable Archives: http://archives.free.net.ph
>
_________________________________________________
Philippine Linux Users' Group (PLUG) Mailing List
http://lists.linux.org.ph/mailman/listinfo/plug
Searchable Archives: http://archives.free.net.ph

Reply via email to