Logging to DB
Anton Yuzhaninov
citrin at citrin.ru
Tue Jun 7 15:21:20 MSD 2011
On 06/07/11 01:17, John Macleod wrote:
> Is there any tried and tested way to log to a database?
>
> There appears to be several options using fifo, syslog, etc floating
> around, however, there seems to be some issues with certain options.
how to do this depend on acceptable delay.
If you need nearly real time info in DB:
tail -F /var/log/access.log | /path/to/writer_logs_to_db
If several minutes lag is acceptable, you can rotate logs and then load full log
in single transaction.
--
Anton Yuzhaninov
More information about the nginx
mailing list