When i try to install php7.4-fpm using apt install php7.4-fpm
on my xenial machine, it will show this error:
Setting up php7.4-fpm (7.4.2-3+ubuntu16.04.1+deb.sury.org+1) ...
touch: cannot touch '/run/php/php7.4-fpm.sock': No such file or directory
when i create this folder:
mkdir /run/php
and chmod
it to 777 then shows this error:
Setting up php7.4-fpm (7.4.2-3+ubuntu16.04.1+deb.sury.org+1) ...
/var/lib/dpkg/info/php7.4-fpm.postinst: 32: /var/lib/dpkg/info/php7.4-fpm.postinst: /run/php/php7.4-fpm.sock: Permission denied
dpkg: error processing package php7.4-fpm (--configure):
subprocess installed post-installation script returned error exit status 126
Errors were encountered while processing:
php7.4-fpm
E: Sub-process /usr/bin/dpkg returned an error code (1)
I did purge php* but no difference. Also there's this behavior with another versions like 7.3, 7.2 too.