View Full Version : Error Logs do not show my site
peeka
03-16-2009, 06:51 PM
After logging into CPanel, clicking Logs, and then clicking on Error Logs does not show the web server error logs for my web site on HostMonster. Instead I see the error activity for a "Family-Mingle" site.
Is this a configuration problem of mine or am I seeing someone else's error log.
Please let me know what to do to fix this since I really would like to see the httpd error messages from my web site.
Thank you
Falcon1986
03-16-2009, 07:00 PM
Entries appearing in the MAIN error_log section are from server-wide errors. They are not necessarily coming from your website.
Only entries that appear in the SUEXEC and PHP sections relate to your website.
peeka
03-16-2009, 10:02 PM
Arrgh!!! Apache can log activity to two logs, one for web site activity and another for web site errors. The config files for each web site can define a separate log file for activity and for errors .... per web site .... thus each web site can have its own two separate log files for its web activity. You can appy the same compression and quotas to both these files for each web site.
I use the error log for debugging by putting print statements in my cgi code rather than messing with the web page or writing to a file.
peeka
03-17-2009, 07:52 PM
It would be cleaner if the Apache web server was configured to provide a separate error log files for each site.
The error log directive can be added to the virtual host definition of each configured domain. For examples, check this link out: http://www.sitepoint.com/article/configuring-web-logs-apache/
Falcon1986
03-17-2009, 08:02 PM
I don't believe the use of VirtualHost is allowed or even possible in this shared server environment. You would probably require a VPS at minimum, which you should already know HostMonster does not provide.
peeka
03-18-2009, 07:54 PM
Ah, as I understand it, VirtualHost is a directive in Apache's config files. There is one VirtualHost definition per domain defined on the system to Apache. All of these domains share a single Apache server on a single system. This is the way that Apache can be configured so that a single physical server can support multiple domains. I believe that this is the way that Apache is configured on HostMonster.
Within each VirtualHost definition, it is possible to override various directives in the main Apache configuration file, such as the locations for the domain's access and error log files, thus providing each such domain with some unique characteristics.
More examples: http://httpd.apache.org/docs/2.0/vhosts/examples.html show how to provide what appears to be a static IP for a domain even though all the software is running on a shared server.
Falcon1986
03-18-2009, 08:17 PM
I believe that this is the way that Apache is configured on HostMonster.
That is what is implied if you understand the meaning of shared web hosting.
Within each VirtualHost definition, it is possible to override various directives in the main Apache configuration file, such as the locations for the domain's access and error log files, thus providing each such domain with some unique characteristics.
Yes, but we as customers do not have access to those configuration files. If you want a dedicated IP address for your website you can purchase one from HostMonster, but you are still not able to gain access to these files.
Again, you need not worry about errors showing up for other websites on the server. The Error Logs panel in cPanel that displays these logs are not storing logs from other websites on your webspace anyway. All errors related to your website are stored within error_log files and are found in the directory where the error occurred. The cPanel Error Logs panel gathers the information from these files and simply displays their contents all in one place for you.
peeka
03-19-2009, 01:19 PM
I agree with your responses except for your last paragraph:
Again, you need not worry about errors showing up for other websites on the server. The Error Logs panel in cPanel that displays these logs are not storing logs from other websites on your webspace anyway. All errors related to your website are stored within error_log files and are found in the directory where the error occurred. The cPanel Error Logs panel gathers the information from these files and simply displays their contents all in one place for you.
If that be true, then I would not see "family-mingle.com" error messages when I look at the error log for my domain, peekalum.com. I expected to see a blank file (no errors) or errors related to cgi code that was running in my domain.
I apologize if my previous posts were confusing, but I was just pointing out that the error log for each domain could be placed in separate files and thus avoid what appears to be a co-mingling of error logs from multiple domains. BTW, I am familiar with configuring Apache web servers ... but have not done it for a couple of years.
Powered by vBulletin® Version 4.1.10 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.