Portál AbcLinuxu, 14. května 2025 03:09
/usr/bin/cfgmaker \ --output=/etc/mrtg/traffic.cfg \ --ifdesc=ip \ --ifref=descr \ --global "WorkDir: /var/www/localhost/htdocs/mrtg" \ --global "Options[_]: bits,growright" \ public@localhostmi nezafungovala. Muzete mi poradit jak ma by konfigurace spravne ? Dekuji
deb http://ftp.cz.debian.org/debian jessie main contrib non-free
sysDescr.0 = STRING: Linux monitoring 2.4.27-2-386 #1 Wed Aug 17 09:33:35 UTC 2005 i586 sysObjectID.0 = OID: netSnmpAgentOIDs.10 sysUpTimeInstance = Timeticks: (10574337) 1 day, 5:22:23.37 sysContact.0 = STRING: Root (configure /etc/snmp/snmpd.local.conf) sysName.0 = STRING: monitoring sysLocation.0 = STRING: Unknown (configure /etc/snmp/snmpd.local.conf) sysORLastChange.0 = Timeticks: (11) 0:00:00.11 sysORID.1 = OID: ifMIB sysORID.2 = OID: snmpMIB sysORID.3 = OID: tcpMIB sysORID.4 = OID: ip sysORID.5 = OID: udpMIB sysORID.6 = OID: vacmBasicGroup sysORID.7 = OID: snmpFrameworkMIBCompliance sysORID.8 = OID: snmpMPDCompliance sysORID.9 = OID: usmMIBCompliance sysORDescr.1 = STRING: The MIB module to describe generic objects for network interface sub-layers sysORDescr.2 = STRING: The MIB module for SNMPv2 entities sysORDescr.3 = STRING: The MIB module for managing TCP implementations sysORDescr.4 = STRING: The MIB module for managing IP and ICMP implementations sysORDescr.5 = STRING: The MIB module for managing UDP implementations sysORDescr.6 = STRING: View-based Access Control Model for SNMP. sysORDescr.7 = STRING: The SNMP Management Architecture MIB. sysORDescr.8 = STRING: The MIB for Message Processing and Dispatching. sysORDescr.9 = STRING: The management information definitions for the SNMP User-based Security Model. sysORUpTime.1 = Timeticks: (8) 0:00:00.08 sysORUpTime.2 = Timeticks: (9) 0:00:00.09 sysORUpTime.3 = Timeticks: (9) 0:00:00.09 sysORUpTime.4 = Timeticks: (9) 0:00:00.09 sysORUpTime.5 = Timeticks: (9) 0:00:00.09 sysORUpTime.6 = Timeticks: (9) 0:00:00.09 sysORUpTime.7 = Timeticks: (11) 0:00:00.11 sysORUpTime.8 = Timeticks: (11) 0:00:00.11 sysORUpTime.9 = Timeticks: (11) 0:00:00.11 End of MIBtedy, snmp na serveru odpovida. A pokud ted dam: cfgmaker poublic@127.0.0.1
SNMP Error: no response received SNMPv1_Session (remote host: "127.0.0.1" [127.0.0.1].161) community: "poublic" request ID: -130069904 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.1 on poublic@127.0.0.1::::::v4only at /usr/bin/cfgmaker line 921 WARNING: Skipping poublic@127.0.0.1: as no info could be retrieved # Created by # /usr/bin/cfgmaker poublic@127.0.0.1 ### Global Config Options # for UNIX # WorkDir: /home/http/mrtg # for Debian WorkDir: /var/www/mrtg # or for NT # WorkDir: c:\mrtgdata ### Global Defaults # to get bits instead of bytes and graphs growing to the right # Options[_]: growright, bits EnableIPv6: no ###################################################################### # System: # Description: # Contact: # Location: ######################################################################tak to neprobehne v poradku. Nevim presne jakou konfiguraci by mel tento prikaz vygenerovat, ale cekal bych ze vygeneruje konfiguraci pro vsechny parametry, ktere se daji na serveru sledovat a ja si vyberu pouze ty, ktere potrebuji. Mne by ted stacilo, kdyz budu mit konfiguraci pro monitoring sitovych rozhrani. U cisco routeru a switchuje tato uloha pomerne jednoducha, ale u monitorovani linux serveru nevim. Prosim o radu
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: -96106258 PDU bufsize: 8000 bytes timeout: 2s retries: 5 backoff: 1) at /usr/share/perl5/SNMP_util.pm line 733 # Created by # /usr/bin/cfgmaker public@127.0.0.1 ### Global Config Options # for UNIX # WorkDir: /home/http/mrtg # for Debian WorkDir: /var/www/mrtg # or for NT # WorkDir: c:\mrtgdata ### Global Defaults # to get bits instead of bytes and graphs growing to the right # Options[_]: growright, bits EnableIPv6: no ###################################################################### # System: monitoring # Description: Linux monitoring 2.4.27-2-386 #1 Wed Aug 17 09:33:35 UTC 2005 i586 # Contact: Root (configure /etc/snmp/snmpd.local.conf) # Location: Unknown (configure /etc/snmp/snmpd.local.conf) #####################################################################
Z toho snmpwalk výpisu by vám ale měla být příčina problému zřejmá
SNMP démon na tom serveru poskytuje pouze jenom velmi omezenou množinu informací, konkrétně neříká vůbec nic o svých rozhraních. cfgmaker se ale snaží najít informace jiné, konkrétně to 1.3.6.1.2.1.1 leze někam do části SNMPv2-MIB, kde jsou údaje o system description, uptime a tak - a váš démon mu nic podobného neřekne, takže konfigurátor exne.
Musíte nakonfigurovat SNMP démona tak, aby poskytoval informace, které konfigurátor čeká (a na jejichž základě pak sestaví konfiguraci). Pokud si dobře pamatuju /etc/snmpd.conf je docela dobře komentovaný a napoví vám, jak co nastavit. Konkrétně musíte poskytnout informace o systému (popis a uptime, SNMPv2-MIB::sysDescr.0 a SNMPv2-MIB::sysUptime.0) a pak nějak vhodně oMIBovat rozhraní a jejich OctetsIn, OctetsOut a takové ty věci...
Tiskni
Sdílej:
ISSN 1214-1267, (c) 1999-2007 Stickfish s.r.o.