OVH Cloud OVH Cloud

problemes SNMP et MRTG

3 réponses
Avatar
Rakotomandimby (R12y) Mihamina
Bonjour,

Je suis sur une Debian Testing et avec un noyau 2.6.8-2 compilé avec mes
options à partir des sources patchées par Debian.

Je n'arrive pas à configurer mrtg, parceque SNMP lui-même se (com)porte
mal...

Les messages et éléments qui sont en ma possession sont ci dessous, et
je pense que j'ai pas les bonnes options dans le Noyau, pourtant au niveau
SNMP, il n'y a pas tant d'options disponibles que ça.

J'ai du louper quelquechose, mais je ne vois pas quoi.

Sur une autre Testing mais avec le kernel-image de Debian, tout a marché
du premier coup... donc ça me fais penser que c'est bien une option du
kernel que j'ai loupé mais je ne sais pas laquelle... Et j'ai cherché
sur le net avec "linux kernel 2.6 option snmp" mais y a pas grand chose...


Merci d'avance...

root-mail>>>>dpkg -l | grep snmp
ii libnet-snmp-pe 5.0.1-1 Script SNMP connections
ii libsnmp-base 5.1.2-6.1 NET SNMP (Simple Network Management Protocol
ii libsnmp-perl 5.1.2-6.1 NET SNMP (Simple Network Management Protocol
ii libsnmp-sessio 1.07-1 Perl support for accessing SNMP-aware device
ii libsnmp4.2 4.2.5-5 NET SNMP (Simple Network Management Protocol
ii libsnmp5 5.1.2-6.1 NET SNMP (Simple Network Management Protocol
ii snmp 5.1.2-6.1 NET SNMP (Simple Network Management Protocol
ii snmpd 5.1.2-6.1 NET SNMP (Simple Network Management Protocol
ii snmptrapfmt 1.08 A configurable snmp trap handler daemon for

root-mail>>>>ifconfig
eth0 Link encap:Ethernet HWaddr 00:01:02:45:B1:0F
inet addr:83.143.18.14 Bcast:83.143.18.255 Mask:255.255.255.0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX
packets:37735950 errors:0 dropped:0 overruns:0 frame:0 TX
packets:28120360 errors:0 dropped:0 overruns:0 carrier:890
collisions:0 txqueuelen:1000
RX bytes:92612657 (88.3 MiB) TX bytes:2090140865 (1.9 GiB)
Interrupt:22 Base address:0xb800
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:634212 errors:0 dropped:0 overruns:0 frame:0
TX packets:634212 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:615137901 (586.6 MiB) TX bytes:615137901 (586.6 MiB)

root-mail>>>> grep SNMP /boot/config-2.6.8-3
# CONFIG_IP_NF_NAT_SNMP_BASIC is not set

root-mail>>>> cfgmaker --global 'WorkDir: /var/www/mrtg' --output
/etc/mrtg.cfg public@127.0.0.1 --base: Get Device Info on
public@127.0.0.1: SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.1.9.1.4.9)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089820
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 733
--base: Vendor Id:
--base: Populating confcache
--coca: populate confcache public@127.0.0.1: --coca: Skipping ifName
scanning because public@127.0.0.1: does not seem to support it --coca:
Skipping ifDescr scanning because public@127.0.0.1: does not seem to
support it --coca: Skipping ifType scanning because public@127.0.0.1: does
not seem to support it --coca: Skipping ipAdEntIfIndex scanning because
public@127.0.0.1: does not seem to support it --coca: Skipping
ifPhysAddress scanning because public@127.0.0.1: does not seem to support
it --base: Get Interface Info
--base: Walking ifIndex
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.1)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089826
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.1 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 144
--base: Walking ifType
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.3)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089827
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.3 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 144
--base: Walking ifAdminStatus
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.7)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089828
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.7 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 144
--base: Walking ifOperStatus
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.8)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089829
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.8 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 144
--base: Walking ifMtu
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.4)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089830
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.4 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 144
--base: Walking ifSpeed
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.5)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089831
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.5 on public@127.0.0.1::::::v4only
at /usr/bin/cfgmaker line 183
--base: Writing /etc/mrtg.cfg

--
Miroir de logiciels libres http://www.etud-orleans.fr
Développement de logiciels libres http://aspo.rktmb.org/activites/developpement
Infogerance de serveur dédié http://aspo.rktmb.org/activites/infogerance
(En louant les services de l'ASPO vous luttez contre la fracture numerique)

3 réponses

Avatar
SauronDeMordor
snmp n est pas un service kernel

as tu demare le daemon snmp?

/etc/init.d/snmpd status

ensuite il te faudra configurer snmpd.conf dans etc/snmp/snmpd.conf qui a priori
pour ce aue tu veux faire (graph de traffic reseau il me semble) est deja ok.

donc demarer le daemon puis refais cfgmaker, ca devrait etre ok


Bonjour,

Je suis sur une Debian Testing et avec un noyau 2.6.8-2 compilé avec mes
options à partir des sources patchées par Debian.

Je n'arrive pas à configurer mrtg, parceque SNMP lui-même se (com)p orte
mal...

Les messages et éléments qui sont en ma possession sont ci dessous, et
je pense que j'ai pas les bonnes options dans le Noyau, pourtant au niv eau
SNMP, il n'y a pas tant d'options disponibles que ça.

J'ai du louper quelquechose, mais je ne vois pas quoi.

Sur une autre Testing mais avec le kernel-image de Debian, tout a march é
du premier coup... donc ça me fais penser que c'est bien une option d u
kernel que j'ai loupé mais je ne sais pas laquelle... Et j'ai cherché
sur le net avec "linux kernel 2.6 option snmp" mais y a pas grand chose ...


Merci d'avance...

root-mail>>>>dpkg -l | grep snmp
ii libnet-snmp-pe 5.0.1-1 Script SNMP connections
ii libsnmp-base 5.1.2-6.1 NET SNMP (Simple Network Management P rotocol
ii libsnmp-perl 5.1.2-6.1 NET SNMP (Simple Network Management P rotocol
ii libsnmp-sessio 1.07-1 Perl support for accessing SNMP-aware device
ii libsnmp4.2 4.2.5-5 NET SNMP (Simple Network Management P rotocol
ii libsnmp5 5.1.2-6.1 NET SNMP (Simple Network Management P rotocol
ii snmp 5.1.2-6.1 NET SNMP (Simple Network Management P rotocol
ii snmpd 5.1.2-6.1 NET SNMP (Simple Network Management P rotocol
ii snmptrapfmt 1.08 A configurable snmp trap handler daem on for

root-mail>>>>ifconfig
eth0 Link encap:Ethernet HWaddr 00:01:02:45:B1:0F
inet addr:83.143.18.14 Bcast:83.143.18.255 Mask:255.255.255 .0
UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX
packets:37735950 errors:0 dropped:0 overruns:0 frame:0 TX
packets:28120360 errors:0 dropped:0 overruns:0 carrier:890
collisions:0 txqueuelen:1000
RX bytes:92612657 (88.3 MiB) TX bytes:2090140865 (1.9 GiB)
Interrupt:22 Base address:0xb800
lo Link encap:Local Loopback
inet addr:127.0.0.1 Mask:255.0.0.0
UP LOOPBACK RUNNING MTU:16436 Metric:1
RX packets:634212 errors:0 dropped:0 overruns:0 frame:0
TX packets:634212 errors:0 dropped:0 overruns:0 carrier:0
collisions:0 txqueuelen:0
RX bytes:615137901 (586.6 MiB) TX bytes:615137901 (586.6 MiB )

root-mail>>>> grep SNMP /boot/config-2.6.8-3
# CONFIG_IP_NF_NAT_SNMP_BASIC is not set

root-mail>>>> cfgmaker --global 'WorkDir: /var/www/mrtg' --output
/etc/mrtg.cfg --base: Get Device Info on
: SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.1.9.1.4.9)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089820
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 733
--base: Vendor Id:
--base: Populating confcache
--coca: populate confcache : --coca: Skipping ifName
scanning because : does not seem to support it --coca:
Skipping ifDescr scanning because : does not seem to
support it --coca: Skipping ifType scanning because : d oes
not seem to support it --coca: Skipping ipAdEntIfIndex scanning because
: does not seem to support it --coca: Skipping
ifPhysAddress scanning because : does not seem to suppo rt
it --base: Get Interface Info
--base: Walking ifIndex
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.1)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089826
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.1 on ::::::v4onl y
at /usr/bin/cfgmaker line 144
--base: Walking ifType
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.3)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089827
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.3 on ::::::v4onl y
at /usr/bin/cfgmaker line 144
--base: Walking ifAdminStatus
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.7)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089828
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.7 on ::::::v4onl y
at /usr/bin/cfgmaker line 144
--base: Walking ifOperStatus
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.8)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089829
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.8 on ::::::v4onl y
at /usr/bin/cfgmaker line 144
--base: Walking ifMtu
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.4)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089830
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.4 on ::::::v4onl y
at /usr/bin/cfgmaker line 144
--base: Walking ifSpeed
SNMP Error:
Received SNMP response with error code
error status: noSuchName
index 1 (OID: 1.3.6.1.2.1.2.2.1.5)
SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161)
community: "public"
request ID: 106089831
PDU bufsize: 8000 bytes
timeout: 2s
retries: 5
backoff: 1)
at /usr/share/perl5/SNMP_util.pm line 627
SNMPWALK Problem for 1.3.6.1.2.1.2.2.1.5 on ::::::v4onl y
at /usr/bin/cfgmaker line 183
--base: Writing /etc/mrtg.cfg



Avatar
Rakotomandimby (R12y) Mihamina
SauronDeMordor :

snmp n est pas un service kernel


Ok.

as tu demare le daemon snmp?


Oui :-)

/etc/init.d/snmpd status


Il connait pas sur Debian.

ensuite il te faudra configurer snmpd.conf dans etc/snmp/snmpd.conf qui a
priori pour ce aue tu veux faire (graph de traffic reseau il me semble)
est deja ok.


Comment tu sais qu'il est OK?

donc demarer le daemon puis refais cfgmaker, ca devrait etre ok


J'ai déjà fait ça mais non ça ne marche pas...

Usage: /etc/init.d/snmpd {start|stop|restart|reload|force-reload}
invoke-rc.d: initscript snmpd, action "status" failed.

root-mail>>>>ps aux | grep snmp
root 9424 0.0 0.0 1508 432 ? Ss 16:45 0:00 /usr/sbin/snmptrapfmt -D -f /etc/snmp/snmptrapfmt.conf
root 10287 0.0 0.6 5572 3424 ? S 17:28 0:00 /usr/sbin/snmpd -Lsd -Lf /dev/null -p /var/run/snmpd.pid
root 11382 0.0 0.0 1548 480 pts/0 S+ 18:39 0:00 grep snmp

--
Miroir de logiciels libres http://www.etud-orleans.fr
Développement de logiciels libres http://aspo.rktmb.org/activites/developpement
Infogerance de serveur dédié http://aspo.rktmb.org/activites/infogerance
(En louant les services de l'ASPO vous luttez contre la fracture numerique)

Avatar
Rakotomandimby (R12y) Mihamina
"Rakotomandimby (R12y) Mihamina"
:
[...]

Non c'est bon, c'était des paramètres foireux dans le snmpd.conf.

Mais il est du même acabit que le fichier de conf de sendmail ce truc...


--
Miroir de logiciels libres http://www.etud-orleans.fr
Développement de logiciels libres http://aspo.rktmb.org/activites/developpement
Infogerance de serveur dédié http://aspo.rktmb.org/activites/infogerance
(En louant les services de l'ASPO vous luttez contre la fracture numerique)