E
E
edik892016-06-04 16:01:12
Nginx
edik89, 2016-06-04 16:01:12

How to make it so that data is written to access.log for a month?

Asked to provide entries from access.log for the last month. Looked settings, found the necessary folder. Only records for the last few days are stored there. How to make sure that the logs are stored for a month? In office Didn't find any documentation.

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dimonchik, 2016-06-04
@edik89

https://www.nginx.com/resources/wiki/start/topics/...
https://www.digitalocean.com/community/tutorials/h...

A
Andrey Shatokhin, 2016-06-04
@Sovigod

You obviously have logrotate installed and running. Its settings are in /etc/logrotate.conf - there you can change the rules for triggering log rotation. Change weekly to monthly. This will help if you have few logs. Otherwise, they will be rotated upon reaching the specified size.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question