snmp OID question

Discussion in 'PHP' started by PSS, Jun 18, 2007.

  1. PSS

    PSS Member

    Sorry to bother again so soon :)

    I'm working on making mrtg graph Litespeed data. All seems well, all Litespeed OID's return data with snmpwalk, like

    Code:
    [root@main snmp_monitoring]# /usr/local/bin/snmpwalk -v1 -c XXXXXXX localhost .1.3.6.1.4.1.22253.310
    SNMPv2-SMI::enterprises.22253.310.1 = Gauge32: 0
    I have inserted in mrtg.cnf

    Code:
    Target[litespeed.req_per_sec]: .1.3.6.1.4.1.22253.310&.1.3.6.1.4.1.22253.310:XXXXXXXX@localhost
    Title[litespeed.req_per_sec]: Litespeed requests per second
    PageTop[litespeed.req_per_sec]: <H1>Litespeed requests per second</H1>
    MaxBytes[litespeed.req_per_sec]: 1000000000
    ShortLegend[litespeed.req_per_sec]: req/s
    YLegend[litespeed.req_per_sec]: Requests/s
    LegendI[litespeed.req_per_sec]:
    LegendO[litespeed.req_per_sec]:
    Legend1[litespeed.req_per_sec]: Requests per second
    Legend2[litespeed.req_per_sec]:
    Options[litespeed.req_per_sec]: growright,nopercent,gauge
    XSize[litespeed.req_per_sec]: 600
    YSize[litespeed.req_per_sec]: 100
    
    But mrtg gives error

    SNMPGET Problem for .1.3.6.1.4.1.22253.310 .1.3.6.1.4.1.22253.310 sysUptime sysName on XXXXXXXX@localhost::::::v4only
    at /usr/bin/mrtg line 2035

    310 should be
    "310" => "gauge,req_per_sec"
    and not sysUptime sysName

    I check it out with

    Code:
    /usr/local/bin/snmpget -v1 -c XXXXXXXX localhost .1.3.6.1.4.1.22253.310
    Error in packet
    Reason: (noSuchName) There is no such variable name in this MIB.
    Failed object: SNMPv2-SMI::enterprises.22253.310
    Usually I would include the required MIB in mrtg.cfg, like

    Code:
    LoadMIBs: /usr/local/share/snmp/mibs/UCD-SNMP-MIB.txt,/usr/local/share/snmp/mibs/TCP-MIB.txt,/usr/local/share/snmp/mibs/HOST-RESOURCES-MIB.txt
    
    Now I do not know where to go from here, as the OID is passed to snmp with php and I have no clue why snmpget does not accept litespeed OIDs .1.3.6.1.4.1.22253.XXX

    Thanks for any insight.

    PS. I start to like Litespeed better and better every day. 20 days left to try it out and I already see its powers :)

    PPS. I noticed that the enterprise tryout uses only one core. I gather this means you do not HAVE to buy the 4 core licence for Dual Woodcrests?
    Last edited: Jun 18, 2007
  2. mistwang

    mistwang LiteSpeed Staff

    I do not have a quick answer to your questions since we do not create a MIB for our SNMP stuff.
    But there is a better solution, check out

    http://www.litespeedtech.com/support/wiki/doku.php?id=litespeed_wiki:snmp_cacti_monitoring

    It is recommended but you don't have to buy n-core license to match number of cores on your server. Matching license will bring the best out of your server especially when you need to serve a lot of static files. The trial license is a 2-CPU license. however, if you use it with cPanel, you need to add a listener binding to the specific IP address associated with your vhost and have "Process 1" and "Process 2" checked to really put the 2-CPU license to good use.
  3. PSS

    PSS Member

    Thanks for your quick reply.

    I probably need eventually to install Cacti although I am reluctant to use MySQL to anything else than serve vbulletin and other intensive databases.

    I do not use any control panels. Does 4 CPU version help php parsing?
  4. mistwang

    mistwang LiteSpeed Staff

    Does not help much on PHP as PHP run in their own processes.

Share This Page