A disk on one of our servers was filling up. Analysis showed that most of the space was wasted in /tmp
.
The culprit was the 25,000+ files there that were taking up more than 3 gigs, all of them named after the pattern passenger-error-xxxxxx.html
. A quick inspection showed that this was the standard error page Passenger serves when it cannot start an application.
From the message in one of those files, Passenger could not start the application because mysql2
gem was missing and it couldn't connect to the database.
From a rough estimate, it seems as if Passenger kept these files at least for each request which was due to health checks from ELB (request every 30 seconds = 2880reqs/day, Gemfile was fixed after 5 days which should be less than 15,000reqs).
Is it documented anywhere that Passenger keeps these HTML files in /tmp
?
Why does it do that? Is something wrong with our config?
/tmp
over the weekend just because the app was never working. But I regard this as "documented behavior" now :) – Peterson