0

I have an apache/passenger server that run rails apps, and this error is displayed when I try to run passenger-status :

passenger-status
ERROR: Phusion Passenger(R) doesn't seem to be running. If you are sure that it is running, then the causes of this problem could be:

1. You customized the instance registry directory using Apache's PassengerInstanceRegistryDir option, Nginx's passenger_instance_registry_dir option, or Phusion Passenger(R) Standalone's --instance-registry-dir command line argument. If so, please set the environment variable PASSENGER_INSTANCE_REGISTRY_DIR to that directory and run passenger-status again.
2. The instance directory has been removed by an operating system background service. Please set a different instance registry directory using Apache's PassengerInstanceRegistryDir option, Nginx's passenger_instance_registry_dir option, or Phusion Passenger(R) Standalone's --instance-registry-dir command line argument.

LS of the relevent processes

admin     3291  0.8  9.4 715484 291352 ?       Sl   16:27   0:54 Passenger RubyApp: /srv/production/*******app1 (production)
admin     3721  0.0  2.9 483276 90736 ?        Sl   08:27   0:03 Passenger RubyApp: /srv/production/********app2 (production)
admin    10963  0.0  0.0  13132   996 pts/0    S+   18:17   0:00 grep --color=auto Pass
root     18477  0.0  0.2 399440  7964 ?        Ssl  03:40   0:01 Passenger watchdog
root     18480  1.1  0.6 2682448 20956 ?       Sl   03:40  10:09 Passenger core

Here is the passenger config in the apache foldermods-available:

LoadModule passenger_module /home/admin/.rvm/gems/ruby-2.5.5/gems/passenger-6.0.8/buildout/apache2/mod_passenger.so
   <IfModule mod_passenger.c>
     PassengerRoot /home/admin/.rvm/gems/ruby-2.5.5/gems/passenger-6.0.8
     PassengerDefaultRuby /home/admin/.rvm/gems/ruby-2.5.5/wrappers/ruby
   </IfModule>

I checked the /tmp/ folder and nothing look like a passenger temp folder. How can I find and/or setup the instance registry directory ?

Sylario
  • 101
  • 1
  • 11

1 Answers1

0

There is an apache option that hide the instance registery directory for security reasons. It's possible to change it by setting PrivateTmp to true in : /etc/systemd/system/multi-user.target.wants/apache2.service

Once you restart apache, passenger-status works.

Sylario
  • 101
  • 1
  • 11