Re: Execution Error
Marek Szermutzky <[email protected]>
| Newsgroups | gmane.network.open-pegasus.general |
|---|---|
| Message-ID | <OF7C25A66F.1CCDABA7-ONC1257A3E.00577A24-C1257A3E.00599C3E@de.ibm.com> |
Hi Manis!
An error as: "Provider
is not a CMPI style provider. Cannot find ProviderName_Create<mi-type>MI
symbol."
usually is caused by the fact that the
<mi-name> used in your provider is not equal to the value of Name
property in registration mof.
instance of PG_ProviderModule
{
Description = "Skeleton
Provider";
Caption = "Skeleton
Provider";
Name
= "SkeletonProvider";
Vendor = "Manish";
Version = "2.0.0";
InterfaceType =
"CMPI";
InterfaceVersion
= "2.0.0";
Location = "SkeletonProvider";
};
CMPI requires as provider entry point
a function like:
CMPI<mi-type>MI* <mi-name>_Create_<mi-type>MI(
const CMPIBroker*,
const CMPIContext*,
CMPIStatus*);
with <mi-type> being Instance
and <mi-name> being SkeletonProvider in your example. So it would
in your case look like:
CMPIInstanceMI* SkeletonProvider_Create_InstanceMI(const
CMPIBroker* broker, const CMPIContext* context, CMPIStatus* rc);
Alternatively use the C provider
factory macros provided in cmpimacs.h.
@param pfx The prefix for all mandatory association provider functions.
This is a character
string without quotes.
Mandatory functions
are: <pfx>Cleanup, <pfx>EnumInstanceNames,
<pfx>EnumInstances,
<pfx>GetInstance, <pfx>
CreateInstance,
<pfx>SetInstance, <pfx>DeleteInstance and
<pfx>ExecQuery.
@param pn The provider
name under which this provider is registered.
This is a character
string without quotes.
@param broker The name
of the broker variable used by this macro to store
the CMPIBroker
pointer
@param hook A statement
that is executed within <pn>Create_InstanceMI
routine. This enables
you to perform additional initialization functions
and is normally
a function call like furtherInit(broker) or CMNoHook.
Use CMNoHook if
no further intialization is required.
@return The function
table of this instance provider.
CMInstanceMIStub(
Skeleton,
SkeletonProvider,
_broker,
CMNoHook);
which requires a static to hold the
broker and would have the CIM Server call for enumerateInstances in your
provider the following function:
static CMPIBroker * _broker;
CMPIStatus SkeletonEnumInstances(
CMPIInstanceMI
* mi,
CMPIContext
* ctx,
CMPIResult
* rslt,
CMPIObjectPath
* ref,
char
** properties)
Mit freundlichen Grüßen / Kind regards
Marek Szermutzky
Software Engineer / OpenPegasus Maintainer (PMC) and z/OS PlatformRep.
IBM Systems &Technology Group, Systems Software Development / z/OS
Capacity Management and Support
-------------------------------------------------------------------------------------------------------------------------------------------
IBM Deutschland
Schoenaicher Str. 220
71032 Boeblingen
Phone: +49-7031-16-5182
E-Mail: [email protected]
-------------------------------------------------------------------------------------------------------------------------------------------
IBM Deutschland Research & Development GmbH / Vorsitzender des Aufsichtsrats:
Martin Jetter
Geschäftsführung: Dirk Wittkopp
Sitz der Gesellschaft: Böblingen / Registergericht: Amtsgericht Stuttgart,
HRB 243294
From:
<[email protected]>
To:
<[email protected]>
Date:
17.07.2012 13:58
Subject:
Execution Error
----------
HI all,
Please help me to get rid of this error,
I have written a demo instance provider and I have
Successfully compiled the mof file as well
as the registeration mof.
But whenever I fired command to the instance
provider like gi, ei , ni etc.. its show me the error that
CIM_ERR_FAILED: ProviderLoadFailure
: <../../ProviderName.dll>
Provider is not a CMPI style provider.
Cannot find ProviderName_Create<mi-type>MI symbol.
Please give me valuable suggestion to solve
this as well as the reason of occurrence of such type of error.
Thanks and Regards
Manish
Please do not
print this email unless it is absolutely necessary.
The information contained in this electronic message and
any attachments to this message are intended for the exclusive use of the
addressee(s) and may contain proprietary, confidential or privileged information.
If you are not the intended recipient, you should not disseminate, distribute
or copy this e-mail. Please notify the sender immediately and destroy all
copies of this message and any attachments.
WARNING: Computer viruses can be transmitted via email.
The recipient should check this email and any attachments for the presence
of viruses. The company accepts no liability for any damage caused by any
virus transmitted by this email.
www.wipro.com