Already done:
a2dissite 000-default.conf
and
service apache2 restart
So symlink successfully removed from sites-enabled directory. But i still can see that test page. What's wrong? Shouldn't i see an error instead?
apache-2.4Ubuntu
Already done:
a2dissite 000-default.conf
and
service apache2 restart
So symlink successfully removed from sites-enabled directory. But i still can see that test page. What's wrong? Shouldn't i see an error instead?
Best Answer
The Apache code (
httpd.h file
, in particular) sets a default location of documents, which can be overwritten by theDocumentRoot
directive. Depending on the installation, the Apache source code includes lines like the following:Because a default installation will also generally include a default
index.html
(and also default in the permissions settings to allow access the relevant directory), you can still be served a default page even if you remove all of the default sites. In order to prevent this, in favor of an error, you will have to set a default DocumentRoot that has no "index" type file or for which permission is denied, or you will have to remove such files from the directory that your installation defaults to in the Apache code.