Skip to content

Instantly share code, notes, and snippets.

@mguymon
mguymon / passenger-management.rb
Created August 5, 2011 20:27 — forked from loopj/passenger-management.rb
Checks memory usage of all paseenger child process and kill if grows too large. Additionally kill off long running passengers to prevent memory leak issues (similar to the PassengerMaxRequests config variable in apache's passenger version, but works on bo
#!/usr/bin/env ruby
#
# Passenger management script
# By James Smith http://loopj.com
# Based heavily on a similar script by Jon Bettcher
#
# Check memory usage of all paseenger child process and kill if grows
# too large.
#