Ticket #491 (closed enhancement: fixed)

Opened 14 years ago

Last modified 14 years ago

counterlog should include `lsb_release -sd`

Reported by: jdreed Owned by: jdreed
Priority: blocker Milestone: Karmic Deploy (Canceled)
Component: -- Keywords:
Cc: Fixed in version:
Upstream bug:

Description

We should update counterlog to include the output of lsb_release -sd, so that we can compile a list of users running old distros and tell them to upgrade before Ubuntu de-supports them.

This requires coordination with ops to ensure that this doesn't break their existing scripts.

Marking as critical, because Intrepid turns off in April, and there are Interpid machines in the wild.

Change History

comment:1 Changed 14 years ago by jweiss

This is a little tricky, as the existing scripts count words backwards from the end of the line, since suns and linux boxes log different junk before the interesting part of the message. All of the words back to "counterlog" which begins that part of the log message are counted, so I believe we're stuck either having a flag day for the log format (which won't work, since we're not going to update the old suns), making the existing scripts smart enough to identify the new style log from the old style one (plausible, I think) or replacing a useless word with the new information. For reference, the existing words (working backwards from the end) are:

0: cron|booting (to indicate what ran counterlog
*1: unique id
*2: version or metapackage, depending on whether it is an athena 9 or debathena machine
3: hardware (eg., Sun-Blade-1500, x86_64, i686)
*4: sun4|linux
5: hostname
*6: Counterlog:

  • referenced by the existing scripts

Over the course of writing this, I think I've come to the conclusion that updating the existing script to allow for an additional word may be the best option, but let me know if you think it would be a better idea to replace one of the existing words.

comment:2 follow-up: ↓ 3 Changed 14 years ago by jdreed

If we replace item 4 ("linux"), we get the added benefit that Debathena machines are no longer double-counted in the monthly counterlog report, and "linux" would refer exclusively to Athena 9. So I'm in favor of that.

I'll note that "lsb_release -sd" returns multiple words, so whitespace should be replaced with underscores or something.

comment:3 in reply to: ↑ 2 Changed 14 years ago by jweiss

If we replace item 4 ("linux"), we get the added benefit that Debathena machines are no longer double-counted in the monthly counterlog report, and "linux" would refer exclusively to Athena 9. So I'm in favor of that.

They'd still get double counted, it would just be as "lsb-release" and "debathena-foo" rather than "linux" and "debathena-foo". That might still be a feature though. I'm pretty sure that I can separately update the script to be more intelligent about not double-counting them, regardless of this change, if that's important.

comment:4 Changed 14 years ago by jdreed

At 1/29 release-team, we decided we're fine with the double-counting. There was some debate as to whether we want "lsb_release -sc" instead (which returns the codename).

It was asserted that s/\s/_/g; is still required because the "codename" on Debian is, e.g. "Debian Lenny", but this appears to not be true:

dr-wily:~> lsb_release -sc
lenny
dr-wily:~> 

This is high-priority so we can begin telling Intrepid users that they'll lose in April.

comment:5 Changed 14 years ago by jdreed

  • Status changed from new to accepted
  • Owner set to jdreed

Fixed in r24336

comment:6 Changed 14 years ago by broder

  • Status changed from accepted to proposed

Built and uploaded, with some unrelated cleanup in r24343

comment:7 Changed 14 years ago by broder

  • Status changed from proposed to closed
  • Resolution set to fixed

Moved to production.

comment:8 Changed 14 years ago by jweiss

This seems to be working fine. Looking at the report for the 24 hour window ending at 7:45am today:

9 debathena-clients

282 debathena-cluster

3 debathena-locker

42 debathena-login
15 debathena-login-graphical

141 debathena-standard
114 debathena-workstation

9 hardy
3 intrepid

145 jaunty

7 karmic
2 lenny

698 linux

1 sgi
2 sid

64 sun4

Let me know if you want a list of the machines at a specific release.

Note: See TracTickets for help on using tickets.