[rabbitmq-discuss] RabbitMQ log rotation problem with large log file

Emile Joubert emile at rabbitmq.com
Thu Jun 14 13:04:56 BST 2012


Hi,

On 13/06/12 19:40, Chen, Bin wrote:
> The servers have been running for several months. The log files are over
> 16 GB now.

I've observed that the broker consumes RAM according to the size of the
logfile during rotation, so it seems likely that the logfile is read
into memory in its entirety. I will file a bug to reduce the memory
requirements during log rotation, but in the meantime you will need to
rotate logs often enough that they fit in available RAM.

> If you know some way to solve this problem without shutting down the
> server, please let me know.

It might be possible by turning logging off and back on using the
underlying error_logger
(http://www.erlang.org/doc/man/error_logger.html) and the "rabbitmqctl
eval" command, but this is unsupported and you risk losing messages
generated during the procedure. I recommend instead that you shut down
the broker.




-Emile



More information about the rabbitmq-discuss mailing list