Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I wanted a clean reinstall of php5-cli, php5-common, php5-fpm. So what I did was:

rm -rf /etc/php5
rm -rf /usr/local/lib/php5
rm -rf /usr/local/php5
rm -rf /usr/lib/php
apt-get autoremove php5*
apt-get purge php5*

But after reinstalling I don't have /etc/php5/cli/php.ini or /etc/php5/fpm/php.ini anymore. How could I get them back?

My install command:

apt-get install php5-cli php5-comon php5-cli --force-yes -o Dpkg::Options::=--force-confmiss

share|improve this question

First you need to do complete removal of packages using this command.

sudo apt-get purge php*

Now install again using

sudo apt-get install php* 

You will get generated new config files.

share|improve this answer
I'm not sure this is a good idea – Prozi Jun 6 '15 at 21:32

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.