Restoring ‘apache2’ Directory on Ubuntu 15.04

If for any reason you want to restore your apache2 directory located at /etc/apache2 to its default state on Ubuntu 15.04 then I have a sure way to do so which I’m gonna share with you. Just follow the steps given below:

Note: I’m not providing any kind of guarantee if you mistakenly delete your data or made any other harm for yourself.

1. Remove the ‘apache2’ Directory

First of all you need to remove ‘apache2’ directory completely and permanently from your system, run the following command to remove the apache2 directory:

sudo rm -R /etc/apache2

2. Restore the ‘apache2’ Directory

Now, after removing we need to restore the ‘apache2′ directory, run the following command in your terminal to restore:

sudo apt-get -o DPkg::Options::="--force-confmiss" --reinstall install apache2

Hopefully the above described method will restore the apache2 directory to its default state. If you are having some problems in this regard then you can ask the relevant question via comments.

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s