Bug#917059: apt-listbugs: New error message /etc/cron.daily/apt-listbugs: logname: no login name

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Bug#917059: apt-listbugs: New error message /etc/cron.daily/apt-listbugs: logname: no login name

Alex Gould
Package: apt-listbugs
Version: 0.1.26
Severity: normal

Dear Maintainer,

After upgrade to the current version of apt-listbugs, I have been getting messages in my local mail from "Anacron job 'cron.daily'" to root:

/etc/cron.daily/apt-listbugs:
logname: no login name
logname: no login name
logname: no login name
logname: no login name
logname: no login name

I'm not sure what it means -- is apt-listbugs or anacron trying to run a process as a different user?

-- System Information:
Debian Release: buster/sid
  APT prefers testing
  APT policy: (500, 'testing')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 4.18.0-3-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), LANGUAGE=en_US (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages apt-listbugs depends on:
ii  apt             1.8.0~alpha2
ii  ruby            1:2.5.1
ii  ruby-debian     0.3.9+b8
ii  ruby-gettext    3.2.9-1
ii  ruby-soap4r     2.0.5-4
ii  ruby-unicode    0.4.4-2+b9
ii  ruby-xmlparser  0.7.3-3+b2

Versions of packages apt-listbugs recommends:
ii  ruby-httpclient  2.8.3-1
ii  s6               2.7.2.2-1

Versions of packages apt-listbugs suggests:
ii  firefox-esr [www-browser]  52.9.0esr-1
ii  konqueror [www-browser]    4:18.04.0-1+b2
ii  lynx [www-browser]         2.8.9rel.1-2
ii  reportbug                  7.5.1
ii  sensible-utils             0.0.12
ii  w3m [www-browser]          0.5.3-36+b1
ii  xdg-utils                  1.1.3-1

-- no debconf information

Reply | Threaded
Open this post in threaded view
|

Bug#917059: apt-listbugs: New error message /etc/cron.daily/apt-listbugs: logname: no login name

Francesco Poli (wintermute)
On Fri, 21 Dec 2018 17:11:56 -0800 Alex Gould wrote:

[...]
> Dear Maintainer,

Hello Alex,
thanks for your bug report!

>
> After upgrade to the current version of apt-listbugs, I have been getting messages in my local mail from "Anacron job 'cron.daily'" to root:
>
> /etc/cron.daily/apt-listbugs:
> logname: no login name
> logname: no login name
> logname: no login name
> logname: no login name
> logname: no login name
>
> I'm not sure what it means -- is apt-listbugs or anacron trying
> to run a process as a different user?
I am already aware of this bug.

It seems to only happen when anacron is in charge of running cron.daily
jobs (if cron.daily jobs are run by cron, the bug is not triggered).
In a nutshell, apt-listbugs/0.1.26 executes logname, but, for some
mysterious reason (maybe a bug in anacron? I have to investigate...),
when anacron runs cron jobs, it sets an environment where the logname
command fails (with the error message you are seeing).

Unfortunately I noticed the issue only after the upload of
apt-listbugs/0.1.26 to Debian unstable...
Sorry about that.


Anyway, this issue is harmless (the apt-listbugs cron.daily jobs works
correctly, despite spitting error messages), it is just annoying.

I have already worked around the issue and the next upload will include
the patch I prepared.


If the issue annoys you too much, you can manually apply the attached
patch directly to the installed apt-listbugs package, with the
following commands (run as root):

  # cd /usr/lib/ruby/vendor_ruby/aptlistbugs/
  # zcat /tmp/apt-listbugs_logname_bug.diff.gz | patch -p3

assuming you saved the attached patch in the /tmp directory.


Please let me know whether the patch succeeds in suppressing the
annoying error message.

Bye and thanks for your time.



--
 http://www.inventati.org/frx/
 There's not a second to spare! To the laboratory!
..................................................... Francesco Poli .
 GnuPG key fpr == CA01 1147 9CD2 EFDF FB82  3925 3E1C 27E1 1F69 BFFE

apt-listbugs_logname_bug.diff.gz (896 bytes) Download Attachment
attachment1 (849 bytes) Download Attachment