I'm having an issue with Puma, it fails when it tries to restart itself.
When this happens it kills all the Puma processes, resulting in nginx
delivering a 502 Bad Gateway to our users. I'm able to start, stop &
restart it with my /etc/init.d/puma script (it runs
/usr/local/bin/run-puma), it just has issues when it restarts itself. The
puma.log file doesn't show anything just useful for troubleshooting, just

Puma starting in single mode...
* Version 2.5.1, codename: Astronaut Shoelaces
* Min threads: 16, max threads: 32
* Environment: production
* Listening on unix:///home/deploy/app/shared/sockets/puma.sock

and my workers. Any help would be greatly appreciated.

Also - i have whats probably a pretty dumb question. Is there a way for me
to allocate more resources to Puma so it doesn't need to restart itself so
frequently? I'm currently only using around 25% of the server's memory.

Thanks for the help

--
You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
To post to this group, send email to rubyonrails-talk@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/9ac8c9a9-ea48-40f6-87dd-2312d460925d%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Search Discussions

  • Hassan Schroeder at Aug 29, 2013 at 10:42 pm

    On Thu, Aug 29, 2013 at 2:51 PM, Rob Daniels wrote:
    I'm having an issue with Puma, it fails when it tries to restart itself.
    When this happens it kills all the Puma processes, resulting in nginx
    delivering a 502 Bad Gateway to our users. I'm able to start, stop & restart
    it with my /etc/init.d/puma script (it runs /usr/local/bin/run-puma), it
    just has issues when it restarts itself.
    So, "restarts itself"? Do you have any idea why? I've never seen any
    of my own Puma instances spontaneously restart.

    Have you looked in the system logs for anything relevant? Is there
    a mismatch between you-the-user-manually-starting-it and the user
    that the process is normally running as/restarting as?

    What Ruby are you running?

    --
    Hassan Schroeder ------------------------ hassan.schroeder@gmail.com
    http://about.me/hassanschroeder
    twitter: @hassan

    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CACmC4yBKWmy9-O0j0NEYg9__njdyCN4By2uUuZUD97ho2X%2BaNQ%40mail.gmail.com.
    For more options, visit https://groups.google.com/groups/opt_out.
  • Rob Daniels at Aug 30, 2013 at 12:47 pm
    FIXED
    I had the restart_command in puma.rb trying to run 'puma.sock restart', I
    pointed it to my init.d file and it no longer has an issue when it boots
    workers

    restart_command '/etc/init.d/puma restart'

    I still occasionally get a 504 timeout under very heavy load, but i have
    the god gem monitoring too and it recovers from that quickly



    On Thursday, August 29, 2013 5:51:24 PM UTC-4, Rob Daniels wrote:

    I'm having an issue with Puma, it fails when it tries to restart itself.
    When this happens it kills all the Puma processes, resulting in nginx
    delivering a 502 Bad Gateway to our users. I'm able to start, stop &
    restart it with my /etc/init.d/puma script (it runs
    /usr/local/bin/run-puma), it just has issues when it restarts itself. The
    puma.log file doesn't show anything just useful for troubleshooting, just

    Puma starting in single mode...
    * Version 2.5.1, codename: Astronaut Shoelaces
    * Min threads: 16, max threads: 32
    * Environment: production
    * Listening on unix:///home/deploy/app/shared/sockets/puma.sock

    and my workers. Any help would be greatly appreciated.

    Also - i have whats probably a pretty dumb question. Is there a way for me
    to allocate more resources to Puma so it doesn't need to restart itself so
    frequently? I'm currently only using around 25% of the server's memory.

    Thanks for the help
    --
    You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group.
    To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe@googlegroups.com.
    To post to this group, send email to rubyonrails-talk@googlegroups.com.
    To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/57281308-5f55-49ce-bec3-2a06a6e9c592%40googlegroups.com.
    For more options, visit https://groups.google.com/groups/opt_out.

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
grouprubyonrails-talk @
categoriesrubyonrails
postedAug 29, '13 at 9:51p
activeAug 30, '13 at 12:47p
posts3
users2
websiterubyonrails.org
irc#RubyOnRails

2 users in discussion

Rob Daniels: 2 posts Hassan Schroeder: 1 post

People

Translate

site design / logo © 2022 Grokbase