landscape-common shows erroneous MOTD on install

Bug #1745347 reported by Alan Pope 🍺🐧🐱 🦄
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
landscape-client (Ubuntu)
Expired
Undecided
Unassigned
update-notifier (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

I was just updating my system via apt, and got this in the middle of the update.

Why is it telling me about 14.04 updates, I'm on 18.04.

Setting up landscape-common (16.03-0ubuntu5) ...
Welcome to Ubuntu Bionic Beaver (development branch) (GNU/Linux 4.13.0-25-generic x86_64)

 * Documentation: https://help.ubuntu.com
 * Management: https://landscape.canonical.com
 * Support: https://ubuntu.com/advantage

 System information disabled due to load higher than 2.0

78 packages can be updated.
0 updates are security updates.

WARNING: Security updates for your current Hardware Enablement
Stack ended on 2016-08-04:
 * http://wiki.ubuntu.com/1404_HWE_EOL

There is a graphics stack installed on this system. An upgrade to a
configuration supported for the full lifetime of the LTS will become
available on 2016-07-21 and can be installed by running 'update-manager'
in the Dash.

Setting up libmatekbd4:amd64 (1.18.2-3) ...

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: landscape-common 16.03-0ubuntu5
ProcVersionSignature: Ubuntu 4.13.0-25.29-generic 4.13.13
Uname: Linux 4.13.0-25-generic x86_64
ApportVersion: 2.20.8-0ubuntu6
Architecture: amd64
CurrentDesktop: MATE
Date: Thu Jan 25 10:38:43 2018
InstallationDate: Installed on 2014-11-04 (1177 days ago)
InstallationMedia: Ubuntu MATE 14.04.1 "Trusty Tahr" - dev.30817 amd64 (20141104)
SourcePackage: landscape-client
UpgradeStatus: Upgraded to bionic on 2016-04-13 (651 days ago)

Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) wrote :
Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Hello,

I don't think what you saw came from landscape. The bit that landscape-sysinfo spits out to the motd is this:

 System information disabled due to load higher than 2.0

I don't know why you got the whole motd during the package install as if you had logged in, but the landscape bit is just that line above. The rest comes from many different scripts in /etc/update-motd.d

Why all that got displayed mid-apt upgrade does sound wrong. Maybe the bug got triggered by landscape because it does install a script in /etc/update-motd.d. I'm adding a bug task for update-notifier.

Changed in landscape-client (Ubuntu):
status: New → Incomplete
Revision history for this message
Alan Pope 🍺🐧🐱 🦄 (popey) wrote :

I actually did apt-get install landscape-common --reinstall to confirm it was something triggered as part of that package install. So while it might be something else landscape-common calls, it's definitely landscape-common triggering it, not some other thing during my upgrade.

Revision history for this message
Andreas Hasenack (ahasenack) wrote :

Can you try a reinstall of some of the other packages that have files in that directory? For example, on my system:

$ dpkg -S /etc/update-motd.d/*
base-files: /etc/update-motd.d/00-header
base-files: /etc/update-motd.d/10-help-text
base-files: /etc/update-motd.d/50-motd-news
update-notifier-common: /etc/update-motd.d/90-updates-available
ubuntu-release-upgrader-core: /etc/update-motd.d/91-release-upgrade
update-notifier-common: /etc/update-motd.d/95-hwe-eol
update-notifier-common: /etc/update-motd.d/98-fsck-at-reboot
update-notifier-common: /etc/update-motd.d/98-reboot-required

If you install ubuntu-advantage-tools, I think you will get an ESM motd as well. It won't display anything on ubuntu (as it's precise only), but should place another file in that directory and may trigger this behavior too.

Revision history for this message
Steve Langasek (vorlon) wrote :

This is the existing behavior of update-motd from the update-motd package, unchanged since 2009, which does the following:

if run-parts --lsbsysinit /etc/update-motd.d > /var/run/motd.new; then
        if mv -f /var/run/motd.new /var/run/motd; then
                cat /var/run/motd
                exit 0
        else
                echo "ERROR: could not install new MOTD" 1>&2
                exit 1
        fi
fi

So the update-motd command installs the new motd, and then cats it to stdout.

landscape-common should not need to call update-motd as part of the maintainer script, as the rest of the system is intended to ensure the dynamic motd shown at login is always current.

Changed in update-notifier (Ubuntu):
status: New → Invalid
Revision history for this message
Launchpad Janitor (janitor) wrote :

[Expired for landscape-client (Ubuntu) because there has been no activity for 60 days.]

Changed in landscape-client (Ubuntu):
status: Incomplete → Expired
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.