On Thu, Oct 30, 2014 at 06:49:32PM +0100, Andreas Cadhalpun wrote:
> Control: retitle -1 journald: does not respect carriage return
> Control: reassign -1 systemd 215-5+b1
> 
> Hi Santiago,
> 
> On 30.10.2014 13:12, Santiago Vila wrote:
> >freshclam[7495]: Downloading daily-19559.cdiff [ 45%]#015Downloading
> >daily-19559.cdiff [ 61%]#015Downloading daily-19559.cdiff [ 
> >77%]#015Downloading daily-19559.cdiff [
> >93%]#015Downloading daily-19559.cdiff [100%]#015Downloading 
> >daily-19559.cdiff [100%]
> >
> >A percentage or a progress bar in a log file does not make much sense.
> >This should be better replaced by just two messages.
> >
> >Download start.
> >Download end.
> 
> This only shows up in /var/log/syslog.
> 
> freshclam's own log file, /var/log/clamav/freshclam.log correctly
> only contains the last part, i.e. 'Downloading daily-19559.cdiff
> [100%]', just as it would appear on the terminal.
> 
> The problem is that the systemd journal does not respect the
> carriage return '\r' by deleting the current line content, but
> rather continues to append the message.
> In 'journalctl -u clamav-freshclam' this output is suppressed as
> 'freshclam[2421]: [1.6K blob data]', but it is still forwarded to
> syslog and there the carriage return is replaced with '#015'.
> 
> The fix for this would be for journald to correctly interpret the
> carriage return. Therefore I'm reassigning this bug to systemd.
Nope, there's no place for '\r' in logs. It only makes sense on
a console, where you show something and then erase it some time
later when the situation changes. Log file viewers don't show
logs in real time, so any usage of erase characters should be
replaced by simply logging the final version in the first place.

Zbyszek


-- 
To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to