I've been using forever for a long time but recently it started to behave a little bit weird: everything is ok except for the logs.
I used to run
forever start /path/to/app.js
and everything was fine. Even for huge logs (1-2 gigs).
But I currently have an app, a very busy web app and the log is being truncated every 3-4 hours. The size is not that big, 80-120 megs actually.
After realising this I decided to try (unsuccessfully though) starting forever with options:
forever --append -o /path/to/out.log -e /path/to/error.log start /path/to/app.js
but the problem persists.
I really don't know what to do.
- node v0.12.7
- npm 2.11.3
- forever v0.15.1
- 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt11-1+deb8u6 (2015-11-09) x86_64 GNU/Linux
- BTW: I have plenty of hard disk an memory available
I found a related Issue (https://github.com/foreverjs/forever/issues/106#issuecomment-116933382
) and beging testing with the following command:
forever -a -l >(logger -t fileteTrackchile) start /path/to/app.js
So far so good, but it will store log information in
. It's the same information so it would be better to save it only once.
I'll leave it running for a couple of days and see if it works or not.
The problem had nothing to do with forever, nor winston. I didn't realise that the files were so big that the log viewer was only showing part of it. The confusing part is that the first line (past) was truncated by the viewer (OSX Console) what led me to think that the file itself was truncated.