check_apt: also check for HWE EOL status by basak · Pull Request #1260 · monitoring-plugins/monitoring-plugins · GitHub
Skip to content

check_apt: also check for HWE EOL status#1260

Open
basak wants to merge 2 commits into
monitoring-plugins:masterfrom
basak:master
Open

check_apt: also check for HWE EOL status#1260
basak wants to merge 2 commits into
monitoring-plugins:masterfrom
basak:master

Conversation

@basak

@basak basak commented Jun 16, 2014

Copy link
Copy Markdown

In Ubuntu, LTS point releases ship with hardware enablement kernels and
X.org stacks backported from the latest corresponding non-LTS release by
default, so that users can continue to install and use the LTS release
on newer hardware.

These enablement packages have a shorter support lifetime than the LTS
release itself. The supported mechanism to continue with newer hardware
on LTS releases for the full LTS support lifetime period is to upgrade
to a newer hardware enablement package. This process must be manual,
however, since we do not want to risk regressing installations. We have
concluded that bumping the kernel and X.org versions is a major enough
change that it is not suitable for an automatic update.

Thus we must notify users of this need to update in any way we can, so
that they can take action.

We thought that the existing check_apt test is one appropriate place to
alert users that an update is available.

The underlying logic for the change to this plugin is:

  1. Follow the existing behaviour to determine the number of updates and
    critical updates available.
  2. If /usr/bin/hwe-support-status does not exist, do nothing different.
    This covers the case where users have not yet received the update that
    makes it available, or are using a distribution that does not provide
    HWE packs (eg. Debian currently).
  3. Given that /usr/bin/hwe-support-status does exist, run it with
    --quiet. If an update is required, it will exit with a non-zero status.
  4. If an update is required, bump the number of "critical updates"
    detected.
  5. Report this as normal.
  6. I expect a user who wants more information to run "check_apt -v". In
    this case, /usr/bin/hwe-support-status is run with --verbose and its
    output is printed. This prints a human-readable EOL notification
    message with more information. On Ubuntu, this links to a wiki page
    which we can update with any frequently asked questions.

Though the need for this patch comes from Ubuntu, I've written it in a
way that Debian could use the same mechanism in future. There are no
Ubuntu-specific parts in this patch itself.

More information:

https://launchpad.net/bugs/1244438
https://wiki.ubuntu.com/HweStackEolNotifications
https://wiki.ubuntu.com/1204_HWE_EOL
https://wiki.ubuntu.com/Kernel/LTSEnablementStack
https://blueprints.launchpad.net/ubuntu/+spec/core-1403-hwe-stack-eol-notifications

In Ubuntu, LTS point releases ship with hardware enablement kernels and
X.org stacks backported from the latest corresponding non-LTS release by
default, so that users can continue to install and use the LTS release
on newer hardware.

These enablement packages have a shorter support lifetime than the LTS
release itself. The supported mechanism to continue with newer hardware
on LTS releases for the full LTS support lifetime period is to upgrade
to a newer hardware enablement package. This process must be manual,
however, since we do not want to risk regressing installations. We have
concluded that bumping the kernel and X.org versions is a major enough
change that it is not suitable for an automatic update.

Thus we must notify users of this need to update in any way we can, so
that they can take action.

We thought that the existing check_apt test is one appropriate place to
alert users that an update is available.

The underlying logic for the change to this plugin is:

0. Follow the existing behaviour to determine the number of updates and
critical updates available.

1. If /usr/bin/hwe-support-status does not exist, do nothing different.
This covers the case where users have not yet received the update that
makes it available, or are using a distribution that does not provide
HWE packs (eg. Debian currently).

2. Given that /usr/bin/hwe-support-status does exist, run it with
--quiet. If an update is required, it will exit with a non-zero status.

3. If an update is required, bump the number of "critical updates"
detected.

4. Report this as normal.

5. I expect a user who wants more information to run "check_apt -v". In
this case, /usr/bin/hwe-support-status is run with --verbose and its
output is printed. This prints a human-readable EOL notification
message with more information. On Ubuntu, this links to a wiki page
which we can update with any frequently asked questions.

Though the need for this patch comes from Ubuntu, I've written it in a
way that Debian could use the same mechanism in future. There are no
Ubuntu-specific parts in this patch itself.

More information:

https://launchpad.net/bugs/1244438
https://wiki.ubuntu.com/HweStackEolNotifications
https://wiki.ubuntu.com/1204_HWE_EOL
https://wiki.ubuntu.com/Kernel/LTSEnablementStack
https://blueprints.launchpad.net/ubuntu/+spec/core-1403-hwe-stack-eol-notifications
@basak

basak commented Jun 16, 2014

Copy link
Copy Markdown
Author

@basak

basak commented Jun 16, 2014

Copy link
Copy Markdown
Author

There's some kind of gnulib build error caused by include unistd.h and
sys/types.h as I was directed to do by stat(2).

Dropping down to including just sys/stat.h fixes this problem.

As far as I can see, POSIX says that this is fine to get the required
definitions for the stat function and structure:
http://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/stat.h.html
simondeziel added a commit to simondeziel/custom-nagios-plugins that referenced this pull request Jul 1, 2014
This feature is based on Robie Basak's merge proposal to check_apt:
monitoring-plugins/monitoring-plugins#1260
@waja waja force-pushed the master branch 2 times, most recently from 441913d to 40c870e Compare October 19, 2014 21:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants