I have a rails app running Thin. During peak hours holds up pretty well... but i've noticed child processes or connections persist and slow the application to almost a crawl. Since we launch, I've had to restart the application servers frequently. Can someone explain to me what's happening. I'm putting God in place to monitor this now and I'm using the following to verify currently:
On Wed, Aug 22, 2012 at 12:02 PM, de <jimmie4848john...@gmail.com> wrote:
> I have a rails app running Thin. During peak hours holds up pretty well...
> but i've noticed child processes or connections persist and slow the
> application to almost a crawl. Since we launch, I've had to restart the
> application servers frequently. Can someone explain to me what's happening.
> I'm putting God in place to monitor this now and I'm using the following to
> verify currently:
> Bash$ netstat -nap | grep 3000 | wc -l
> --
> You received this message because you are subscribed to the Google Groups
> "thin-ruby" group.
> To view this discussion on the web visit
> https://groups.google.com/d/msg/thin-ruby/-/wpNCjIN3M_UJ.
> To post to this group, send email to thin-ruby@googlegroups.com.
> To unsubscribe from this group, send email to
> thin-ruby+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/thin-ruby?hl=en.
Timeout is set to 30seconds, but just noticed now max_persistant_connections is set to 512 which is almost precisely where the app dies. I'm assuming I should lower this. Just soaking up way to much memory. Here's my config.
On Wednesday, August 22, 2012 12:05:50 PM UTC-4, macournoyer wrote:
> Did you set the timeout option to 0 or something? You can also limite the > number of persistent connections with --max-persistent-conns option.
> On Wed, Aug 22, 2012 at 12:02 PM, de <jimmie48...@gmail.com <javascript:>>wrote:
>> I have a rails app running Thin. During peak hours holds up pretty >> well... but i've noticed child processes or connections persist and slow >> the application to almost a crawl. Since we launch, I've had to restart the >> application servers frequently. Can someone explain to me what's happening. >> I'm putting God in place to monitor this now and I'm using the following to >> verify currently:
>> Bash$ netstat -nap | grep 3000 | wc -l
>> -- >> You received this message because you are subscribed to the Google Groups >> "thin-ruby" group. >> To view this discussion on the web visit >> https://groups.google.com/d/msg/thin-ruby/-/wpNCjIN3M_UJ. >> To post to this group, send email to thin...@googlegroups.com<javascript:> >> . >> To unsubscribe from this group, send email to >> thin-ruby+...@googlegroups.com <javascript:>. >> For more options, visit this group at >> http://groups.google.com/group/thin-ruby?hl=en.
If the connections are not being closed is because there is some activity
on the socket. Are you doing anything special, like real-time updates
inside Rails?
On Wed, Aug 22, 2012 at 12:10 PM, de <jimmie4848john...@gmail.com> wrote:
> Timeout is set to 30seconds, but just noticed now
> max_persistant_connections is set to 512 which is almost precisely where
> the app dies. I'm assuming I should lower this. Just soaking up way to much
> memory. Here's my config.
> On Wednesday, August 22, 2012 12:05:50 PM UTC-4, macournoyer wrote:
>> Did you set the timeout option to 0 or something? You can also limite the
>> number of persistent connections with --max-persistent-conns option.
>> On Wed, Aug 22, 2012 at 12:02 PM, de <jimmie48...@gmail.com> wrote:
>>> I have a rails app running Thin. During peak hours holds up pretty
>>> well... but i've noticed child processes or connections persist and slow
>>> the application to almost a crawl. Since we launch, I've had to restart the
>>> application servers frequently. Can someone explain to me what's happening.
>>> I'm putting God in place to monitor this now and I'm using the following to
>>> verify currently:
>>> Bash$ netstat -nap | grep 3000 | wc -l
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "thin-ruby" group.
>>> To view this discussion on the web visit https://groups.google.com/d/** >>> msg/thin-ruby/-/wpNCjIN3M_UJ<https://groups.google.com/d/msg/thin-ruby/-/wpNCjIN3M_UJ>
>>> .
>>> To post to this group, send email to thin...@googlegroups.com.
>>> To unsubscribe from this group, send email to thin-ruby+...@**
>>> googlegroups.com.
> To post to this group, send email to thin-ruby@googlegroups.com.
> To unsubscribe from this group, send email to
> thin-ruby+unsubscribe@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/thin-ruby?hl=en.
No, not at all. The queries are fairly robust, but I'm using Mongo. What happens if I lower max persisted connections to say, 100? This is wear it seems to slow down dramatically. ps- the app is stateless, no sessions.
On Wednesday, August 22, 2012 1:09:12 PM UTC-4, macournoyer wrote:
> If the connections are not being closed is because there is some activity > on the socket. Are you doing anything special, like real-time updates > inside Rails?
> On Wed, Aug 22, 2012 at 12:10 PM, de <jimmie48...@gmail.com <javascript:>>wrote:
>> Timeout is set to 30seconds, but just noticed now >> max_persistant_connections is set to 512 which is almost precisely where >> the app dies. I'm assuming I should lower this. Just soaking up way to much >> memory. Here's my config.
>> On Wednesday, August 22, 2012 12:05:50 PM UTC-4, macournoyer wrote:
>>> Did you set the timeout option to 0 or something? You can also limite >>> the number of persistent connections with --max-persistent-conns option.
>>> On Wed, Aug 22, 2012 at 12:02 PM, de <jimmie48...@gmail.com> wrote:
>>>> I have a rails app running Thin. During peak hours holds up pretty >>>> well... but i've noticed child processes or connections persist and slow >>>> the application to almost a crawl. Since we launch, I've had to restart the >>>> application servers frequently. Can someone explain to me what's happening. >>>> I'm putting God in place to monitor this now and I'm using the following to >>>> verify currently:
>>>> Bash$ netstat -nap | grep 3000 | wc -l
>>>> -- >>>> You received this message because you are subscribed to the Google >>>> Groups "thin-ruby" group. >>>> To view this discussion on the web visit https://groups.google.com/d/** >>>> msg/thin-ruby/-/wpNCjIN3M_UJ<https://groups.google.com/d/msg/thin-ruby/-/wpNCjIN3M_UJ> >>>> . >>>> To post to this group, send email to thin...@googlegroups.com. >>>> To unsubscribe from this group, send email to thin-ruby+...@** >>>> googlegroups.com.
>> To post to this group, send email to thin...@googlegroups.com<javascript:> >> . >> To unsubscribe from this group, send email to >> thin-ruby+...@googlegroups.com <javascript:>. >> For more options, visit this group at >> http://groups.google.com/group/thin-ruby?hl=en.
Thin should kill off any connections over max_persisted_conns, right? So If i'm seeing persisted connections hover around 512 which it was previously set too, Thin won't do anything. The application will continually eat memory. If I lower the limit on max persisted connections, I should be fine unless I choose to increase the instance size at a later date. Equally, I could just turn this off by setting this config to 0.
On Wednesday, August 22, 2012 1:14:23 PM UTC-4, de wrote:
> No, not at all. The queries are fairly robust, but I'm using Mongo. What > happens if I lower max persisted connections to say, 100? This is wear it > seems to slow down dramatically. ps- the app is stateless, no sessions.
> On Wednesday, August 22, 2012 1:09:12 PM UTC-4, macournoyer wrote:
>> If the connections are not being closed is because there is some activity >> on the socket. Are you doing anything special, like real-time updates >> inside Rails?
>> On Wed, Aug 22, 2012 at 12:10 PM, de <jimmie48...@gmail.com> wrote:
>>> Timeout is set to 30seconds, but just noticed now >>> max_persistant_connections is set to 512 which is almost precisely where >>> the app dies. I'm assuming I should lower this. Just soaking up way to much >>> memory. Here's my config.
>>> On Wednesday, August 22, 2012 12:05:50 PM UTC-4, macournoyer wrote:
>>>> Did you set the timeout option to 0 or something? You can also limite >>>> the number of persistent connections with --max-persistent-conns option.
>>>> On Wed, Aug 22, 2012 at 12:02 PM, de <jimmie48...@gmail.com> wrote:
>>>>> I have a rails app running Thin. During peak hours holds up pretty >>>>> well... but i've noticed child processes or connections persist and slow >>>>> the application to almost a crawl. Since we launch, I've had to restart the >>>>> application servers frequently. Can someone explain to me what's happening. >>>>> I'm putting God in place to monitor this now and I'm using the following to >>>>> verify currently:
>>>>> Bash$ netstat -nap | grep 3000 | wc -l
>>>>> -- >>>>> You received this message because you are subscribed to the Google >>>>> Groups "thin-ruby" group. >>>>> To view this discussion on the web visit https://groups.google.com/d/* >>>>> *msg/thin-ruby/-/wpNCjIN3M_UJ<https://groups.google.com/d/msg/thin-ruby/-/wpNCjIN3M_UJ> >>>>> . >>>>> To post to this group, send email to thin...@googlegroups.com. >>>>> To unsubscribe from this group, send email to thin-ruby+...@** >>>>> googlegroups.com.
>>> To post to this group, send email to thin...@googlegroups.com. >>> To unsubscribe from this group, send email to >>> thin-ruby+...@googlegroups.com. >>> For more options, visit this group at >>> http://groups.google.com/group/thin-ruby?hl=en.