On Tue, Jan 22, 2013 at 1:34 PM, Michael C. Toren <span dir="ltr"><<a href="mailto:mct@toren.net" target="_blank">mct@toren.net</a>></span> wrote:<br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div class="im">On Tue, Jan 22, 2013 at 01:57:55AM -0800, Jonathan Lassoff wrote:<br>
> Maybe we should rotate or truncate the log after a while? Seems like<br>
> we're collecting info on users' comings and goings, and there's no real<br>
> reason to keep that forever.<br>
<br>
</div>Yes, we should totally do that. We definitely do not want to keep the<br>
baron logfile around for very long.<br>
<br>
In addition to the su stuff I mentioned elsewhere in this thread, I just<br>
changed /etc/init/baron.conf to include the line "console log", and to<br>
remove the "--logfile" argument that's passed to baron. This redirects<br>
stdout and stderr to /var/log/upstart/<job-name>. There's some existing<br>
mechanism in Debian that rotates files in that directory, but I don't know<br>
offhand where it's configured. We'll want to find it, and tweak it so that<br>
it only saves N days of logs.<br></blockquote><div><br></div><div>It's /etc/logrotate.d/upstart, which says:</div><div><br></div><div>/var/log/upstart/*.log {</div><div> daily</div><div> missingok</div>
<div> rotate 7</div><div> compress</div><div> notifempty</div><div><span class="Apple-tab-span" style="white-space:pre"> </span>nocreate</div><div>}</div><div><br></div><div>So, it's a week's worth, rotating daily.</div>
<div>Seems fine to me.</div><div><br></div><div>Nice work!</div><div><br></div><div>--j</div></div>