Ad Widget

Collapse

zabbix_sender errors

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Yello
    Senior Member
    • Apr 2011
    • 309

    #1

    zabbix_sender errors

    Hi,
    I have a script which is run from cron and parses some xml for stats to pass to zabbix via zabbix_sender. The script works but I'm seeing some updates fail:

    Info from server: "Processed 0 Failed 1 Total 1 Seconds spent 0.001578"
    sent: 1; skipped: 0; total: 1
    Info from server: "Processed 0 Failed 1 Total 1 Seconds spent 0.001366"
    sent: 1; skipped: 0; total: 1
    Info from server: "Processed 1 Failed 0 Total 1 Seconds spent 0.000040"
    sent: 1; skipped: 0; total: 1
    Info from server: "Processed 1 Failed 0 Total 1 Seconds spent 0.000043"

    My code that does the inserts looks like this:

    foreach($sender_data[$host] as $key=>$value) {
    if (ZabbixItem::apiObjExists('item',array('key_'=>$ke y,'host'=>$host))) {
    shell_exec("$zabbix_sender -c $zabbix_agent_cfg -s $host -k $key -o $value 2>&1 >> $LOGPATH");
    }
    else {
    shell_exec("echo Item update failed for $host:$key. Item key not found.\n 2>&1 >> $LOGPATH");
    }
    }

    Are my updates failing because I'm processing the updates via a loop? What is the recommended method for bulk loading significant numbers of stats?


    Regards,
    David
  • Yello
    Senior Member
    • Apr 2011
    • 309

    #2
    Hi,
    I realised later on that I had some type mismatch issues. Once I fixed the items all was ok.


    Regards,
    David

    Comment

    Working...