Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reduce logging or number of stored logs #8

Open
153957 opened this issue Apr 20, 2015 · 4 comments
Open

Reduce logging or number of stored logs #8

153957 opened this issue Apr 20, 2015 · 4 comments

Comments

@153957
Copy link
Member

153957 commented Apr 20, 2015

frome now has log level set to DEBUG for the writer and uwsgi processes. With the new PySPARC stations that upload every event individually this causes a lot of extra log messages. We should set the log level to INFO. Or, alternatively, instead of reducing the log level, reduce the number of logs kept by the TimedRotatingFileHandler..

Recently frome was having issues accepting new events due to a full partition, caused by the large logs..

@153957
Copy link
Member Author

153957 commented Apr 20, 2015

The excess of hisparc.log-wsgi logs is caused by wsgi_app#L107.
This appends the current PID to the log file, which makes it unable to find the old logs to remove.

We could also solve this by running a cron job which removes old files, similar to the cron job on the publicdb to remove old .h5 files downloaded using sapphire.publicdb

@153957
Copy link
Member Author

153957 commented Mar 4, 2016

Something like:
find /var/log/hisparc/ -mtime +100 -delete

@tomkooij
Copy link
Member

tomkooij commented Mar 4, 2016

Rotating logfiles can (should?) be handled by syslogd or logrotate(8) or something.

That would be much easier to manage in the future.

@davidfokkema
Copy link
Member

Yes, well... In the future, we should use something more manageable like uWSGI instead of Apache. Then everything can end up in one log, with pid in the log message. uWSGI can also automatically rotate logs, I believe.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

3 participants