I can't say for sure, but it sounds like an IO sync
issue. I/O is generally buffered for speed. RAM is a lot faster than disks, so reads and writes are temporarily stored until the data is requested by the code, or the disk is able to receive it. Ruby's IO class has the sync=
method that lets you tell Ruby to immediately flush the buffer on a write.
This should work:
logger_file = open('/mnt/dbsdata/output.log', File::WRONLY | File::APPEND | File::CREAT)
logger_file.sync = true
LOGGER = Logger.new(logger_file)
LOGGER.level = Logger::INFO
For simplicity, you can create the correct mode you want for your output using:
logger_file = File.open('/mnt/dbsdata/output.log', 'a')