Hi,

When running `apt-get upgrade` via a cron job, there is a "Reading database" 
section.

In the email this appears as:

> (Reading database ...
> (Reading database ... 5%
> (Reading database ... 10%
> (Reading database ... 15%
> (Reading database ... 20%

Where the first "Reading database" line ends with a "\r" only (the others are 
fine).

It's not a major issue, as it just breaks DKIM signing of emails; where the 
"\r" is changed to a "\r\n" after the DKIM signature has been added.

I've been informed by Julian Klode that this relates to `dpkg`:

https://github.com/Debian/apt/issues/37 
<https://github.com/Debian/apt/issues/37>

And at a guess, I think it's due to:

https://anonscm.debian.org/cgit/dpkg/dpkg.git/tree/lib/dpkg/progress.c#n43 
<https://anonscm.debian.org/cgit/dpkg/dpkg.git/tree/lib/dpkg/progress.c#n43>

---

Just for reference, two alternative ways of fixing this include:

1) Use `FixCRLF yes` in the OpenDKIM config.

2) Use `apt-get upgrade -q`, which is a quiet mode which "produces output 
suitable for logging, omitting progress indicators".

Craig

Reply via email to