Scheduled Maintenance: We are aware of an issue with Google, AOL, and Yahoo services as email providers which are blocking new registrations. We are trying to fix the issue and we have several internal and external support tickets in process to resolve the issue. Please see: viewtopic.php?t=158230

 

 

 

Apache 2.4 doesn't read configuration files

Linux Kernel, Network, and Services configuration.
Post Reply
Message
Author
syscon
Posts: 13
Joined: 2020-10-24 18:35

Apache 2.4 doesn't read configuration files

#1 Post by syscon »

The apache 2.4 doesn't read configuration files.
In apache2.conf I have:

Code: Select all

# Include the virtual host configurations:
IncludeOptional sites-enabled/*.conf 
So it should read read every *config file in sites-enabled/
In that directory I have:

Code: Select all

ll sites-enabled/
total 4
lrwxrwxrwx 1 root root   35 Oct 27 21:15 000-default.conf -> ../sites-available/000-default.conf
-rw-r--r-- 1 root root 3420 Oct 29 18:03 vhosts.conf
vhosts.conf - define my web-site, but I commented everything out in that file and restarted apache:
/etc/init.d/apache2 restart

And I can still display my web page.
How is it possible???

5ive
Posts: 4
Joined: 2020-12-13 21:10

Re: Apache 2.4 doesn't read configuration files

#2 Post by 5ive »

Since, the file 000-default.conf file will be read first. That file would be loaded before vhosts.conf
Apache when installed will be setup to point at an example web page. Perhaps, you copied over that file?

nano 000-default.conf and see what is inside it!
I do not take responsibility if you ruin your system.
Beginner’s Guide

thomas-gatry
Posts: 2
Joined: 2021-02-01 09:13

Re: Apache 2.4 doesn't read configuration files

#3 Post by thomas-gatry »

Hi guys!
After upgrading from 9 to 10
Apache stopped working :(

Сonfigurations may have been reset
What needs to be checked?

5ive
Posts: 4
Joined: 2020-12-13 21:10

Re: Apache 2.4 doesn't read configuration files

#4 Post by 5ive »

I would double check configuration files. Debian will ask what you want to do with an altered config file while upgrading.
It will ask to keep your original or install a new one.

More importantly, what messages are in the log files? I believe they should be located in /var/log/apache2/ or /var/log/httpd/
Otherwise ls /var/log/ and you should find them.
I no longer run Apache, so I don't know the exact location.

1. You can also in one terminal:
sudo journalctl -f -u apache2

This will follow the logging of the service apache2
2. In another terminal:
sudo systemctl restart apache2

This will restart your Apache 2 service, which should output logging into your first terminal.

You might see an error or be able to get better help supplying an error message to someone here.
I do not take responsibility if you ruin your system.
Beginner’s Guide

Post Reply