The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

webalizer lost all history

Discussion in 'General Discussion' started by dev.null, Jan 16, 2004.

  1. dev.null

    dev.null Well-Known Member

    Joined:
    May 27, 2003
    Messages:
    75
    Likes Received:
    1
    Trophy Points:
    6
    I just updated my webalizer as per

    http://forums.cpanel.net/showthread.php?s=&postid=88146


    Now when I run

    /scripts/runweblogs <name>

    I see this in the output:

    Error: Unable to save current run data
    Error: Unable to write history file /var/lib/webalizer/webalizer.hist

    Here's two other things I notice:

    1. The history is gone from the webalizer html pages. The only data in there is the data from what's left in the apache log. This is *real* bad.
    2. The /home/<name>/tmp/webalizer/webalizer.current and *.hist files are not changed, they still have yesterday's time and date on them. So it looks like webalizer can't read them and doesn't update them. I've checked the file permissions, they are the same as all the other files in the webalizer directory (owner:group set to the site's user ID).

    Any ideas why it's not keeping all the old history and/or how to get it back in?

    Thanks!

    cPanel.net Support Ticket Number: don't I wish I had one eh?
     
  2. dev.null

    dev.null Well-Known Member

    Joined:
    May 27, 2003
    Messages:
    75
    Likes Received:
    1
    Trophy Points:
    6
    UPDATE/FIX

    OK, when I first installed the rpm webalizer (from another post here as the DNS fix) I was checking the stats page in for January on my own domain. I kept tweeking the /home/domain/webalizer.conf file, running `runweblogs domain`, and then refreshing the page in the browser to see the .conf changes take place. I had it set exactly like I wanted.

    I know it was working correctly back then with all the right stats, and it was finally doing the dns resolve and country pie graph (I finally got to see what it lookes like).

    All of the sudden it starts giving me a report on *another domain*, and only what was currently in the apache logs on top of that! I thought I had lost all my history (and my mind too!).

    Well after doing the command line webalizer myself several times and reading the .conf instructions and the man page again and again I decided to leave nothing out. I went through every command and figured out what webalizer would do step by step. Then I realized in the man page it was telling me it would always try to use /etc/webalizer.conf if it were there. I checked, sure enough it was there. And it had it's HistoryName and IncrementalName pointing to the /var/lib/webalizer directory.

    I don't know when it slipped in, but whenever it did it was smooth. It had to have slipped in after I had already successfully ran webalizer on my own .conf file and saw my web stats the way I wanted them. The funny thing is I never did anthing (that I know of) that would have made this .conf file.

    So, after deleting the bad .conf, rm'ing the /var/lib/webalizer directory, and putting a webalizer.conf in each /home/<name> directory that specified their history and current webalizer files, a /scripts/runweblogs re-created all my stats the way I wanted them. Minus one thing - the dns names it had already looked up were now gone and there are only IPs in their place. Only new hits are getting their DNS names looked up. A minor glitch, at least I've got my real stats back.
     
Loading...

Share This Page