Goaccess: Seemingly incorrect hit percentage

Created on 18 May 2019  Â·  5Comments  Â·  Source: allinurl/goaccess

Hi — I'm not sure if this is a bug or just something I'm not understanding. I'm using GoAccess 1.3.

I've got everything seemingly working, except the "h%" column shows "100%" for the first line within each module. Is that the correct behavior? The screenshots on the homepage don't show that, so I'm assuming not.

Shouldn't the first row in "Requested Files" have a h% value of 32.78% (19536 Hits/59604 Valid Requests) rather than 100%?

Could it be something like each module is using the value from the topmost row as the denominator instead of Valid Requests? Because that would line up (e.g., 19536/19536 = 100%, 7753/19536 = 39.69%, etc.)

If that's the intended behavior, is there any way to change it to use Valid Requests as the denominator? I didn't see anything in the man page about it or any Github issues.

(I'm using --log-format COMBINED on the default nginx combined format here, but it also occurs with custom date/time/log formats.)

Thanks in advanced for any help/insight you can provide!

Screen Shot 2019-05-18 at 10 53 22 AM

log-processing question

Most helpful comment

You are right. This is based on the topmost row of each panel. #649 addressed this. However, I'm trying to find who requested this. To be honest, I find it odd as well when I looked at my stats. Originally was done as you expected, based of valid requests and then changed. I may need to revert this or add some sort of option...

All 5 comments

You are right. This is based on the topmost row of each panel. #649 addressed this. However, I'm trying to find who requested this. To be honest, I find it odd as well when I looked at my stats. Originally was done as you expected, based of valid requests and then changed. I may need to revert this or add some sort of option...

Yeah, this behavior is extremely weird, and basically renders percentages useless as far as I can tell. It makes sense to calculate hit percentages based on total number of hits, but as far as I can tell it is not going by total number of hits but instead by the first row of the table.

For example, here I am sorting by hits:

image

And here I am sorting by visitors:

image

The raw numbers stay the same, but the percentages change based on which row comes first.

Looking at the full table:

image

The total hits is 32,322 (summing all the values for Hits) and total visitors is 2,299 (summing all the values for Vis.). Based on this, I would expect Chrome to be 10467/32322 = 32.38% of hits, and 614/2299 = 26.71% of visitors, regardless of how the list is sorted.

Note that Valid Requests is a different number completely and I don't think it should factor into these percentages.

By the way, I'm using the latest release, 1.3.

Any updates on this? It makes stats useless or maybe hard to understand.

@ank-everstake I already have a working copy of this, I'll push it over the weekend. Stay tuned.

This has been reverted back to its original behavior per this commit.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

ArunDahiya1 picture ArunDahiya1  Â·  3Comments

canepa picture canepa  Â·  3Comments

konungrl picture konungrl  Â·  3Comments

deosha picture deosha  Â·  3Comments

eroldru picture eroldru  Â·  3Comments