Hi again, On Thu, Sep 13, 2012 at 02:57:54PM +0300, Vladislav Bogdanov wrote: > Hi Dejan, all, > > current crm shell (b58a3398bf11) can not parse node 'id' attribute when > running on corosync 2: > > # crm configure show |grep xml > INFO: object 1074005258 cannot be represented in the CLI notation > INFO: object 1090782474 cannot be represented in the CLI notation > INFO: object 1107559690 cannot be represented in the CLI notation > INFO: object 1124336906 cannot be represented in the CLI notation > xml <node id="1074005258" uname="vd01-a"> \ > xml <node id="1090782474" uname="vd01-b"> \ > xml <node id="1107559690" uname="vd01-c"> \ > xml <node id="1124336906" uname="vd01-d"> \
Can you please try the attached patch. Cheers, Dejan > > Best, > Vladislav > > _______________________________________________ > Pacemaker mailing list: Pacemaker@oss.clusterlabs.org > http://oss.clusterlabs.org/mailman/listinfo/pacemaker > > Project Home: http://www.clusterlabs.org > Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf > Bugs: http://bugs.clusterlabs.org
diff -r b58a3398bf11 modules/cibconfig.py --- a/modules/cibconfig.py Thu Sep 13 12:19:56 2012 +0200 +++ b/modules/cibconfig.py Thu Sep 13 14:41:04 2012 +0200 @@ -1005,7 +1005,7 @@ class CibNode(CibObject): s = '%s $id="%s"' % (s, self.obj_id) s = '%s %s' % (s, cli_display.id(uname)) type = self.node.getAttribute("type") - if type != vars.node_default_type: + if type and type != vars.node_default_type: s = '%s:%s' % (s, type) return s def cli_list2node(self,cli_list,oldnode): @@ -1017,8 +1017,7 @@ class CibNode(CibObject): if not obj_id: return None type = find_value(head[1],"type") - if not type: - type = vars.node_default_type + if type: head[1].append(["type",type]) headnode = mkxmlsimple(head,get_topnode(cib_factory.doc,self.parent_type),'node') id_hint = headnode.getAttribute("uname")
_______________________________________________ Pacemaker mailing list: Pacemaker@oss.clusterlabs.org http://oss.clusterlabs.org/mailman/listinfo/pacemaker Project Home: http://www.clusterlabs.org Getting started: http://www.clusterlabs.org/doc/Cluster_from_Scratch.pdf Bugs: http://bugs.clusterlabs.org