Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Apache Stats Module for Virtual Hosts

Status
Not open for further replies.

golfing22

IS-IT--Management
Nov 17, 2006
2
US
Sorry in advance if this is a duplicate story but anyways my current situation is, I'm hosting a website with multiple subdomains that are defined by Virtual Host. I have already have a good stats module for my CMS webpage, but I'm hosting a podcast for my friend (he has his own subdomain/virtual host) and he want to be able to view how many hits he gets. I've tried a few different stats modules but they seem to group all the virtual hosts as one. What I really want to do is be able to see how many people have gone to the subdomain only.

Thanks,
golfing22
 
I think that the easiset way is to create a different log file within each virtual host container. Then analyze the individual log files using your preferred log analyzer.

Another alternative is to add the virtual host (%v) to the existing log format string. Then you'd need to filter/parse the combined log file for whichever virtual hosts that you want to analyze.
 
Thanks a ton smah and rhythmace, I took your advice and create a separate log file location for the subdomain. The way it's set up now is that is creates a log file at "/ my question is if it's a big deal that anybody could access the logs via web-browser. I'm wondering if I should create a htaccess file for the logs folder or not.

Thanks
golfing22
 
It's generally not a good idea to have your logs accessible through your web server. Do you have a reason for doing this?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top