1 (edited by Chrissicom 2017-08-15 09:11:44)

Topic: php-fpm is broken by default in 0.9.7 on CentOS 7 with nginx [solved]

In a fresh installation on CentOS 7 of iRedMail 0.9.7 the php-fpm configuration is broken by default when using nginx (I haven't tried what happens when installing apache). The following changes need to be done.

nano /etc/php-fpm.d/www.conf

# otherwise socket configured in /etc/nginx/conf-available/php-fpm.conf is missing
listen = /run/php-fpm/php-fpm.socket

# otherwise you see permission denied errors in /var/log/nginx/error.log
listen.owner = nginx
listen.group = nginx
listen.mode = 0660

# nginx is running as user nginx and not apache
user = nginx
group = nginx

----

Spider Email Archiver: On-Premises, lightweight email archiving software developed by iRedMail team. Supports Amazon S3 compatible storage and custom branding.

2

Re: php-fpm is broken by default in 0.9.7 on CentOS 7 with nginx [solved]

Chrissicom wrote:

The following changes need to be done.

I got exactly same settings with default iRedMail installation.

3

Re: php-fpm is broken by default in 0.9.7 on CentOS 7 with nginx [solved]

ZhangHuangbin wrote:
Chrissicom wrote:

The following changes need to be done.

I got exactly same settings with default iRedMail installation.

That's interesting. /etc/php-fpm.d/www.conf looked for me like below after making a fresh installation of iRedMail 0.9.7. As you can see it wasn't even listening on a socket, that's why it couldn't work out of the box. What components of iRedMail actually use php-fpm? iRedAdmin and SoGo worked with the broken configuration, I only needed to fix it to install adminer.

nano /etc/php-fpm.d/www.conf

# otherwise socket configured in /etc/nginx/conf-available/php-fpm.conf is missing
listen = 127.0.0.1:9000

# otherwise you see permission denied errors in /var/log/nginx/error.log
;listen.owner = nobody
;listen.group = nobody
;listen.mode = 0666

# nginx is running as user nginx and not apache
user = apache
group = apache