From: Xavier Date: 2004-05-01T07:14:10+09:00 Subject: logger.rb does not rotate files properly I thought I'd mention that logger.rb does not rotate log files after it has already rotated once. It does not set the sync flag to true when it creates a new log file which means the stat.size call will always return 0 after the first rotation. The following patch solves this issue: $ diff -Nut /usr/lib/ruby/1.8/logger.rb ./logger.rb --- /usr/lib/ruby/1.8/logger.rb 2004-02-07 11:05:12.000000000 +0100 +++ ./logger.rb 2004-04-14 20:55:25.617250444 +0200 @@ -539,6 +539,7 @@ def create_logfile(filename) logdev = open(filename, (File::WRONLY | File::APPEND | File::CREAT)) + logdev.sync = true add_log_header(logdev) logdev end hth