Moved domain main website folder which broke webalizer

snowweb

Verified User
Joined
Aug 31, 2007
Messages
144
Location
Antipolo City, Rizal, Philippines (a British Natio
In an attempt to reorganize the directory structure for one domain, I seem to have upset webalizer.

I did have structure as follows:

/home/<username>/domains/<domain>/public_html/<root-of-main-site>/
/home/<username>/domains/<domain>/public_html/<root-of-main-site>/<sub-domain-1>/<root-of-sub-domain-1>/
/home/<username>/domains/<domain>/public_html/<root-of-main-site>/<sub-domain-2>/<root-of-sub-domain-2>/

I didn't want the main site to contain the directories of the sub domains in it, so I re-organized it as follows:

/home/<username>/domains/<domain>/public_html/<main-site>/<root-of-main-site>/
/home/<username>/domains/<domain>/public_html/<sub-domain-1>/<root-of-sub-domain-1>/
/home/<username>/domains/<domain>/public_html/<sub-domain-2>/<root-of-sub-domain-2>/

I also created a symbolic link in the moved root of the main site, called 'stats', directed back to /home/<username>/domains/<domain>/stats/

I updated http.conf manually. That was in August last year and all appeared ok until I just noticed that the stats for that whole domain appear to no longer be generated.

Do you know of a solution for this please?

Kind regards,

Peter
 
Webalizer doesnt care what your paths are it just reads the apache logs. What error are you getting?
 
Webalizer doesnt care what your paths are it just reads the apache logs. What error are you getting?

Forgot to mention, I moved them as well. By updating the paths in http.conf. Bad idea?

I did it as all logs appeared to flung in one directory and since this particular domain has many sub domains, I wanted to organize it further.

I guess I need to find out how to update the path that webalizer uses to find the log files, and ammend it only for just this domain.

I don't suppose you know where to find that do you?
 
Further information:

I just checked and what I actually did was rename the path to the log files as follows:

/var/log/httpd/domains/<mydomain>.<main-site>.log
/var/log/httpd/domains/<mydomain>.<sub-domain-1>.log
/var/log/httpd/domains/<mydomain>.<sub-domain-2>.log

I should mention that I only did this for this one domain as it has more than one or two sub domains.
 
Webalizer doesnt care what your paths are it just reads the apache logs. What error are you getting?

So these lines below in httpd.conf only tell apache where to store the files and these lines are not read by webalizer in order to find the files?

CustomLog /var/log/httpd/domains/<my-domain>.bytes bytes
CustomLog /var/log/httpd/domains/<my-domain>.log combined
ErrorLog /var/log/httpd/domains/<my-domain>.ph.error.log

So are you saying that if there are logs in the /var/log/httpd/domains/ webalizer should automatically find them without reference to any other files?

I've not seen any errors. Maybe I'm not looking in the right places? Where should I look for error messages please?

One really odd thing, is that in desperation to get it working earlier, I decided to just move the logs for the main site back to where they were originally. I updated the httpd.conf with the new paths (the lines above), created the log files manually in their new locations (in case apache can't and set the permissions the same as the other logs and I reloaded httpd.conf. It still continues to use the existing logs though, even though there is no reference to them that I can see!
 
Last edited:
Hello Pete,

And what to you want to get as an answer? You've already been told (and you've admitted this), the path to logs make the difference.

Code:
# webalizer --help
Usage: webalizer [options] [log file]

How do you think webalizer is going to know that you've moved your logs? Do you really think it reads apache configs?

If you want to make webalizer to read apache logs from new location, you'd better disable build-in directadmin support for webalizer and run your own script nightly to parse the logs.
 
Many thanks for your very friendly and - oh, so helpful reply!

Since no one seems willing (or maybe capable) to provide the answers to my questions, I installed AWStats a couple of hours ago, independently of DA (since I haven't used the DA interface for a couple of years anyway).

AWStats seems to be a lot more sophisticated than Webalizer (which I read on another forum, has not been supported since 2002).

AWStats installs easily and work nicely (for anyone who's interested in doing the same).
 
Yes, awstats is really great.

Just wonder, what questions are left without a reply? I can't say if anyone here is still using Webalizer or not. But for sure I'm not using it, even despite on this it is obvious that this issue is caused by changed paths of logs. I've searched prior to my previous answer and have not found a way to configure webalizer and make it to search logs in another location. So my purpose was not to give you a direct answer but to give you a hint. I apologize if you found me too rude.
 
Back
Top