How to Remove the Default php-fpm www Pool File

If you’ve set up a php based site using php-fpm you have probably copied the default www pool configuration file and edited the copy. It’s good to deactivate the default www . conf file so it doesn’t consume any resources since it’s not used at all. When doing destructive things it’s good practice to rename the file or move it to another location in case you need this later.

Some people prefer to delete it though. Those files consume so little space that it doesn’t matter if it’s deleted or not.

In our case the installed php version was 7.4. so the pool.d folder is in /etc/php/7.4/fpm/pool.d/

Solution

Open your ssh terminal or putty/kitty on Windows.

Then go to /etc/php/7.4/fpm/pool.d directory and then rename the www.conf file to something else.

cd /etc/php/7.4/fpm/pool.d

mv www.conf www.conf-inactive 

It’s good to call reload (graceful restart) so any existing connections are not interrupted.

service php7.4-fpm reload

Image credit: php elegaphan by ben griffiths on unsplash

Related

https://serverfault.com/questions/868032/how-to-safely-remove-www-pool-and-default-site-from-nginx

Referral Note: When you purchase through a referral link (if any) on this page, we may earn a commission.
If you're feeling thankful, you can buy me a coffee or a beer