Troubleshooting Commands For Apache Web Server
Troubleshooting Commands For Apache is an Open Source Web server available in today’s market. The current Apache Web Server released version is 2.44.33. This is used to host the website on servers. we can troubleshoot the apache webserver using the below commands in Linux.
Let’s start Apache Troubleshooting
1. Check Apache service is running or not.
You have to check the Apache service is running or not by the below command.
systemctl status httpd
2. If the service is running, check the logs of Apache.
This logs will help you to see what errors you’re getting in the Apache configuration file and what is the reason for not working Apache.
/var/log/httpd/error_log and /var/log/httpd/access_log
3. Check the Apache configuration file syntax
4. Check virtual host configuration definition
5. Check modules
I will show you the list of loaded Static and shared modules.
6. Run Apache in debug mode
Check Out: Configuration Of mod_security in Apache
7. Check file config
This will help you to find a file conflict on startup in the directive
httpd –f filename
You’re done troubleshoot apache linux