Closed jarretlavallee closed 3 years ago
@jarretlavallee Since these are standard Apache log format, we can probably use existing tools for this. For example, goaccess
works.
goaccess --log-format COMBINED logs/puppetserver/puppetserver-access.log
Is this or another tool suitable?
Introducing a tool to reduce the maintenance burden and increase the capabilities is a good idea. goaccess
is available in brew
on MacOS so it seems like an easy fit.
@coreymbe Thoughts on ^^
Sorry for the delayed response on this one @jarretlavallee.
Should this be counts per minute, or the raw display? I wouldn't mind seeing both of those to be honest. I can think of scenarios where I would be more interested in one over the other.
Of the requests here, I think the only thing goaccess
doesn't do is break down 500 errors by endpoint. That shouldn't be too hard to work into the script.
@jarretlavallee @coreymbe I've added this to a feature in my fork. Could you test it out and look for the access_log_errors
entry in the output? If it works ok I'll merge it into master. Here's how to test out the feature:
git remote add m0d git@github.com:m0dular/support-tooling.git
git fetch --all
git checkout aph/access-parse
@cwebster61083 Gives it the :+1:
Added in #14
Use Case
Add a section for each service for the errors in the access logs. These should be items like 404's, 503's, 500's, etc.
Additional Context
@coreymbe Should this be counts per minute, or the raw display?
Another consideration is that some 404s are expected. Such as when an agent is doing a cert request for the first time, we would expect there to be a 404 on the cert API call. So that could make this a little more complicated.