/etc/update-motd.d scripts fail to run if camel case

Bug #1348455 reported by Jonathan
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
debianutils (Ubuntu)
New
Undecided
Unassigned

Bug Description

This could either be in libpam0g or libpam0g-modules, not sure.

 I have a fresh Ubuntu 14 install with the latest pam_motd. I added a cool shell
script in /etc/update-motd.d/99-coolStuff

Verified correct syntax. doing a run-parts . from that dir gave me correct results. But the correct results didn't show up when logging in. Eventually I figured out camel casing the file name breaks pam_motd. :(

99-coolstuff works fine from login.

Not sure if this is by design, but run-parts didn't care and I thought this emulated the behavior of that package- at least that's what your documentation says. Speaking of docs- there is SO much stale info about the old update-motd package out there that it took an obnoxious amount of time to figure out what package this was in. An update to this man page saying it isn't done in cron and update-motd has been superseded by this would be good.

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: libpam0g 1.1.8-1ubuntu2
ProcVersionSignature: Ubuntu 3.13.0-24.46-generic 3.13.9
Uname: Linux 3.13.0-24-generic x86_64
ApportVersion: 2.14.1-0ubuntu3.2
Architecture: amd64
Date: Thu Jul 24 19:45:07 2014
InstallationDate: Installed on 2014-07-24 (0 days ago)
InstallationMedia: Ubuntu-Server 14.04 LTS "Trusty Tahr" - Release amd64 (20140416.2)
SourcePackage: pam
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
Jonathan (fatal-exception) wrote :
Revision history for this message
Jonathan (fatal-exception) wrote :

Also the man page for pam_motd has incorrect author info.

AUTHOR
       pam_motd was written by Ben Collins <email address hidden>.

Email address bounces.

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

> Not sure if this is by design, but run-parts didn't care and I thought
> this emulated the behavior of that package- at least that's what your
> documentation says.

It's not by design. But I also don't think it's a bug in pam_motd, but in
run-parts itself. pam_motd invokes run-parts with --lsbsysinit, which is
documented as:

       If the --lsbsysinit option is given, then the names must not end
       in .dpkg-old or .dpkg-dist or .dpkg-new or .dpkg-tmp, and must belong
       to one or more of the following namespaces: the LANANA-assigned
       namespace (^[a-z0-9]+$); the LSB hierarchical and reserved namespaces
       (^_?([a-z0-9_.]+-)+[a-z0-9]+$); and the Debian cron script namespace
       (^[a-zA-Z0-9_-]+$).

Your example name, '99-coolStuff', does match the last of these, so should
not have been skipped.

> Speaking of docs- there is SO much stale info about
> the old update-motd package out there that it took an obnoxious amount
> of time to figure out what package this was in. An update to this man
> page saying it isn't done in cron and update-motd has been superseded by
> this would be good.

I don't think it's the place of the manpage to document what things are *not* true. Better to fix any wrong documentation claiming this is being done via cron.

affects: pam (Ubuntu) → debianutils (Ubuntu)
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.