snmp query returned by CentOS 7 x64 is similar to RHEL 7 x64

Issues related to hardware problems
Post Reply
arnab2890
Posts: 2
Joined: 2014/10/28 11:16:21

snmp query returned by CentOS 7 x64 is similar to RHEL 7 x64

Post by arnab2890 » 2014/10/28 11:30:44

I am using an application that differentiates between different platforms based on their snmp strings returned. Recently I am facing a problem between RHEL 7 and CentOS 7. Both these platforms are returning exactly matching snmp query and hence it becomes to difficult to distinguish between them.
A sample string generated from CentOS is as follows : Linux <hostname> 3.10.32-431.el6.x86_64 #1 SMP Fri Nov 22 03:15:09 UTC 2013 x86_64

However previous version of CentOS returned something like this : "Linux <hostname> 2.6.32-431.el6.x86_64 #1 SMP Fri Nov 22 03:15:09 UTC 2013 x86_64  ⁿ↑ ⁿ  ⁿ# ⁿ' ■♥ ⁿ☺ ⁿ▼ ■♣ ⁿ! ■♥ ■☺CentOS release 6.5 (Final) Kernel 2.6.32-431.el6.x86_64 on an x86_64"

This behaviour is seen with the change in the kernel version from 2.6 to 3.10.

Any suggestion on what other alternative way can I use to distinguish between different platforms remotely.

Thanks

User avatar
TrevorH
Site Admin
Posts: 33219
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: snmp query returned by CentOS 7 x64 is similar to RHEL 7

Post by TrevorH » 2014/10/28 11:45:16

What is the exact query are you issuing to see this? It sounds like you have been exploiting a bug - and not one that I can recreate here since I only get e.g

Code: Select all

SNMPv2-MIB::sysDescr.0 = STRING: Linux vmhost.trevor.local 2.6.32-504.el6.x86_64 #1 SMP Wed Oct 15 04:27:16 UTC 2014  x86_64
You really should not be able to tell the difference between a CentOS machine and a RHEL one at all except by querying something that is designed to be different and the kernel uname string should not be.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

arnab2890
Posts: 2
Joined: 2014/10/28 11:16:21

Re: snmp query returned by CentOS 7 x64 is similar to RHEL 7

Post by arnab2890 » 2014/10/28 11:52:13

Thank you for your suggestion. Actually I use an inbuilt tool that extract the snmp query from different platforms.
I have quoted the exact query that it returned.
The problem is RHEL 7 is also returning the same string from the tool.

User avatar
TrevorH
Site Admin
Posts: 33219
Joined: 2009/09/24 10:40:56
Location: Brighton, UK

Re: snmp query returned by CentOS 7 x64 is similar to RHEL 7

Post by TrevorH » 2014/10/28 12:03:08

Does it also do it using snmpget/snmpwalk? Otherwise I suspect you have a bug in your tool that is returning data past the end of the buffer.

There should be no difference in the data returned for .1.3.6.1.2.1.1.1.0 and the extraneous data you are seeing on 6.x is almost certainly a bug in either the snmp server or in the client that is querying it. My queries against a local box using snmpget/snmpwalk appear to show the server is returning the correct data.
The future appears to be RHEL or Debian. I think I'm going Debian.
Info for USB installs on http://wiki.centos.org/HowTos/InstallFromUSBkey
CentOS 5 and 6 are deadest, do not use them.
Use the FAQ Luke

Post Reply