Francis Daly
September 04, 2018 03:22AM
On Mon, Sep 03, 2018 at 09:26:42AM -0400, prajos wrote:

Hi there,

> I'm wondering if there is a ready way to add a checksum (e.g. CRC) to the
> end of each log entry before they get written to the "access" or "error" log
> files?

I believe that stock nginx does not include a way to do that.

> One of the project I work on wants each log line to have its own
> checksum for some integrity checks.

What kind of corruption is the checksum intended to protect against?

The answer to that might help determine a suitable design for a solution
for you.

> Any hint on how I can implement these would be of great help.

If it is acceptable to be outside nginx, you could have something that
post-processed the logs to add whatever marks you want.

Or maybe you could write nginx logs to a named pipe, and have another
process do whatever you want before writing to "real" disk.

Good luck with it,

f
--
Francis Daly francis@daoine.org
_______________________________________________
nginx mailing list
nginx@nginx.org
http://mailman.nginx.org/mailman/listinfo/nginx
Subject Author Posted

add checksum to nginx log entries

prajos September 03, 2018 09:26AM

Re: add checksum to nginx log entries

Francis Daly September 04, 2018 03:22AM



Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 268
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready