Hi Anton Pak,
Is there any function to get resources of a specified handler? for example,
we have a handler id (of oHpiHandlerIdT type), we want to get all resource
entries belonging to this handler.
I know a function, that is saHpiRptEntryGet(), but with it, we will get
all resource entries of all available handlers.
Thanks,
Hung
On Wed, May 30, 2012 at 12:56 PM, Anton Pak <[email protected]>wrote:
> Hi Hung,
>
> Perhaps you have no test_agent plug-in installed.
> Let's change it to libsimulator.
>
> The config stanza:
>
> handler libsimulator {
> entity_root = "{SYSTEM_CHASSIS,10}"
> name = "test10"
> }
>
> goes to python code:
>
> d = { "plugin" : "libsimulator", "entity_root" : "{SYSTEM_CHASSIS,10}",
> "name" : "test10" }
>
>
> Anton Pak
>
>
> On Wed, 30 May 2012 08:48:08 +0400, Hung Ta <[email protected]> wrote:
>
> Hi Anton Pak,
>>
>> I've tried.
>>
>> Basically, your examples work. However, it failed at creating a new
>> handler: in my case, there are some handlers (libsimulator) created first.
>> After that, I run example_handlers.py. It deleted a handler OK, but
>> created
>> another handler (libtest_agent) failed.
>>
>> What do you think of this?
>>
>> Thanks,
>> Hung
>>
>> On Wed, May 30, 2012 at 4:46 AM, Anton Pak <[email protected]>**
>> wrote:
>>
>> Hi Hung,
>>>
>>> I've just added initial support in openhpi svn trunk (rev #7446).
>>> Could you try it?
>>>
>>> Some instructions:
>>> ==============================****==============
>>>
>>> run openhpi daemon with several handlers (for example libsimulator,
>>> libdyn_simulator, libtest_agent)
>>> mkdir openhpi
>>> cd openhpi
>>> svn checkout https://openhpi.svn.sf.net/****
>>> svnroot/openhpi/openhpi/trunk<https://openhpi.svn.sf.net/**svnroot/openhpi/openhpi/trunk>
>>> <**https://openhpi.svn.sf.net/**svnroot/openhpi/openhpi/trunk<https://openhpi.svn.sf.net/svnroot/openhpi/openhpi/trunk>
>>> >
>>>
>>> cd trunk
>>> cd baselibs/python
>>> ./example_lsres.py
>>> ./example_handlers.py
>>>
>>> Anton Pak
>>>
>>>
>>>
>>> On Tue, 29 May 2012 08:00:45 +0400, Hung Ta <[email protected]>
>>> wrote:
>>>
>>> Hi Anton Pak,
>>>
>>>>
>>>> I was busy on another project for a time. Now, I get back the issue.
>>>>
>>>> Researching the source code of py-openhpi-1.1 (openhpi_wrap.c), it seems
>>>> that some ohpi wrap functions don't have valid arguments. For example,
>>>> there is missing sessionid in _wrap_oHpiHandlerCreate(),
>>>> _wrap_oHpiHandlerDestroy() ... So, I tried to fix them by fixing ohpi.i:
>>>> declare oHpiHandlerCreate(), oHpiHandlerDestroy()... with valid
>>>> argument.
>>>> Then, rebuilt and tested but I still get the same problem.
>>>>
>>>> It's great if you can support me to add oHpiHandlerXXX into openhpi
>>>> python
>>>> package.
>>>>
>>>> Thank you so much for your support.
>>>>
>>>> Regards,
>>>> Hung
>>>>
>>>> On Wed, May 9, 2012 at 2:58 PM, Anton Pak <[email protected]>
>>>> wrote:
>>>>
>>>> Hi Hung!
>>>>
>>>>>
>>>>> py-openhpi has been abandoned for years.
>>>>> There is new python baselib in 3.1.0 but with limited support for
>>>>> oHpiXXX
>>>>> functions.
>>>>> I can add oHpiHandlerXXX support if you need it.
>>>>>
>>>>> Anton Pak
>>>>>
>>>>>
>>>>> On Wed, 09 May 2012 11:55:42 +0400, Hung Ta <[email protected]>
>>>>> wrote:
>>>>>
>>>>> Hi Uli,
>>>>>
>>>>>
>>>>>> That is very useful. Thanks a lot!
>>>>>>
>>>>>> I've tested with openhpi release in C, and it worked fine. But with
>>>>>> PyOpenHPI (py-openhpi-1.1.tar.gz) (the openhpi was ported to python),
>>>>>> it
>>>>>> seems not worked well.
>>>>>> I installed py-openhpi-1.1 and created a simple example that creates a
>>>>>> new
>>>>>> handler using oHpiHandlerCreate() in python (as some examples written
>>>>>> in
>>>>>> README), it always returns err = -1015. Other functions
>>>>>> (oHpiHandlerGetNext, oHpiHandlerInfo...) have the same result.
>>>>>>
>>>>>> Is py-openhpi-1.1.tar.gz stable?
>>>>>>
>>>>>> Do you or anyone test this and know why?
>>>>>>
>>>>>> Appreciate your reply.
>>>>>>
>>>>>> Thanks,
>>>>>> hung
>>>>>>
>>>>>> On Tue, May 8, 2012 at 2:49 PM, Ulrich Kleber <
>>>>>> [email protected]
>>>>>> >*
>>>>>> *wrote:
>>>>>>
>>>>>> Hi,****
>>>>>>
>>>>>>
>>>>>>>
>>>>>>> OpenHPI has a few additional APIs to manage the OpenHPI specific
>>>>>>> configuration dynamically.****
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>>
>>>>>>> In openhpid/oHpi.c you find the handler operation APIs which manage
>>>>>>> plugin
>>>>>>> instances:****
>>>>>>>
>>>>>>> oHpiHandlerCreate****
>>>>>>>
>>>>>>> oHpiHandlerDestroy****
>>>>>>>
>>>>>>> oHpiHandlerInfo****
>>>>>>>
>>>>>>> oHpiHandlerGetNext****
>>>>>>>
>>>>>>> oHpiHandlerFind****
>>>>>>>
>>>>>>> oHpiHandlerRetry****
>>>>>>>
>>>>>>> and other functions to address OpenHPI configuration.****
>>>>>>>
>>>>>>> The description there is pretty short, but should tell you what they
>>>>>>> do.**
>>>>>>> **
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>>
>>>>>>> You can find coding examples in the clients (clients/ohhandler.c) and
>>>>>>> you
>>>>>>> can use these client programs also in your testbed.****
>>>>>>>
>>>>>>> There are man entries as well.****
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>>
>>>>>>> That way you should be able to reconnect to a shelf manager or change
>>>>>>> the
>>>>>>> connection method.****
>>>>>>>
>>>>>>>
>>>>>>> Only the conf files are not changed by these programs. The changes
>>>>>>> will
>>>>>>> be
>>>>>>> not persistent.****
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>> Cheers,****
>>>>>>>
>>>>>>> Uli****
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>> *From:* Hung Ta [mailto:[email protected]]
>>>>>>> *Sent:* Dienstag, 8. Mai 2012 04:21
>>>>>>> *To:* openhpi-devel@lists.****sourcefo**rge.net <
>>>>>>> http://sourceforge.net>
>>>>>>>
>>>>>>> <openhpi-devel@lists.**sourcef**orge.net <http://sourceforge.net><
>>>>>>> openhpi-devel@lists.**sourceforge.net<[email protected]>
>>>>>>> >
>>>>>>> >
>>>>>>>
>>>>>>> *Subject:* Re: [Openhpi-devel] [openhpid] How to connect to Shelf
>>>>>>> manager
>>>>>>> without restart openhpi daemon****
>>>>>>>
>>>>>>> ** **
>>>>>>>
>>>>>>>
>>>>>>> Thank you for your reply, Mohan.
>>>>>>>
>>>>>>> I also think as yours.
>>>>>>>
>>>>>>> But digging into openhpi source code, I found a function which
>>>>>>> establishes connection to shelf manager, that is
>>>>>>> ipmi_lan_setup_con().
>>>>>>> This function is one of the device driver functions that allows upper
>>>>>>> application to talk to IPMI hardware platform. It takes
>>>>>>>
>>>>>>> ****
>>>>>>>
>>>>>>>
>>>>>>> configuration parameters and make a connection to IPMI hardware
>>>>>>> platform.
>>>>>>>
>>>>>>> But I wonder if we provide configuration parameter changes and invoke
>>>>>>> it, the daemon still works or not? Is it the function that
>>>>>>> meets our purpose?
>>>>>>>
>>>>>>> ****
>>>>>>>
>>>>>>>
>>>>>>> Thanks,
>>>>>>> hung
>>>>>>>
>>>>>>> >Hung,****
>>>>>>>
>>>>>>> >** **
>>>>>>>
>>>>>>> >I do not know of an API that can dynamically read the changes in
>>>>>>> the****
>>>>>>>
>>>>>>> >openhpi.conf file. When the configuration is changed, the daemon
>>>>>>> needs****
>>>>>>>
>>>>>>> >to be restarted. ****
>>>>>>>
>>>>>>> >Complete list of the API's are in the HPI specification which can
>>>>>>> be****
>>>>>>>
>>>>>>> >downloaded from ****
>>>>>>>
>>>>>>> >http://www.saforum.org/******Service-Availability-Forum---******<http://www.saforum.org/****Service-Availability-Forum---****>
>>>>>>> <http://www.saforum.org/****Service-Availability-Forum---****<http://www.saforum.org/**Service-Availability-Forum---**>
>>>>>>> >
>>>>>>> Specification:-Hardware-******Platform-Interface-%28HPI%29~******
>>>>>>> 217308~16627.htm<http://www.****saforum.org/Service-**<http://saforum.org/Service-**>
>>>>>>> Availability-Forum---****Specification:-Hardware-**
>>>>>>> Platform-Interface-%28HPI%29%****7E217308%7E16627.htm<http://**
>>>>>>> www.saforum.org/Service-**Availability-Forum---**
>>>>>>> Specification:-Hardware-**Platform-Interface-%28HPI%29%**
>>>>>>> 7E217308%7E16627.htm<http://www.saforum.org/Service-Availability-Forum---Specification:-Hardware-Platform-Interface-%28HPI%29%7E217308%7E16627.htm>
>>>>>>> >
>>>>>>> ><
>>>>>>>
>>>>>>> http://www.saforum.org/******Service-Availability-Forum---******<http://www.saforum.org/****Service-Availability-Forum---****>
>>>>>>> <http://www.saforum.org/****Service-Availability-Forum---****<http://www.saforum.org/**Service-Availability-Forum---**>
>>>>>>> >
>>>>>>> Specification:-Hardware-******Platform-Interface-%28HPI%29%******
>>>>>>> 7E217308%7E16627.htm<http://****www.saforum.org/Service-**<http://www.saforum.org/Service-**>
>>>>>>> Availability-Forum---****Specification:-Hardware-**
>>>>>>>
>>>>>>> Platform-Interface-%28HPI%29%****7E217308%7E16627.htm<http://**
>>>>>>> www.saforum.org/Service-**Availability-Forum---**
>>>>>>> Specification:-Hardware-**Platform-Interface-%28HPI%29%**
>>>>>>> 7E217308%7E16627.htm<http://www.saforum.org/Service-Availability-Forum---Specification:-Hardware-Platform-Interface-%28HPI%29%7E217308%7E16627.htm>
>>>>>>> >
>>>>>>> >
>>>>>>>
>>>>>>> >****
>>>>>>>
>>>>>>> >** **
>>>>>>>
>>>>>>> >Mohan****
>>>>>>>
>>>>>>> >** **
>>>>>>>
>>>>>>> >** **
>>>>>>>
>>>>>>> >On Mon, 2012-05-07 at 10:52 +0700, Hung Ta wrote:****
>>>>>>>
>>>>>>> >> Hello openhpi experts,****
>>>>>>>
>>>>>>> >> ****
>>>>>>>
>>>>>>> >> I have a question would like to ask: assuming that there is an****
>>>>>>>
>>>>>>> >> openhpid being started ( and assuming IPMIDirect plugin was
>>>>>>> defined
>>>>>>> in****
>>>>>>>
>>>>>>> >> openhpi.conf). Later, there is a change in IPMIDirect config
>>>>>>> (e.g.****
>>>>>>>
>>>>>>> >> addr, port, authentication...), so is there any openhpi API able
>>>>>>> to****
>>>>>>>
>>>>>>> >> reconnect the shelf manager without restarting the openhpid
>>>>>>> daemon?
>>>>>>> In****
>>>>>>>
>>>>>>> >> this case, we just provide those changed config parameters and****
>>>>>>>
>>>>>>> >> reconnect to the shelf manager without restarting openhpid
>>>>>>> daemon.****
>>>>>>>
>>>>>>> >> ****
>>>>>>>
>>>>>>> >> Could you please help?****
>>>>>>>
>>>>>>> >>** **
>>>>>>>
>>>>>>> >> Thanks and regards,****
>>>>>>>
>>>>>>> >> hung ****
>>>>>>>
>>>>>>>
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Openhpi-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openhpi-devel