php fpm – How to separate vhost(web site) and extend limits per vhost on nginx.
I’m done it for phpmyadmin to allow import large files (this can be used to separate vhosts with limitations or extend as well)
change
; pool name (‘www’ here)
[www]
to
[phpmyadmin]
change
; Note: This value is mandatory.
listen = /var/run/php5-fpm.sock
to
; Note: This value is mandatory.
listen = /var/run/php5-fpm-phpmyadmin.sock
chnge
fastcgi_pass unix:/var/run/php5-fpm.sock;
to
fastcgi_pass unix:/var/run/php5-fpm-phpmyadmin.sock;
# cp /etc/php5/fpm/pool.d/www.conf /etc/php5/fpm/pool.d/phpmyadmin.conf
# nano /etc/php5/fpm/pool.d/phpmyadmin.conf
change
; pool name (‘www’ here)
[www]
to
[phpmyadmin]
change
; Note: This value is mandatory.
listen = /var/run/php5-fpm.sock
to
; Note: This value is mandatory.
listen = /var/run/php5-fpm-phpmyadmin.sock
# nano /etc/nginx/sites-enabled/phpmyadmin
chnge
fastcgi_pass unix:/var/run/php5-fpm.sock;
to
fastcgi_pass unix:/var/run/php5-fpm-phpmyadmin.sock;
# nano /home/phpmyadmin/.user.ini
add
upload_max_filesize = 20M
memory_limit = 256M
max_execution_time = 300
max_input_time = 240
# sudo service php5-fpm restart
# sudo service nginx reload
No comments:
Post a Comment