Reputation: 1051
I have running RoR site which handled by unicorn. Unicorn master process spawns 10 workers and handle them well, but workers sometimes starts to spawn threads inside and do not kill them.... it leads to memory leaks and server fault.
I solved it by cron script which restarts unicorn every 10 minutes, but its really bad solution. Any ideas?
ScreenProof:
Unicorn (4.6.1) configuration files: https://gist.github.com/907th/4995323
Upvotes: 0
Views: 415
Reputation: 11436
Look into using Monit (http://mmonit.com/monit/) to monitor Unicorn and keep it in check. Watch Ryan Bates' wonderful video on the subject:* http://railscasts.com/episodes/375-monit
*requires a subscription but it's well worth the paltry $9 he's asking.
Upvotes: 1