Every time i restart apache, i am getting this error:
Warning: DocumentRoot [/dev/null] does not exist
That is not an error; it is a warning. Apache makes the distinction between a warning and an error; they do not have the same meaning and the words should not be used interchangeably. A warning tells about an issue that should be corrected, but will not prevent Apache from starting. An error tells you about an issue that is preventing Apache from starting.
First, is Apache running? Try the following command:
Code:
# /usr/local/apache/bin/apachectl status
You should see an Apache status report, similar to the following:
Code:
# /usr/local/apache/bin/apachectl status
Apache Server Status for localhost
Server Version: Apache/2.2.15 (Unix) mod_ssl/2.2.15
OpenSSL/0.9.8e-fips-rhel5 mod_bwlimited/1.4
Server Built: Apr 15 2010 10:59:05
_________________________________________________________________
Current Time: Tuesday, 01-Feb-2011 08:33:48 CST
Restart Time: Tuesday, 11-Jan-2011 14:48:20 CST
Parent Server Generation: 273
Server uptime: 20 days 17 hours 45 minutes 28 seconds
Total accesses: 46199 - Total Traffic: 668.7 MB
CPU Usage: u.05 s.06 cu.37 cs0 - 2.68e-5% CPU load
.0258 requests/sec - 391 B/second - 14.8 kB/request
1 requests currently being processed, 9 idle workers
__W_____...._............_......................................
................................................................
................................................................
................................................................
Scoreboard Key:
"_" Waiting for Connection, "S" Starting up, "R" Reading Request,
"W" Sending Reply, "K" Keepalive (read), "D" DNS Lookup,
"C" Closing connection, "L" Logging, "G" Gracefully finishing,
"I" Idle cleanup of worker, "." Open slot with no current process
If you see something like the above, then nothing is wrong and you do not need to fix anything. Warnings from Apache will not prevent Apache from starting and can normally be disregarded.
If you do not see an Apache status display (it should look like what you would see in the WebHost Manager if you click Main >> Server Status >> Apache Status, because that is the command that the WHM uses to get this information), then you can try rebuilding the Apache configuration and restarting Apache:
Code:
# cd /usr/local/apache/conf
# cp -p httpd.conf httpd.conf.old-bak
# /scripts/rebuildhttpdconf
# /scripts/restartsrv_httpd
# /usr/local/apache/bin/apachectl status
If Apache is still not running after this, please submit a ticket so that we may log into your server and assist you individually. We can normally fix a problem with a service not starting in a very timely manner if we can log into the server via a ticket.