Passenger error #2 Apache

josephh

Verified User
Joined
Jul 21, 2019
Messages
20
Hello guys, I'm using Directadmin with Cloudlinux. But on all domains access webmail i get error

Code:
Passenger error #2
An error occurred while trying to access '/home/myusername/domains/myusername.com/passenger_wsgi.py': Cannot stat '/home/myusername/domains/myusername.com/passenger_wsgi.py': Permission denied (errno=13)

Apache doesn't have read permissions to that file. Please fix the relevant file permissions.

I tried building apache with suphp using the bellow code but it just crashes apache.

Code:
/usr/local/directadmin/custombuild/build set mod_ruid2 no
/usr/local/directadmin/custombuild/build set mod_php no
/usr/local/directadmin/custombuild/build set php1_mode suphp
/usr/local/directadmin/custombuild/build set cloudlinux yes
/usr/local/directadmin/custombuild/build set cagefs yes
/usr/local/directadmin/custombuild/build update
/usr/local/directadmin/custombuild/build apache
/usr/local/directadmin/custombuild/build php y
/usr/local/directadmin/custombuild/build suphp
/usr/local/directadmin/custombuild/build rewrite_confs
cagefsctl --force-update
cagefsctl --remount-all

Any Idea on how to get this resolved, I currently using mod_php
 
Passenger is not a part of DirectAdmin. It must be used for NodeJS/Python selector from CloudLinux. I'd suggest contacting CloudLinux on this.
 
Many will come here because of a Google search. Can you tell us how it got resolved? What was the solution?
 
For my particular case the issue I had "mod_ruid2" and "mod_php" enabled. Which is not a cloudlinux friendly combination. This combination worked ok for websites but it showed a "Passenger error #2" on domains webmail link.

But switching to "suphp" with "mod_ruid2" and "mod_php" disabled crashed apache.

The root cause of apache build errors was the SSL-cache mutex issue.

[Wed Jun 10 10:07:15.440031 2020] [core:emerg] [pid 2309353:tid 140156086737088] (28)No space left on device: AH00023: Couldn't create the ssl-cache mutex
AH00016: Configuration Failed


"This is a common apache issue and I've fixed it with this command:"

for i in $(ipcs -s | grep apache | awk '{print $2}'); do ipcrm sem $i; done && service httpd restart
 
Last edited:
Code:
for i in $(ipcs -s | grep apache | awk '{print $2}'); do ipcrm sem $i; done && service httpd restart

Oh yeah I have a cron job that runs it every 10 minutes.
 
Out of curiosity, I always still use mod_php with mod_ruid2. Why do you still use suphp then? Because mod_ruid2 is already doing this?

Do you use mod_php with mod_ruid2 on a cloudlinux server? And I meant switching to "suphp" with "mod_ruid2" and "mod_php" disabled crashed apache.
 
As said, I was only asking out of curiousity. I don't use cloudlinux no. I know you said it crashed apache, I was just wondering if it would also crash when only using mod_ruid2 with mod_php without suphp. Because suphp+modruid2 is doing things double which might also interfere with eachother. So I was just asking myself that. Or rather that triggered my curiosity.
 
Back
Top