Restore /etc/ configuration files from the default
A related serverfault question describes how to restore package conffiles if you've removed them, and requires that you track down the actual .deb
file.
All you need to do:
Find the list of conffiles provided by the package:
dpkg --status <package>
(look under the
Conffiles:
section).Remove those conffiles yourself.
Reinstall the package. If you've found the
.deb
file,dpkg -i --force-confmiss <package_deb>.deb
Alternatively, passing the
dpkg
option viaapt
should work:apt-get install --reinstall -o Dpkg::Options::="--force-confmiss" <package>
Besides remove
apt-get also offers the purge
command which cleans out your config customizations, which can then be followed by an apt-get install
apt-get install -o Dpkg::Options::="--force-confnew" packagename