Small modification to hobbitclient-linux.sh
list Frédéric Mangeant
Hi Henrik hobbitclient-linux.sh uses "uname -a" to report information about the OS, which gives something like this : Linux hades 2.6.14.2 #2 Wed Nov 16 10:14:26 CET 2005 i686 Pentium III (Katmai) GNU/Linux IMHO it would be great to display less information about the running kernel and add information about the Linux distribution, something like that : Linux 2.6.14.2 i686 - Gentoo Base System version 1.6.14 Linux 2.6.9-34.EL i686 - CentOS release 4.3 (Final) Linux 2.4.20-28.7 i686 - Red Hat Linux release 7.3 (Valhalla) Linux 2.4.26-vs1.28 i686 - Debian 3.1 Linux 2.4.18-64GB-SMP i686 - SuSE Linux 8.0 (i386) If you like this idea, I've tested the attached "patch" (on top of latest snapshot) with RedHat / CentOS, Gentoo, Debian and SuSE. Regards, -- Frédéric Mangeant Steria EDC Sophia-Antipolis
Attachments (1)
list Henrik Størner
▸
On Fri, Jun 02, 2006 at 02:47:30PM +0200, Frédéric Mangeant wrote:
hobbitclient-linux.sh uses "uname -a" to report information about the OS, which gives something like this : Linux hades 2.6.14.2 #2 Wed Nov 16 10:14:26 CET 2005 i686 Pentium III (Katmai) GNU/Linux IMHO it would be great to display less information about the running kernel and add information about the Linux distribution, something like that : Linux 2.6.14.2 i686 - Gentoo Base System version 1.6.14 Linux 2.6.9-34.EL i686 - CentOS release 4.3 (Final)
I've taken your patch and modified it somewhat, so that the distribution
specific information is reported in a separate [osversion] section of
the client data. Then I made the "info" column webpage use this, so in
the "OS: " display you'll now see
OS: Ubuntu 6.06
Linux osiris.hswn.dk 2.6.15-23-k7 i686
Regards,
Henrik
list Allan Spencer
▸
Henrik Stoerner wrote:
On Fri, Jun 02, 2006 at 02:47:30PM +0200, Frédéric Mangeant wrote:hobbitclient-linux.sh uses "uname -a" to report information about the OS, which gives something like this : Linux hades 2.6.14.2 #2 Wed Nov 16 10:14:26 CET 2005 i686 Pentium III (Katmai) GNU/Linux IMHO it would be great to display less information about the running kernel and add information about the Linux distribution, something like that : Linux 2.6.14.2 i686 - Gentoo Base System version 1.6.14 Linux 2.6.9-34.EL i686 - CentOS release 4.3 (Final)I've taken your patch and modified it somewhat, so that the distribution specific information is reported in a separate [osversion] section of the client data. Then I made the "info" column webpage use this, so in the "OS: " display you'll now see OS: Ubuntu 6.06 Linux osiris.hswn.dk 2.6.15-23-k7 i686 Regards, Henrik
Another very nice addition that will come in handy, but as an extension could the 'flavour' be added in there also ? Eg I know you can do cat /etc/redhat-release on redhat but no idea what the equivalent command is on other nix* Allan
list Rdeal
This and more are available in the cpu2.sh script on deadcat.
▸
From: ZanDAhaR <user-42a3456c44ef@xymon.invalid>
Reply-To: <user-ae9b8668bcde@xymon.invalid>
Date: Mon, 05 Jun 2006 09:32:23 +1000
To: <user-ae9b8668bcde@xymon.invalid>
Subject: Re: [hobbit] Small modification to hobbitclient-linux.sh
Henrik Stoerner wrote:On Fri, Jun 02, 2006 at 02:47:30PM +0200, Frédéric Mangeant wrote:hobbitclient-linux.sh uses "uname -a" to report information about the OS, which gives something like this : Linux hades 2.6.14.2 #2 Wed Nov 16 10:14:26 CET 2005 i686 Pentium III (Katmai) GNU/Linux IMHO it would be great to display less information about the running kernel and add information about the Linux distribution, something like that : Linux 2.6.14.2 i686 - Gentoo Base System version 1.6.14 Linux 2.6.9-34.EL i686 - CentOS release 4.3 (Final)I've taken your patch and modified it somewhat, so that the distribution specific information is reported in a separate [osversion] section of the client data. Then I made the "info" column webpage use this, so in the "OS: " display you'll now see OS: Ubuntu 6.06 Linux osiris.hswn.dk 2.6.15-23-k7 i686 Regards, Henrik
Another very nice addition that will come in handy, but as an extension could the 'flavour' be added in there also ? Eg I know you can do cat /etc/redhat-release on redhat but no idea what the equivalent command is on other nix* Allan
list Allan Spencer
▸
rdeal wrote:
This and more are available in the cpu2.sh script on deadcat.
*From: *ZanDAhaR <user-42a3456c44ef@xymon.invalid>
*Reply-To: *<user-ae9b8668bcde@xymon.invalid>
*Date: *Mon, 05 Jun 2006 09:32:23 +1000
*To: *<user-ae9b8668bcde@xymon.invalid>
*Subject: *Re: [hobbit] Small modification to hobbitclient-linux.sh
Henrik Stoerner wrote:
On Fri, Jun 02, 2006 at 02:47:30PM +0200, Frédéric Mangeant wrote:
hobbitclient-linux.sh uses "uname -a" to report information
about the
OS, which gives something like this :
Linux hades 2.6.14.2 #2 Wed Nov 16 10:14:26 CET 2005 i686
Pentium III
(Katmai) GNU/Linux
IMHO it would be great to display less information about the
running
kernel and add information about the Linux distribution,
something like
that :
Linux 2.6.14.2 i686 - Gentoo Base System version 1.6.14
Linux 2.6.9-34.EL i686 - CentOS release 4.3 (Final)
I've taken your patch and modified it somewhat, so that the
distribution
specific information is reported in a separate [osversion] section of
the client data. Then I made the "info" column webpage use this, so in
the "OS: " display you'll now see
OS: Ubuntu 6.06
Linux osiris.hswn.dk 2.6.15-23-k7 i686
Regards,
Henrik
Another very nice addition that will come in handy, but as an
extension could the 'flavour' be added in there also ? Eg I know you
can do cat /etc/redhat-release on redhat but no idea what the
equivalent command is on other nix*
Allan
Ahh forgot all about that thing!! Shows how long I've been avoiding bb stuff and trying to rely solely on hobbit :) A
list Frédéric Mangeant
▸
Henrik Stoerner a écrit :
I've taken your patch and modified it somewhat, so that the distribution
specific information is reported in a separate [osversion] section of
the client data. Then I made the "info" column webpage use this, so in
the "OS: " display you'll now see
OS: Ubuntu 6.06
Linux osiris.hswn.dk 2.6.15-23-k7 i686
Thanks, your "OS" display is more readable. Here are some more distribution specific files : - Slackware : /etc/slackware-version - Mandriva : /etc/mandrake-release - Fedora : /etc/fedora-release - Arch Linux : /etc/arch-release I don't have these at work, so I don't know the exact format of these files. Regards, -- Frédéric Mangeant Steria EDC Sophia-Antipolis