I set as usual a VM with a standard configuration of Apache + Passenger hosting a Rails 3.2 app. The app is working with Sphinxsearch 2.0.4 via the thinking sphinx gem.
After the deploy, at first time the site is hit by an HTTP request, the typical thinking sphinx tasks (building index and start) are executed and after some seconds of delay, an error page is displayed with error:
[ 2013-06-19 17:07:35.1643 16678/7f2ee30ef700 Pool2/Implementation.cpp:774 ]: Could not spawn process for group /srv/www/owo.biz/www/current#default: An error occurred while starting up the preloader: it did not write a startup response in time.
in 'void Passenger::ApplicationPool2::SmartSpawner::throwPreloaderSpawnException(const string&, Passenger::SpawnException::ErrorKind, Passenger::ApplicationPool2::Spawner::BackgroundIOCapturerPtr&, const DebugDirPtr&)' (SmartSpawner.h:150)
in 'std::string Passenger::ApplicationPool2::SmartSpawner::negotiatePreloaderStartup(Passenger::ApplicationPool2::SmartSpawner::StartupDetails&)' (SmartSpawner.h:558)
in 'void Passenger::ApplicationPool2::SmartSpawner::startPreloader()' (SmartSpawner.h:206)
in 'virtual Passenger::ApplicationPool2::ProcessPtr Passenger::ApplicationPool2::SmartSpawner::spawn(const Passenger::ApplicationPool2::Options&)' (SmartSpawner.h:744)
in 'void Passenger::ApplicationPool2::Group::spawnThreadRealMain(const SpawnerPtr&, const Passenger::ApplicationPool2::Options&, unsigned int)' (Implementation.cpp:707)
[ 2013-06-19 17:07:35.1646 16678/7f2ee0a53700 agents/HelperAgent/RequestHandler.h:1889 ]: [Client 20] Cannot checkout session. An error occurred while starting up the preloader: it did not write a startup response in time.
Seems like the request goes in timeout and can't be answered.
Is the preloader needed and there is a way to disable it?
These are the interesting apache directives:
LoadModule passenger_module /usr/local/rvm/gems/ruby-1.9.3-p429/gems/passenger-4.0.5/libout/apache2/mod_passenger.so
PassengerRoot /usr/local/rvm/gems/ruby-1.9.3-p429/gems/passenger-4.0.5
PassengerDefaultRuby /usr/local/rvm/wrappers/ruby-1.9.3-p429/ruby
PassengerHighPerformance on
PassengerMaxPoolSize 10
PassengerPreStart http://new.example.com/
PassengerMinInstances 3