rsyslog from Heroku drain creates empty log files

Posted by Jeff Lee on Server Fault See other posts from Server Fault or by Jeff Lee
Published on 2012-04-04T21:50:15Z Indexed on 2012/04/04 23:32 UTC
Read the original article Hit count: 314

Filed under:
|
|

I'm sending logs from my Heroku app to an rsyslog server, but the resulting log files seem to come up empty. The rsyslog configuration for receiving remote messages is as follows:

$template RemoteDailyLog,"/var/log/remote/%hostname%/%$year%/%$month%/%$day%.log"
:fromhost-ip, !isequal, "127.0.0.1" -?RemoteDailyLog
& ~

My complete rsyslog configuration is available in this paste.

This configuration appears to create the directories correctly. I see the Heroku app's logging hostname (of the form "d.xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx") appear in /var/log on the rsyslog host, which implies that log messages are successfully making it to the logging daemon, but the resulting logfiles are zero-size.

I'm guessing the issue is with rsyslog, rather than Heroku, but I'm not sure where to look next.

© Server Fault or respective owner

Related posts about logging

Related posts about rsyslog