allinurl / goaccess

GoAccess is a real-time web log analyzer and interactive viewer that runs in a terminal in *nix systems or through your browser.
https://goaccess.io
MIT License
18.52k stars 1.11k forks source link

GoAccess not showing 'Tx.' Amount #2760

Open pjgerardo opened 1 day ago

pjgerardo commented 1 day ago

Hi all

I'm testing GoAccess to read Wasabi bucket logs that supposedly are equal to AWS S3 logs so I'm using the "--log-format awss3" option. Everything works great, but the one thing missing is the bandwidth amount the actual data I want to check 😄

Is there anything specific I should check as to why it won't show the bandwidth?

Here are a few example lines:

Record format: [BucketOwner Bucket Time RemoteIP Requester RequestId Operation Key Request-URI HttpStatus ErrorCode BytesSent ObjectSize TotalTime Turn-Around
546858E6E300000000000000000000000000000000000000000000000000DC170 bucket-name [06/Aug/2024:16:37:48 +0000] 109.50.101.102 546858E6E300000000000000000000000000000000000000000000000000DC170 BE95910000C4743B:A REST.HEAD.OBJECT preseed%2Fubuntu.seed "HEAD /preseed/ubuntu.seed" 404 NoSuchKey - 0 6 0 "" "MSP360/Wasabi Explorer/6.2.2" -
546858E6E300000000000000000000000000000000000000000000000000DC170 bucket-name [06/Aug/2024:16:37:48 +0000] 109.50.101.102 546858E6E300000000000000000000000000000000000000000000000000DC170 78DF800008286EE7:A REST.HEAD.OBJECT EFI%2Fboot%2Fbootx64.efi "HEAD /EFI/boot/bootx64.efi" 404 NoSuchKey - 0 4 4 "" "MSP360/Wasabi Explorer/6.2.2" -
546858E6E300000000000000000000000000000000000000000000000000DC170 bucket-name [06/Aug/2024:16:37:48 +0000] 109.50.101.102 546858E6E300000000000000000000000000000000000000000000000000DC170 1F45D000085389F8:A REST.PUT.OBJECT preseed%2Fubuntu.seed "PUT /preseed/ubuntu.seed" 200 - - 460 109 0 "" "MSP360/Wasabi Explorer/6.2.2" -
546858E6E300000000000000000000000000000000000000000000000000DC170 bucket-name [06/Aug/2024:16:37:49 +0000] 109.50.101.102 546858E6E300000000000000000000000000000000000000000000000000DC170 FBCCB00003E9E20E:A REST.HEAD.OBJECT boot%2Fgrub%2Fx86_64-efi%2Fadler32.mod "HEAD /boot/grub/x86_64-efi/adler32.mod" 404 NoSuchKey - 0 3 0 "" "MSP360/Wasabi Explorer/6.2.2" -
546858E6E300000000000000000000000000000000000000000000000000DC170 bucket-name [06/Aug/2024:16:37:49 +0000] 109.50.101.102 546858E6E300000000000000000000000000000000000000000000000000DC170 71D310000F00E8B2:A REST.PUT.OBJECT boot%2Fgrub%2Fx86_64-efi%2Fadler32.mod "PUT /boot/grub/x86_64-efi/adler32.mod" 200 - - 1952 68 30 "" "MSP360/Wasabi Explorer/6.2.2" -
allinurl commented 16 hours ago

So, is BytesSent equivalent to 'bandwidth'? It looks like they’re all showing as 0 in that sample log.

This should do it (assumes certain fields, e.g., TotalTime).

goaccess access.log --log-format='%^ %v [%d:%t %^] %h %^"%m %U" %s %e %b %^ %L %^"%^" "%u"' --date-format=%d/%b/%Y --time-format=%T --http-protocol=no

If it's the objectsize, you could try:

goaccess access.log --log-format='%^ %v [%d:%t %^] %h %^"%m %U" %s %e %^ %b %L %^"%^" "%u"' --date-format=%d/%b/%Y --time-format=%T --http-protocol=no