# Log rotation on windows?

**URL:** <https://www.ruby-forum.com/t/log-rotation-on-windows/193723>\
**Category:** NGINX\
**Created:** [August 23, 2010, 3:01pm UTC](https://www.ruby-forum.com/t/log-rotation-on-windows/193723 "2010-08-23T15:01:43Z")\
**Posts on this page:** 1\
**Page:** 2

<div class="post-metadata">

**Author:** ![ruhtra01](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/r/76d3ee/32.png) [@ruhtra01](https://www.ruby-forum.com/u/ruhtra01)\
**Post date:** [August 25, 2010, 7:21pm UTC](https://www.ruby-forum.com/t/log-rotation-on-windows/193723/21 "2010-08-25T19:21:42Z")

</div>

Hi

On Wed, Aug 25, 2010 at 13:06, Arthur B. [removed\_email\_address@domain.invalid](mailto:removed_email_address@domain.invalid)  
wrote:

> Â On Linux, which command is better to rotate log files?

The Debian package installs this file: /etc/logrotate.d/nginx:  
/var/log/nginx/\*.log {  
daily  
missingok  
rotate 52  
compress  
delaycompress  
notifempty  
create 640 www-data adm  
sharedscripts  
postrotate  
[! -f /var/run/nginx.pid] || kill -USR1 `cat /var/run/nginx.pid`  
endscript  
}

So, in this case, kill. logrotate gets run by cron every now and then,  
your only concern is cleaning logfiles (if your disk is small).

HTH,  
Nuno

[Previous page](https://www.ruby-forum.com/t/log-rotation-on-windows/193723.md?page=1)
