keymetrics / pm2-logrotate

Automatically rotate all applications logs managed by PM2
1.24k stars 139 forks source link

`pm2 set pm2-logrotate:max_size 1K` doesn't work, logs are not rotated #174

Open pubmikeb opened 3 years ago

pubmikeb commented 3 years ago

I set pm2 set pm2-logrotate:max_size 1K and expect that log will be rotated (flushed) every time log file reaches 1 KB but in fact it doesn't happen.

Perhaps, related to https://github.com/keymetrics/pm2-logrotate/issues/169.

JxJPu9bD commented 1 year ago

max_ size applies to the size of a single file. You should also set the value of retain, but this setting does not take effect on my Windows Server

nguyenngoc2505 commented 9 months ago

This settings doesn't works with me too. I've set 10G but it always rotate by default config (10M) zzz