On 3 Sep 2002, Erwien Samantha Y wrote:
> hello guys,
> can you help me with mergelogs command?
> i already try , but no result.
> i have balancing my 3 web server using pen. But now i have work with
> webserver statistics.
> my webserver :
> webA ----> 10.32.10.26:83
> webB ----> 10.32.10.29:80
> webC ----> 10.32.10.32:80
> Pen server -----> 10.32.10.26 :80
> ps.all server time are synchronized. (GMT)
> to produce a web logfile that i can use for my web statistics i have to
> use mergelogs rite?
> mergerlogs -p /www/logs/pen.log 10.32.10.26:access_log.26
> 10.32.10.29:access-log.29 10.32.10.32:access_log.32
> and i got this error
> "Can't open logfile 'access_log.26'
It means that access_log.26 doesn't exist. Before you run mergelogs, you
must get the logs from all web servers. In your example, something like
scp 10.32.10.26:/usr/local/apache/logs/access_log access_log.26
scp 10.32.10.29:/usr/local/apache/logs/access_log access_log.29
scp 10.32.10.32:/usr/local/apache/logs/access_log access_log.32
But I actually recommend that you don't use mergelogs at all. My own
experience is that it is a PITA to rotate and transfer the logs on a bunch
of web servers. That's the reason behind penlog and penlogd, which
sends the logs over the network to a single place where they are
automatically merged. See the manpages for penlog and penlogd, and also
Penlog[d] are useful even if other load balancers are being used, which
often ignore the logging problem completely. In fact, they can be used for
standalone web servers in order to get logs into a central place.
Here's the relevant line from httpd.conf here at siag.nu:
CustomLog "|/usr/local/bin/penlog alphabob 10000 siagweb" combined
And here's the command to start penlogd:
/usr/local/bin/penlogd -j /home/ulric/webalizer -u ulric \
-l /access_log -p /penlogd.pid 10000
This archive was generated by hypermail 2.1.2 : Tue Sep 03 2002 - 09:02:06 CEST