LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Webalizer with DNS lookups (http://www.linuxquestions.org/questions/linux-software-2/webalizer-with-dns-lookups-205965/)

jnichel 07-16-2004 04:21 PM

Webalizer with DNS lookups
 
I am trying to get webalizer up and running on a RHEL 3.0 box, but am having problems with getting the DNS lookup to work. I configured webalizer as such...

./configure --enable-dns --with-db=/usr/include/db4

Config, compile, install all went fine, but when I try to run webalizer on one of my log files, I get this....

Warning: Invalid keyword 'DNSCache' (/etc/webalizer/kegworks.conf)
Warning: Invalid keyword 'DNSChildren' (/etc/webalizer/kegworks.conf)
DNS support not present, aborting...

I've made sure that webalizer wasn't installed from an RPM anywhere on the box, removed, re-configured, re-compiled, and re-installed numerous times now, but still get the same error.

Any ideas?

korozion 07-16-2004 04:23 PM

Very easy, just turn on reverse DNS lookups in apache (op whatever webserver you are using). That will allow webalizer to see the dns names

jnichel 07-16-2004 04:26 PM

Quote:

Originally posted by korozion
Very easy, just turn on reverse DNS lookups in apache (op whatever webserver you are using). That will allow webalizer to see the dns names
I would prefer not to put that load on my webserver. The way I understood the webalizer docs is that this did not need to be done with Apache to get DNS lookups to work when configuring webalizer with the --enable-dns switch. Is this not the case?

Donboy 07-16-2004 04:32 PM

Are you able to do normal lookups from the machine? Like if you type "host [someipaddress]" is it able to convert the IP into a domain name? Check /etc/resolv.conf and be sure you've got good nameservers listed in there.

If you've got a whole bunch of log files you need to process on there, consider running a caching DNS server somewhere on your LAN or on the machine itself and it will speed up webalizer when it runs... otherwise it has to query your upstream ISP for all the lookups which can make it crunch for a while on all those log files.

bulliver 07-16-2004 04:35 PM

Have a look at this link:

http://www.mrunix.net/webalizer/faq.html

Question 7...

jnichel 07-16-2004 04:44 PM

Quote:

Originally posted by Donboy
Are you able to do normal lookups from the machine? Like if you type "host [someipaddress]" is it able to convert the IP into a domain name? Check /etc/resolv.conf and be sure you've got good nameservers listed in there.

If you've got a whole bunch of log files you need to process on there, consider running a caching DNS server somewhere on your LAN or on the machine itself and it will speed up webalizer when it runs... otherwise it has to query your upstream ISP for all the lookups which can make it crunch for a while on all those log files.

Yeah, the box can resolve. That's a good idea for the caching nameserver, if I get past this problem with webalizer, that'll probably be my next step.

jnichel 07-16-2004 04:50 PM

Quote:

Originally posted by bulliver
Have a look at this link:

http://www.mrunix.net/webalizer/faq.html

Question 7...

One of the first places I looked. According to that, webalizer will do reverse DNS lookups without having the webserver do it. I'm trying to figure out why it's telling me "DNS support not present, aborting..." when I did configure / compile it with DNS support.

Donboy 07-16-2004 05:55 PM

Maybe you have the wrong settings in your /etc/kegworks.conf file. The error you got seems to suggest that it doesn't like the keywords you put in the config file.

http://linux.cudeso.be/linuxdoc/weba...php#dns_lookup

Can you post your config file for us to see.

jnichel 07-16-2004 06:31 PM

Quote:

Originally posted by Donboy
Maybe you have the wrong settings in your /etc/kegworks.conf file. The error you got seems to suggest that it doesn't like the keywords you put in the config file.

http://linux.cudeso.be/linuxdoc/weba...php#dns_lookup

Can you post your config file for us to see.

Sure.....

Code:

LogFile        /webserver/server/logs/temp/kegworks.com-access_log
LogType        clf
OutputDir      /webserver/vhosts/dotcomholdingsofbuffalo.com/docs/secure/stats/kegworks.com/
HistoryName    /webserver/vhosts/dotcomholdingsofbuffalo.com/docs/secure/stats/kegworks.com/webalizer.hist
#Incremental    no
#IncrementalName        webalizer.current
ReportTitle    Usage Statistics for
HostName        KegWorks.com
#HTMLExtension  html
PageType        htm*
PageType        cgi
PageType        php
PageType        pl
UseHTTPS        no
DNSCache        /webserver/vhosts/dotcomholdingsofbuffalo.com/docs/secure/stats/kegworks.com/dns_cache.db
DNSChildren    10
#HTMLPre <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
#HTMLHead <META NAME="author" CONTENT="The Webalizer">
#HTMLBody <BODY BGCOLOR="#E8E8E8" TEXT="#000000" LINK="#0000FF" VLINK="#FF0000">
#HTMLPost      <BR CLEAR="all">
#HTMLTail <IMG SRC="msfree.png" ALT="100% Micro$oft free!">
#HTMLEnd </BODY></HTML>
Quiet          yes
ReallyQuiet    no
TimeMe          no
#GMTTime        no
#Debug          no
#FoldSeqErr    no
#VisitTimeout  1800
#IgnoreHist    no
#CountryGraph  yes
#DailyGraph    yes
#DailyStats    yes
#HourlyGraph    yes
#HourlyStats    yes
#GraphLegend    yes
#GraphLines    2
#TopSites      30
#TopKSites      10
#TopURLs        30
#TopKURLs      10
#TopReferrers  30
#TopAgents      15
#TopCountries  30
#TopEntry      10
#TopExit        10
#TopSearch      20
#TopUsers      20
#AllSites      no
#AllURLs        no
#AllReferrers  no
#AllAgents      no
#AllSearchStr  no
#AllUsers      no
#IndexAlias    home.htm
#IndexAlias    homepage.htm
#HideSite      *mrunix.net
#HideSite      localhost
#HideReferrer  mrunix.net/
#HideReferrer  Direct Request
HideURL        *.gif
HideURL        *.GIF
HideURL        *.jpg
HideURL        *.JPG
HideURL        *.png
HideURL        *.PNG
HideURL        *.ra
#HideAgent      RealPlayer
#HideUser      root
#HideUser      admin
#GroupURL      /cgi-bin/*      CGI Scripts
#GroupURL      /images/*      Images
#GroupSite      *.aol.com
#GroupSite      *.compuserve.com
#GroupReferrer  yahoo.com/      Yahoo!
#GroupReferrer  excite.com/    Excite
#GroupReferrer  infoseek.com/  InfoSeek
#GroupReferrer  webcrawler.com/ WebCrawler
#GroupUser      root            Admin users
#GroupUser      admin          Admin users
#GroupUser      wheel          Admin users
#GroupAgent    MSIE            Micro$oft Internet Exploder
#HideAgent      MSIE
#GroupAgent    Mozilla        Netscape
#HideAgent      Mozilla
#GroupAgent    Lynx*          Lynx
#HideAgent      Lynx*
#HideAllSites  no
#GroupDomains  0
#GroupShading  yes
#GroupHighlight yes
#IgnoreSite    bad.site.net
#IgnoreURL      /test*
#IgnoreReferrer file:/*
#IgnoreAgent    RealPlayer
#IgnoreUser    root
#IgnoreURL      *
#IncludeURL    ~joeuser*
#IgnoreUser    *
#IncludeUser    someuser
#MangleAgents    0
SearchEngine    yahoo.com      p=
SearchEngine    altavista.com  q=
SearchEngine    google.com      q=
SearchEngine    eureka.com      q=
SearchEngine    lycos.com      query=
SearchEngine    hotbot.com      MT=
SearchEngine    msn.com        MT=
SearchEngine    infoseek.com    qt=
SearchEngine    webcrawler      searchText=
SearchEngine    excite          search=
SearchEngine    netscape.com    search=
SearchEngine    mamma.com      query=
SearchEngine    alltheweb.com  query=
SearchEngine    northernlight.com  qr=
#DumpPath      /var/lib/httpd/logs
#DumpHeader    no
#DumpExtension  tab
#DumpSites      no
#DumpURLs      no
#DumpReferrers  no
#DumpAgents    no
#DumpUsers      no
#DumpSearchStr  no


Donboy 07-17-2004 09:25 PM

Quote:

I'm trying to figure out why it's telling me "DNS support not present, aborting..." when I did configure / compile it with DNS support.
I suspect that maybe it's not finding the right libraries for everything it needs. Notice in the webalizer FAQ in #18 that somebody submitted a fix that says it needs to be "db1" instead of what you used which was "db4". Where did you get the "db4" option to use in your configure line??? Just wondering why you picked that... must be something you found that's supposed to help.

Also, your config file is huge! Here's mine, which is typical of all the ones I have for each domain...

Code:

## Webalizer Config File
LogFile                        /home/username/www/logs/access.log.1.gz
OutputDir                /home/username/www/html/stats
HistoryName                /home/username/www/html/stats/webalizer.hist
IncrementalName                /home/username/www/html/stats/webalizer.current
Incremental                yes
HostName                domain.net
PageType                htm*
PageType                php*
PageType                pl
PageType                cgi
Quiet                        yes
HideURL                        *.gif
HideURL                        *.GIF
HideURL                        *.jpg
HideURL                        *.JPG
HideURL                        *.png
HideURL                        *.PNG


jnichel 07-17-2004 11:20 PM

Quote:

Originally posted by Donboy
I suspect that maybe it's not finding the right libraries for everything it needs.
I'm sure the problem lies along those lines somewhere, but where? Course, I wouldn't think it would configure, much less compile if libraries are missing.

Quote:

Originally posted by Donboy
Notice in the webalizer FAQ in #18 that somebody submitted a fix that says it needs to be "db1" instead of what you used which was "db4". Where did you get the "db4" option to use in your configure line??? Just wondering why you picked that... must be something you found that's supposed to help.
That's just where the DB files are installed for RHEL AS v3.0

Quote:

Originally posted by Donboy
Also, your config file is huge! Here's mine, which is typical of all the ones I have for each domain...
Just the sample config file shipped with Webalizer. I'll trim it if I can ever get it working.

Donboy 07-18-2004 01:41 AM

Well, in that case it beats me! If you've configured with those arguments and it still acts like you haven't, you may want to try the webalizer mailing list.

http://groups.yahoo.com/group/webalizer/

The author of the package is active on there so I'm sure you can get some good help there. I hate directing people away from LQ, but sometimes you gotta go to the source.

Sorry I couldn't help.

dablan 07-30-2004 08:13 PM

Sorry,

Did you find the solution, because i am having the same problem...

I hope yo read this...

Thanks,

Donboy 07-30-2004 08:49 PM

Hey! Welcome to LQ!

I think the root of jnichel's original problem is that he didn't want to allow DNS lookups on his machine. Is that also the case for you? Its probably none of my business, but I'm just curious about why you wouldn't want to allow lookups on a machine anyhow?

In post #3 jnichel seemed worried about causing additional load on his machine. I think it's safe to say that the load being put on a machine by webalizer isn't terribly much, and if you run it at 3am when things are quiet it's probably not going to cause your users much grief.

jnichel 07-30-2004 11:20 PM

Quote:

Originally posted by dablan
Sorry,

Did you find the solution, because i am having the same problem...

I hope yo read this...

Thanks,

I didn't find a solution. I finally just gave up, and started writing my own analyzer with php and MySQL. Not as full featured as Webalizer yet, but give me time. :D


All times are GMT -5. The time now is 08:53 PM.