On Jun 4, 2010, at 7:26 AM, Dejan Muhamedagic wrote:

> On Fri, Jun 04, 2010 at 07:21:53AM -0400, Vadym Chepkov wrote:
>> 
>> On Jun 4, 2010, at 7:04 AM, Dejan Muhamedagic wrote:
>>> Can you please test the changes. You can pull the new version
>>> from the repository for testing.
>> 
>> 
>> I just have, and your patch is wrong, sorry, for the reason I described 
>> earlier. 
>> 
>> local set_result is a function, and it always returns 0 if is called inside 
>> a function.
> 
> Oh. Thanks for spotting that! Fixed now.


You missed the spot:
There is nothing useful in snmp_result if snmpwalk fails.


        # Get outlet number from device
    
        local outlet_num=1
        local snmp_result=`snmpwalk -v1 -c $community $pduip $names_oid 2>&1`

        local names=`echo "$snmp_result" | cut -f2 -d'"' | tr ' ' '_' | tr 
'\012' ' '`


Vadym



_______________________________________________
Linux-HA mailing list
[email protected]
http://lists.linux-ha.org/mailman/listinfo/linux-ha
See also: http://linux-ha.org/ReportingProblems

Reply via email to