Error "(2)No such file or directory: AH02291: Cannot access directory '/var/log/httpd/' for main error log" noticed while bringing up Apache HTTPD service.
Issue
- Below error seen while bringing up Apache HTTPD service.
Oct 25 00:11:21 example.com httpd[23459]: (2)No such file or directory: AH02291: Cannot access directory '/var/log/httpd/' for error log of vhost defined at /etc/httpd/conf/httpd.conf:6
Oct 25 00:11:21 example.com httpd[23459]: AH00014: Configuration check failed
Oct 25 00:11:21 example.com systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
Environment
- Red Hat Enterprise Linux
- 6.x, 7.x, 8.x
Subscriber exclusive content
A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.