<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">Hi,</div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;"> </div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">as far as I know I cannot configure Dovecot to pipe the rawlog into rsyslog. Or can I, how?</div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;"> </div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">The rawlog feature in Dovecot writes multiple files (two for each connection, one for raw requests and one for raw responses) into a predefined directory for the user. This generates dozens or hundreds of files per user per day, each file with a timestamp in it, so the filename is not predictable.</div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;"> </div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">Even if it works, I'm not sure if syslog (rsyslog or syslog-ng) should be (ab)used to collect the rawlog file contents, which might be hundreds of MB per minute if someone FETCHes all his emails while setting up a new account in Thunderbird or so. That sounds like a suboptional idea. Syslog cannot handle binary text I guess, and it might have limits like "line length limits" or similar. It sounds like the wrong tool for the job.</div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;"> </div>
<div style="font-family: arial, helvetica,sans-serif; font-size: 12pt; color: #000000;">Michael</div>
</div>
<div><br /><br />Am 28-Jul-2022 15:28:16 +0200 schrieb dovecot@ptld.com:</div>
<blockquote style="margin-left: 0; padding-left: 5px; border-left: 2px solid navy;">> I'm searching for a possibility to have the rawlog feature in lua, which would be much easier for processing. <br />> <br />> It would be much easier to hook to the "raw request and response events" inside Dovecot and have the rawlog-data in a lua script,<br />> where I can prepare it and send it to another maschine for monitoring/collection/analysis/statistics or similar, for example via HTTP. <br /><br /><br />rsyslog has this feature (omprog) allowing you to setup any script/program for it to pipe logs to in real time.<br /><br /><a href="https://www.rsyslog.com/doc/master/configuration/modules/omprog.html" target="_blank" rel="noreferrer noopener">https://www.rsyslog.com/doc/master/configuration/modules/omprog.html</a><br /><a href="https://github.com/rsyslog/rsyslog/blob/master/plugins/external/INTERFACE.md" target="_blank" rel="noreferrer noopener">https://github.com/rsyslog/rsyslog/blob/master/plugins/external/INTERFACE.md</a><br /><br />Works similar in concept to postfix policy servers if you are familiar with them.</blockquote>