Re: Configurable log proposal

Kevin 'Kev' Hughes (kevinh@eit.COM)
Tue, 1 Feb 94 13:58:10 PST

Ari ( writes:

> How about having a fully configurable log files, something
> that would understand escapes like this:
> Time:
> %a abbreviated weekday name
> %b abbreviated month name
> %d day of month
> ...
> ...and what else? I would be happy to implement this. Maybe the %letters
> could be selected in a better way and not respect the ones strftime()
> uses.

I really like the idea - in a log analyzing program, the user
can define their log format in some sort of format string, and all
that's needed is some sort of generic sscanf() function. Once something is
agreed upon, I'll certainly (try to) write one for my analyzer.
How about escapes for a status flag, such as

Whether a file/script was found
Unknown failure
Successful (appears to have sent the request)

...and breaking down the request pathname (full, url, or partial),
and one generic escape for miscellaneous (unknown) data known only to the
server. This would allow a person to define by escapes logs like: [Sat Oct 30 00:17:42 1993] GET /help/modem.html HTTP/1.0

(site, date, method, partial path, protocol) [Sat Oct 30 00:17:42 1993] GET HTTP/1.0

(site, date, method, url, protocol) [Sat Oct 30 00:17:42 1993] HEAD /usr/local/www/help/modem.html HTTP/1.0

(site, date, method, full path, protocol) Sent cache (GET /1/mathdir): Sun Oct 31 11:44:12 1993 Sent binary (GET /9/newton.gif): Sun Oct 31 12:26:42 1993

(site, miscellaneous data, method, partial path, date)

-- Kevin