SNMP MIB Data type - equivalent to Erlang "atom" ?
Serge Aleynikov
serge@REDACTED
Wed Jun 22 23:41:09 CEST 2005
True. Though, in that case anyatom can't really be any atom, but a
predefined enumerated set.
Martin Bjorklund wrote:
> Serge Aleynikov <serge@REDACTED> wrote:
>
>>You need to use DisplayString type in your MIB, and use
>>{value, atom_to_list(anyatom)} in your instrumentation function.
>
>
> Or use an integer enum in the MIB. The agent will convert the atom to
> the appropriate integer.
>
>
> /martin
>
>
>
>
>>Also, to answer your former question on accessing the agent from other
>>hosts - remove {intAgentIpAddress, [127,0,0,1]} entry from agent.config
>>file, or change that IP to the public one assigned to the interface.
>>
>>Serge
>>
>>Sanjaya Vitharana wrote:
>>
>>>Hi....!!!,
>>>
>>>!!!!!....Can any body help me to sort this out.....!!!!
>>>
>>>What is the MIB Data type equivalent to "atom" ?
>>>
>>>For Example:
>>>
>>>assume that I have a function:
>>>----------------------------------------------------
>>>getAtom(get) ->
>>> {value, anyatom}. %% note that returning value is an atom of "anyatom"
>>>----------------------------------------------------
>>>How Should I map it in MIB (What is the Type ?)
>>>
>>> myAtom OBJECT-TYPE
>>> SYNTAX ***What is the equivalent data type to put
>>>here*** %%I know How to handle INTEGER/DisplayString (FROM
>>>RFC1213-MIB). But atom ???
>>> ACCESS read-write
>>> STATUS mandatory
>>> DESCRIPTION
>>> ""
>>> ::= { myObjects 1 }
>>>----------------------------------------------------
>>>Regards,
>>>
>>>Sanjaya
>
>
--
Serge Aleynikov
R&D Telecom, IDT Corp.
Tel: (973) 438-3436
Fax: (973) 438-1464
serge@REDACTED
More information about the erlang-questions
mailing list