How did I fix «ucfr: Attempt from package php7.1-cli to take /etc/php/7.1/fpm/php.ini away from package php7.1-fpm»?

Step 1

rm -rf /etc/php/7.1/cli

unix.stackexchange.com/a/185979

Step 2

aptitude full-upgrade

Step 3

rm -rf /etc/php/7.1/cli &&
ln -s /etc/php/7.1/fpm /etc/php/7.1/cli

My new solution:

rm -rf /etc/php/7.1/cli
rm -rf /etc/php/7.1/fpm
rm -rf /etc/php/7.2/cli
rm -rf /etc/php/7.2/fpm
aptitude full-upgrade
rm -rf /etc/php/7.1/cli
rm -rf /etc/php/7.1/fpm
rm -rf /etc/php/7.2/cli
rm -rf /etc/php/7.2/fpm
ln -s /etc/php/7.1/common /etc/php/7.1/cli
ln -s /etc/php/7.1/common /etc/php/7.1/fpm
ln -s /etc/php/7.2/common /etc/php/7.2/cli
ln -s /etc/php/7.2/common /etc/php/7.2/fpm

ubuntuforums.org/showthread.php?t=2196108&p=13088005#post13088005

My new solution is to patch deb.sury.org files in the /var/lib/dpkg/info/ folder: df.tips/t/topic/1940/3

See also: