From cvincent at linux.vnet.ibm.com Thu Nov 4 21:50:32 2010 From: cvincent at linux.vnet.ibm.com (Chip Vincent) Date: Thu, 04 Nov 2010 17:50:32 -0400 Subject: [Libvirt-cim] [PATCH] Missing namespace from migration indications In-Reply-To: References: Message-ID: <4CD32AA8.5010407@linux.vnet.ibm.com> +1 Sharad Mishra wrote: > # HG changeset patch > # User Sharad Mishra > # Date 1286382665 25200 > # Node ID a97431f4b91e5d4009e9f2e70dea7d7bc85464f5 > # Parent d4beac1f62c6ad131f584b04460eb807aa46f0d4 > Missing namespace from migration indications > > This patch passes ObjectPath inside the indication when calling CBDeliverIndication. > > Signed-off-by: Sharad Mishra > > diff -r d4beac1f62c6 -r a97431f4b91e std_indication.c > --- a/std_indication.c Tue Sep 14 21:19:05 2010 -0400 > +++ b/std_indication.c Wed Oct 06 09:31:05 2010 -0700 > @@ -98,13 +98,15 @@ > > static CMPIStatus default_raise(const CMPIBroker *broker, > const CMPIContext *context, > + CMPIObjectPath *ref, > CMPIInstance *ind) > { > - CMPIObjectPath *ref; > CMPIStatus s = {CMPI_RC_OK, NULL}; > > - ref = CMGetObjectPath(ind, NULL); > - > + s = CMSetObjectPath(ind, ref); > + if (s.rc != CMPI_RC_OK) > + return s; > + > CBDeliverIndication(broker, > context, > NAMESPACE(ref), > @@ -114,13 +116,15 @@ > > static CMPIStatus raise(struct std_indication_ctx *ctx, > const CMPIContext *context, > - const CMPIArgs *argsin) > + const CMPIArgs *argsin, > + CMPIObjectPath *ref) > { > bool enabled; > CMPIInstance *inst; > CMPIStatus s = {CMPI_RC_OK, NULL}; > const char *ind_name = NULL; > > + CU_DEBUG("In raise"); > if (cu_get_inst_arg(argsin, "TheIndication", &inst) != CMPI_RC_OK) { > cu_statusf(ctx->brkr, &s, > CMPI_RC_ERR_FAILED, > @@ -136,6 +140,8 @@ > goto out; > } > > + CU_DEBUG("Indication is %s", ind_name); > + > enabled = is_ind_enabled(ctx, ind_name, &s); > if (s.rc != CMPI_RC_OK) { > CU_DEBUG("Problem checking enabled: '%s'", CMGetCharPtr(s.msg)); > @@ -146,13 +152,14 @@ > goto out; > > if (ctx->handler == NULL || ctx->handler->raise_fn == NULL) > - s = default_raise(ctx->brkr, context, inst); > + s = default_raise(ctx->brkr, context, ref, inst); > else > - s = ctx->handler->raise_fn(ctx->brkr, context, inst); > + s = ctx->handler->raise_fn(ctx->brkr, context, ref, inst); > > out: > return s; > } > + > CMPIStatus stdi_deliver(const CMPIBroker *broker, > const CMPIContext *ctx, > struct ind_args *args, > @@ -294,7 +301,7 @@ > CMPIStatus stdi_handler(CMPIMethodMI *self, > const CMPIContext *context, > const CMPIResult *results, > - const CMPIObjectPath *reference, > + CMPIObjectPath *reference, > const char *methodname, > const CMPIArgs *argsin, > CMPIArgs *argsout) > @@ -305,13 +312,13 @@ > if (STREQC(methodname, "TriggerIndications")) > s = trigger(ctx, context); > else if (STREQ(methodname, "RaiseIndication")) > - s = raise(ctx, context, argsin); > + s = raise(ctx, context, argsin, reference); > else > cu_statusf(ctx->brkr, &s, > CMPI_RC_ERR_FAILED, > "Invalid method"); > > - CMReturnDone(results); > + CMReturnDone(results); > return s; > } > > @@ -370,8 +377,15 @@ > CMPIArgs *argsout; > > op = CMNewObjectPath(broker, ns, type, &s); > - if (s.rc != CMPI_RC_OK) > + if ((op == NULL) || (s.rc != CMPI_RC_OK)) { > + CU_DEBUG("Unable to create path for indication %s", > + type); > + cu_statusf(broker, &s, > + CMPI_RC_ERR_FAILED, > + "Unable to create path for indication %s", > + type); > return s; > + } > > argsin = CMNewArgs(broker, &s); > if (s.rc != CMPI_RC_OK) > @@ -386,7 +400,7 @@ > return s; > > CBInvokeMethod(broker, context, op, method, argsin, argsout, &s); > - > + > return s; > } > > diff -r d4beac1f62c6 -r a97431f4b91e std_indication.h > --- a/std_indication.h Tue Sep 14 21:19:05 2010 -0400 > +++ b/std_indication.h Wed Oct 06 09:31:05 2010 -0700 > @@ -41,6 +41,7 @@ > > typedef CMPIStatus (*raise_indication_t)(const CMPIBroker *broker, > const CMPIContext *ctx, > + CMPIObjectPath *ref, > const CMPIInstance *ind); > > typedef CMPIStatus (*trigger_indication_t)(const CMPIContext *ctx); > @@ -134,7 +135,7 @@ > CMPIStatus stdi_handler(CMPIMethodMI *self, > const CMPIContext *context, > const CMPIResult *results, > - const CMPIObjectPath *reference, > + CMPIObjectPath *reference, > const char *methodname, > const CMPIArgs *argsin, > CMPIArgs *argsout); > > _______________________________________________ > Libvirt-cim mailing list > Libvirt-cim at redhat.com > https://www.redhat.com/mailman/listinfo/libvirt-cim > -- Chip Vincent Open Virtualization, Linux Technology Center IBM Systems & Technology Group phone: 919-254-4482, T/L 444-4482 email: cvincent at us.ibm.com From snmishra at us.ibm.com Wed Nov 17 18:06:06 2010 From: snmishra at us.ibm.com (Sharad Mishra) Date: Wed, 17 Nov 2010 10:06:06 -0800 Subject: [Libvirt-cim] [PATCH] Return profiles according to role In-Reply-To: <4CBDDE27.7030509@linux.vnet.ibm.com> References: <4CBDDE27.7030509@linux.vnet.ibm.com> Message-ID: +1 Sharad Mishra Open Virtualization Linux Technology Center IBM libvirt-cim-bounces at redhat.com wrote on 10/19/2010 11:06:31 AM: > Chip Vincent > Sent by: libvirt-cim-bounces at redhat.com > > 10/19/10 11:06 AM > > Please respond to > List for discussion and development of libvirt CIM > > To > > List for discussion and development of libvirt CIM > > cc > > Subject > > [Libvirt-cim] [PATCH] Return profiles according to role > > # HG changeset patch > # User Chip Vincent > # Date 1287510529 14400 > # Node ID 756b9699be781c251b45ba8e4d9163ef485719e0 > # Parent 13c765505895c9de34908d8f4d02c9a67fe4b907 > Return profiles according to role > > Signed-off-by: Chip Vincent > > diff -r 13c765505895 -r 756b9699be78 src/Virt_ReferencedProfile.c > --- a/src/Virt_ReferencedProfile.c Thu Oct 14 11:51:44 2010 -0400 > +++ b/src/Virt_ReferencedProfile.c Tue Oct 19 13:48:49 2010 -0400 > @@ -126,7 +126,14 @@ > if (conn == NULL) > goto out; > > - s = get_scoping_prof_by_source(ref, info, conn, source, list); > + // NOTE: Autonomous or scoping profiles are dependent profiles. > + // Return them according to role > + if ((!source->scoping_profile || > + STREQC(source->reg_name, "System Virtualization")) && > + info->role && !STREQC(info->role, "Dependent")) > + goto out; > + > + s = get_scoping_prof_by_source(ref, info, conn, source, list); > if (s.rc != CMPI_RC_OK) > goto out; > > -- > Chip Vincent > Open Virtualization, Linux Technology Center > IBM Systems & Technology Group > phone: 919-254-4482, T/L 444-4482 > email: cvincent at us.ibm.com > > _______________________________________________ > Libvirt-cim mailing list > Libvirt-cim at redhat.com > https://www.redhat.com/mailman/listinfo/libvirt-cim -------------- next part -------------- An HTML attachment was scrubbed... URL: From snmishra at us.ibm.com Wed Nov 17 18:08:41 2010 From: snmishra at us.ibm.com (Sharad Mishra) Date: Wed, 17 Nov 2010 10:08:41 -0800 Subject: [Libvirt-cim] [PATCH] This patch adds back the fake_host() functions and groups providers into a single process when used with OpenPegasus In-Reply-To: <4CC762A9.4030302@linux.vnet.ibm.com> References: <4CC762A9.4030302@linux.vnet.ibm.com> Message-ID: +1 This patch and "Return profiles according to roles" patch has been reviewed but I would like our test team to pick up the latest build with these patches and run the entire cimtest. Thanks Sharad Mishra Open Virtualization Linux Technology Center IBM libvirt-cim-bounces at redhat.com wrote on 10/26/2010 04:22:17 PM: > Chip Vincent > Sent by: libvirt-cim-bounces at redhat.com > > 10/26/10 04:22 PM > > Please respond to > List for discussion and development of libvirt CIM > > To > > List for discussion and development of libvirt CIM > > cc > > Subject > > [Libvirt-cim] [PATCH] This patch adds back the fake_host() functions > and groups providers into a single process when used with OpenPegasus > > # HG changeset patch > # User Chip Vincent > # Date 1288135043 14400 > # Node ID 0a19c3e95fdf1fdf263d150470333ecfb566115b > # Parent 756b9699be781c251b45ba8e4d9163ef485719e0 > This patch adds back the fake_host() functions and groups providers into > a single process when used with OpenPegasus. > > fake_host() is needed to ensure keys are propagated properly, and moving > providers into a single process is needed to ensure indications work as > expected (there are dependencies between some providers that do not work > as expected when they are run in different processes). > > Signed-off-by: Chip Vincent > > diff -r 756b9699be78 -r 0a19c3e95fdf provider-register.sh > --- a/provider-register.sh Tue Oct 19 13:48:49 2010 -0400 > +++ b/provider-register.sh Tue Oct 26 19:17:23 2010 -0400 > @@ -61,6 +61,7 @@ > Version = "2.0.0"; > InterfaceType = "CMPI"; > InterfaceVersion = "2.0.0"; > + ModuleGroupName = "libvirt-cim"; > }; > > EOFPM > diff -r 756b9699be78 -r 0a19c3e95fdf src/Virt_HostSystem.c > --- a/src/Virt_HostSystem.c Tue Oct 19 13:48:49 2010 -0400 > +++ b/src/Virt_HostSystem.c Tue Oct 26 19:17:23 2010 -0400 > @@ -38,7 +38,6 @@ > > const static CMPIBroker *_BROKER; > > -/* > static int resolve_host(char *host, char *buf, int size) > { > struct hostent *he; > @@ -76,9 +75,7 @@ > > return 0; > } > -*/ > > -/* > static int get_fqdn(char *buf, int size) > { > char host[256]; > @@ -96,9 +93,7 @@ > > return ret; > } > -*/ > > -/* > static int set_host_system_properties(CMPIInstance *instance) > { > CMPIStatus s = {CMPI_RC_OK, NULL}; > @@ -119,9 +114,7 @@ > > return 1; > } > -*/ > > -/* > static CMPIStatus fake_host(const CMPIBroker *broker, > const CMPIObjectPath *reference, > CMPIInstance **_inst) > @@ -157,7 +150,6 @@ > > return s; > } > -*/ > > CMPIStatus get_host(const CMPIBroker *broker, > const CMPIContext *context, > @@ -167,6 +159,8 @@ > { > CMPIStatus s = {CMPI_RC_OK, NULL}; > > + s = fake_host(broker, reference, _inst); > + > if (!is_get_inst && (s.rc == CMPI_RC_ERR_NOT_FOUND)) { > /* This is not an error */ > return (CMPIStatus){CMPI_RC_OK, NULL}; > > -- > Chip Vincent > Open Virtualization, Linux Technology Center > IBM Systems & Technology Group > phone: 919-254-4482, T/L 444-4482 > email: cvincent at us.ibm.com > > _______________________________________________ > Libvirt-cim mailing list > Libvirt-cim at redhat.com > https://www.redhat.com/mailman/listinfo/libvirt-cim -------------- next part -------------- An HTML attachment was scrubbed... URL: From ancoron at chaoslayer.de Thu Nov 25 23:33:39 2010 From: ancoron at chaoslayer.de (Ancoron Luciferis) Date: Fri, 26 Nov 2010 00:33:39 +0100 Subject: [Libvirt-cim] compiling/linking under debian/ubuntu Message-ID: <4CEEF253.3090302@chaoslayer.de> Hi *, I'm currently trying to figure out how to build and install libvirt-cim on one of my Ubuntu boxes. I have all requirements met but during 'make install' I get this: /usr/bin/ld: cannot find -lVirt_VirtualSystemSnapshotService collect2: ld returned 1 exit status libtool: install: error: relink `libVirt_ComputerSystem.la' with the above command before installing it make[3]: *** [install-providerLTLIBRARIES] Error 1 Well, the mentioned library is there: src/.libs/libVirt_VirtualSystemSnapshotService.a src/.libs/libVirt_VirtualSystemSnapshotService.la src/.libs/libVirt_VirtualSystemSnapshotService.lai src/.libs/libVirt_VirtualSystemSnapshotService.so src/.libs/libVirt_VirtualSystemSnapshotService.so.0 src/.libs/libVirt_VirtualSystemSnapshotService.so.0.0.0 Could someone help me with that as I'm not that familiar with the details of shared library linking yet. I attached a full output of: make preinstall make sudo make install Thanx in advance, Ancoron -------------- next part -------------- A non-text attachment was scrubbed... Name: libvirt-cim-build.log Type: text/x-log Size: 163794 bytes Desc: not available URL: From cvincent at linux.vnet.ibm.com Tue Nov 30 18:37:44 2010 From: cvincent at linux.vnet.ibm.com (Chip Vincent) Date: Tue, 30 Nov 2010 13:37:44 -0500 Subject: [Libvirt-cim] [PATCH] This patch adds back the fake_host() functions and groups providers into a single process when used with OpenPegasus In-Reply-To: References: <4CC762A9.4030302@linux.vnet.ibm.com> Message-ID: <4CF54478.7000605@linux.vnet.ibm.com> It appears that Pegasus 2.9.1, the version that ships with RHEL 6, does not support the "ModuleGroupName" property. That was added in Pegasus 2.6.2. Therefore, I have ommited that change from upstream. I'll create a separate patch to detect the Pegasus version and selective add that property later. -- Chip Vincent Open Virtualization, Linux Technology Center IBM Systems & Technology Group phone: 919-254-4482, T/L 444-4482 email: cvincent at us.ibm.com Sharad Mishra wrote: > > +1 > > This patch and "Return profiles according to roles" patch has been > reviewed but I would like our test team to pick up the latest build > with these patches and run the entire cimtest. > > Thanks > Sharad Mishra > Open Virtualization > Linux Technology Center > IBM > > libvirt-cim-bounces at redhat.com wrote on 10/26/2010 04:22:17 PM: > > > Chip Vincent > > Sent by: libvirt-cim-bounces at redhat.com > > > > 10/26/10 04:22 PM > > > > Please respond to > > List for discussion and development of libvirt CIM > > > > > To > > > > List for discussion and development of libvirt CIM > > > > > cc > > > > Subject > > > > [Libvirt-cim] [PATCH] This patch adds back the fake_host() functions > > and groups providers into a single process when used with OpenPegasus > > > > # HG changeset patch > > # User Chip Vincent > > # Date 1288135043 14400 > > # Node ID 0a19c3e95fdf1fdf263d150470333ecfb566115b > > # Parent 756b9699be781c251b45ba8e4d9163ef485719e0 > > This patch adds back the fake_host() functions and groups providers > into > > a single process when used with OpenPegasus. > > > > fake_host() is needed to ensure keys are propagated properly, and > moving > > providers into a single process is needed to ensure indications work as > > expected (there are dependencies between some providers that do not > work > > as expected when they are run in different processes). > > > > Signed-off-by: Chip Vincent > > > > diff -r 756b9699be78 -r 0a19c3e95fdf provider-register.sh > > --- a/provider-register.sh Tue Oct 19 13:48:49 2010 -0400 > > +++ b/provider-register.sh Tue Oct 26 19:17:23 2010 -0400 > > @@ -61,6 +61,7 @@ > > Version = "2.0.0"; > > InterfaceType = "CMPI"; > > InterfaceVersion = "2.0.0"; > > + ModuleGroupName = "libvirt-cim"; > > }; > > > > EOFPM > > diff -r 756b9699be78 -r 0a19c3e95fdf src/Virt_HostSystem.c > > --- a/src/Virt_HostSystem.c Tue Oct 19 13:48:49 2010 -0400 > > +++ b/src/Virt_HostSystem.c Tue Oct 26 19:17:23 2010 -0400 > > @@ -38,7 +38,6 @@ > > > > const static CMPIBroker *_BROKER; > > > > -/* > > static int resolve_host(char *host, char *buf, int size) > > { > > struct hostent *he; > > @@ -76,9 +75,7 @@ > > > > return 0; > > } > > -*/ > > > > -/* > > static int get_fqdn(char *buf, int size) > > { > > char host[256]; > > @@ -96,9 +93,7 @@ > > > > return ret; > > } > > -*/ > > > > -/* > > static int set_host_system_properties(CMPIInstance *instance) > > { > > CMPIStatus s = {CMPI_RC_OK, NULL}; > > @@ -119,9 +114,7 @@ > > > > return 1; > > } > > -*/ > > > > -/* > > static CMPIStatus fake_host(const CMPIBroker *broker, > > const CMPIObjectPath *reference, > > CMPIInstance **_inst) > > @@ -157,7 +150,6 @@ > > > > return s; > > } > > -*/ > > > > CMPIStatus get_host(const CMPIBroker *broker, > > const CMPIContext *context, > > @@ -167,6 +159,8 @@ > > { > > CMPIStatus s = {CMPI_RC_OK, NULL}; > > > > + s = fake_host(broker, reference, _inst); > > + > > if (!is_get_inst && (s.rc == CMPI_RC_ERR_NOT_FOUND)) { > > /* This is not an error */ > > return (CMPIStatus){CMPI_RC_OK, NULL}; > > > > -- > > Chip Vincent > > Open Virtualization, Linux Technology Center > > IBM Systems & Technology Group > > phone: 919-254-4482, T/L 444-4482 > > email: cvincent at us.ibm.com > > > > _______________________________________________ > > Libvirt-cim mailing list > > Libvirt-cim at redhat.com > > https://www.redhat.com/mailman/listinfo/libvirt-cim > > ------------------------------------------------------------------------ > > _______________________________________________ > Libvirt-cim mailing list > Libvirt-cim at redhat.com > https://www.redhat.com/mailman/listinfo/libvirt-cim