Auteur Sujet: [RÉSOLU] (SNMPTT) Conversion MIB - Cannot adopt OID in  (Lu 942 fois)

Hors ligne surcouf

  • Modérateur Global
  • Super Froggy
  • *****
  • Messages: 1 694
  • Karma: 17
Re : Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #15 le: 06 janvier, 2012, 11:24:56 am »
Aucun résultat :

[root@supervision ~]# grep -i '(Brocade-TC|Brocade-REG-MIB)'  /EXPLOIT/MIB_BROCADE/*.mib
[root@supervision ~]#
Au temps pour moi, essaie avec egrep.
Raphaël 'SurcouF' Bordet

Hors ligne GarsDuCalvados

  • BoyScout Froggy
  • **
  • Messages: 84
  • Karma: 0
Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #16 le: 06 janvier, 2012, 13:36:40 pm »
Désolé je ne connaissais pas la commande "egrep".
Je pensais que tu avais fais une faute de frappe.

Voici le résultat :

[root@supervision ~]# egrep -i '(Brocade-TC|Brocade-REG-MIB)'  /EXPLOIT/MIB_BROCADE/*.mib
/EXPLOIT/MIB_BROCADE/brcdfcip.mib:       bcsi FROM Brocade-REG-MIB
/EXPLOIT/MIB_BROCADE/BRCD.mib:Brocade-REG-MIB DEFINITIONS ::= BEGIN
/EXPLOIT/MIB_BROCADE/BRCD.mib:Brocade-TC DEFINITIONS ::= BEGIN
/EXPLOIT/MIB_BROCADE/BRCD.mib:      FROM Brocade-REG-MIB
/EXPLOIT/MIB_BROCADE/FICON_v5_0.mib:      FROM Brocade-REG-MIB;
/EXPLOIT/MIB_BROCADE/HA.mib:    fibrechannel  FROM Brocade-REG-MIB
/EXPLOIT/MIB_BROCADE/SW.mib:      FROM Brocade-TC
/EXPLOIT/MIB_BROCADE/SW.mib:      FROM Brocade-REG-MIB;

.Matt

Hors ligne surcouf

  • Modérateur Global
  • Super Froggy
  • *****
  • Messages: 1 694
  • Karma: 17
Re : Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #17 le: 06 janvier, 2012, 13:41:06 pm »
Désolé je ne connaissais pas la commande "egrep".[/close]
egrep est l'équivalent de grep -e.
Je pensais que tu avais fais une faute de frappe.

Voici le résultat :

[root@supervision ~]# egrep -i '(Brocade-TC|Brocade-REG-MIB)'  /EXPLOIT/MIB_BROCADE/*.mib
/EXPLOIT/MIB_BROCADE/BRCD.mib:Brocade-REG-MIB DEFINITIONS ::= BEGIN
/EXPLOIT/MIB_BROCADE/BRCD.mib:Brocade-TC DEFINITIONS ::= BEGIN
Nous avons donc la confirmation que le fichier BRCD.mib contient les définitions de Brocade-REG-MIB et Brocade-TC.
Il te faut donc copier ce fichier dans le répertoire /usr/share/snmp/mibs et ça devrait déjà résoudre tes problèmes de définitions d'OID.
Raphaël 'SurcouF' Bordet

Hors ligne GarsDuCalvados

  • BoyScout Froggy
  • **
  • Messages: 84
  • Karma: 0
Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #18 le: 06 janvier, 2012, 16:38:36 pm »
Bonjour,

J'ai copié le fichier BRCD.mib dans mon dossier ou les MIB sont localisé.

Mais j'ai toujours mes erreurs OID lors de la conversion de la MIB :

Cannot adopt OID in SW-MIB: swBlmPerfMnt ::= { sw 23 }
.Matt

Hors ligne surcouf

  • Modérateur Global
  • Super Froggy
  • *****
  • Messages: 1 694
  • Karma: 17
Re : Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #19 le: 06 janvier, 2012, 16:57:12 pm »
Bonjour,

J'ai copié le fichier BRCD.mib dans mon dossier ou les MIB sont localisé.

Mais j'ai toujours mes erreurs OID lors de la conversion de la MIB :

Cannot adopt OID in SW-MIB: swBlmPerfMnt ::= { sw 23 }
Où puis-je récupérer ces MIB, que je teste ce soir chez moi ?
Raphaël 'SurcouF' Bordet

Hors ligne GarsDuCalvados

  • BoyScout Froggy
  • **
  • Messages: 84
  • Karma: 0
Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #20 le: 09 janvier, 2012, 08:01:55 am »
Salut à toi,

En espérant que tu as passé un bon week.

Voici le lien ou j'ai récupré les MIB (tout en bas).

J'ai pris la version 6.3 en rapport à la version logiciel de mes BROCADE.

==> http://community.brocade.com/docs/DOC-1733

.Matt

Hors ligne surcouf

  • Modérateur Global
  • Super Froggy
  • *****
  • Messages: 1 694
  • Karma: 17
Re : Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #21 le: 10 janvier, 2012, 09:28:11 am »
Salut à toi,

En espérant que tu as passé un bon week.

Voici le lien ou j'ai récupré les MIB (tout en bas).

J'ai pris la version 6.3 en rapport à la version logiciel de mes BROCADE.

==> http://community.brocade.com/docs/DOC-1733
En analysant tous les messages d'erreurs, il y a plusieurs typo concernant les dates de mises à jour.
Net-SNMP est assez strict dans sa lecture des MIB et certaines sont parfois mal écrites. Ci-joint, une archive avec les principaux fichiers intéressants et corrigés.
Raphaël 'SurcouF' Bordet

Hors ligne GarsDuCalvados

  • BoyScout Froggy
  • **
  • Messages: 84
  • Karma: 0
Re : [SNMPTT] Conversion MIB - Cannot adopt OID in
« Réponse #22 le: 10 janvier, 2012, 13:22:01 pm »
Mille merci :) :

[root@supervision snmptt]# ./snmpttconvertmib --in=/EXPLOIT/MIB_BROCADE/SW.mib --out=/etc/snmp/snmptt.conf.ESSAI --exec='/usr/local/nagios/libexec/eventhandlers/submit_check_result $r TRAP 1'
exec: /usr/local/nagios/libexec/eventhandlers/submit_check_result $r TRAP 1


*****  Processing MIB file *****

snmptranslate version: NET-SNMP version: 5.3.2.2
severity: Normal

File to load is:        /EXPLOIT/MIB_BROCADE/SW.mib
File to APPEND TO:      /etc/snmp/snmptt.conf.ESSAI

MIBS environment var:   /EXPLOIT/MIB_BROCADE/SW.mib
mib name: SW-MIB


Processing MIB:         SW-MIB
#
skipping a TRAP-TYPE / NOTIFICATION-TYPE line - probably an import line.
#
Line: 3189
NOTIFICATION-TYPE: swFault
Variables: swDiagResult swSsn swGroupName swGroupType swGroupMemPos
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swFault
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.1
#
Line: 3204
NOTIFICATION-TYPE: swSensorScn
Variables: swSensorStatus swSensorIndex swSensorType swSensorValue swSensorInfo swSsn swGroupName swGroupType swGroupMemPos
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swSensorScn
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.2
#
Line: 3225
NOTIFICATION-TYPE: swFCPortScn
Variables: swFCPortOpStatus swFCPortIndex swFCPortName swSsn swFCPortFlag swGroupName swGroupType swGroupMemPos swVfId
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swFCPortScn
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.3
#
Line: 3248
NOTIFICATION-TYPE: swEventTrap
Variables: swEventIndex swEventTimeInfo swEventLevel swEventRepeatCount swEventDescr swSsn swGroupName swGroupType swGroupMemPos swVfId
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swEventTrap
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.4
#
Line: 3265
NOTIFICATION-TYPE: swFabricWatchTrap
Variables: swFwClassAreaIndex swFwThresholdIndex swFwName swFwLabel swFwLastEventVal swFwLastEventTime swFwLastEvent swFwLastState swFwLastSeverityLevel swSsn swGroupName swGroupType swGroupMemPos swVfId
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swFabricWatchTrap
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.5
#
Line: 3293
NOTIFICATION-TYPE: swTrackChangesTrap
Variables: swTrackChangesInfo swSsn swGroupName swGroupType swGroupMemPos swVfId
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swTrackChangesTrap
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.6
#
Line: 3308
NOTIFICATION-TYPE: swIPv6ChangeTrap
Variables: swIPv6Address swIPv6Status
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swIPv6ChangeTrap
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.7
#
Line: 3321
NOTIFICATION-TYPE: swPmgrEventTrap
Variables: swPmgrEventType swPmgrEventTime swPmgrEventDescr swSsn swVfId
Enterprise: swTrapsV2
Looking up via snmptranslate: SW-MIB::swPmgrEventTrap
No log handling enabled - turning on stderr logging
Timestamp should end with Z (TR000247407): At line 93 in /EXPLOIT/MIB_BROCADE/SW.mib
Timestamp should end with Z (TR000255798): At line 99 in /EXPLOIT/MIB_BROCADE/SW.mib
OID: .1.3.6.1.4.1.1588.2.1.1.1.0.8


Done

Total translations:        8
Successful translations:   8
Failed translations:       0

ça a fonctionné tes modifications.

Encore merci à toi,

.Matt