[EMAIL PROTECTED] wrote:
> 
> 
> 
> Giovanni;
> 
> Thanks for responding to my posting. The only problem that I really have
> with the OPAQUE data types is that they do not appear in/from the MIB when
> one uses the type field (provided and supported in the perl scripts). This
> means that I cannot build type-checking into the code generated from the
> perl script as this does not give me the type ASN_OPAQUE_FLOAT, but rather
> an ASN_OCTET_STR (if I use the SMI definitions from the example MIBs as
> provided within the Net SNMP package).
> 
> What is frustrating is that the Net SNMP code utilises the ASN_BOOLEAN and
> ASN_FLOAT/DOUBLE types (as defined in the asn1_degs.h file) and even
> provides parser functions for them, however, they are not supported by the
> SNMP.dll (used by the perl scripts). So, on the one hand, I can generate,
> send, receive and interpret variables of these types, but cannot "see"
> these types within code generated via the perl scripts.
> 
> Aarrgghh!!
> 
> I am willing to make the changes (locally) to the SNMP dll myself to extend
> the functionality, if only someone could advise me of where I need to make
> the changes and how the whole malarky with the the .XS file is supposed to
> work
> 
> Regards
> 
> Martin. Frustrated of Munich.
> 
Hi Martin,

We should keep this on the list...

I think there may be a way to add better support for these extended types to the
perl mod...to the extent there is support in the core package...

however, if you use 'UseSprintVal' option in the perl mod...doesn't this format
the output appropriately. Wes referred me to the load avg. mib in the agent now
as an example.

[EMAIL PROTECTED] ~]$ perl -MSNMP -e '$sess=new
SNMP::Session(UseSprintValue=>1,Version=>1,Community=>"public");
$val=$sess->get("laLoadFloat.1");print "$SNMP::MIB{laLoadFloat}{syntax},
$SNMP::MIB{laLoadFloat}{type}, $SNMP::MIB{laLoadFloat}{textualConvention}: 
$val\n";'
Float, OPAQUE, Float: 0.240000
[EMAIL PROTECTED] ~]$ snmpget -v 1 -c public localhost 'laLoadFloat.1'
UCD-SNMP-MIB::laLoadFloat.1 = Opaque: Float: 0.270000

looks good here...will this work for you?

let me know some specific of what you think the perl mod sold be doing different
here.

-G


-------------------------------------------------------
All the advantages of Linux Managed Hosting--Without the Cost and Risk!
Fully trained technicians. The highest number of Red Hat certifications in
the hosting industry. Fanatical Support. Click to learn more
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=107521&bid=248729&dat=121642
_______________________________________________
Net-snmp-coders mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/net-snmp-coders

Reply via email to