[Bug 1832886] Re: 50-motd-news always called with --force
Steve Langasek
steve.langasek at canonical.com
Fri Jun 14 18:29:46 UTC 2019
No. The --force option is passed when called from the service. It is
NOT passed when the script is called via update-motd during login.
** Changed in: base-files (Ubuntu)
Status: New => Invalid
--
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to base-files in Ubuntu.
https://bugs.launchpad.net/bugs/1832886
Title:
50-motd-news always called with --force
Status in base-files package in Ubuntu:
Invalid
Bug description:
I was looking at the motd-news.service file and 50-motd-news recently
and discovered that 50-motd-news is always called with --force.
bdmurray at clean-disco-amd64:~$ systemctl cat motd-news.service
# /lib/systemd/system/motd-news.service
[Unit]
Description=Message of the Day
After=network-online.target
Documentation=man:update-motd(8)
[Service]
Type=oneshot
ExecStart=/etc/update-motd.d/50-motd-news --force
However, 50-motd-news leads one to believe that it would be faster if
it were not called with --force.
"
# If we're not forcing an update, and we have a cached motd-news file,
# then just print it and exit as quickly as possible, for login performance.
# Note that systemd should keep this cache file up to date, asynchronously
if [ "$FORCED" != "1" ]; then
if [ -r $CACHE ]; then
echo
safe_print $CACHE
else
: > $CACHE
fi
exit 0
fi
"
So is login performance being degraded since 50-motd-news is always
called with --force?
To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/base-files/+bug/1832886/+subscriptions
More information about the foundations-bugs
mailing list