Bug 1568353
Summary: | "pcs resource update" should not create an empty meta-attributes element | ||||||
---|---|---|---|---|---|---|---|
Product: | Red Hat Enterprise Linux 7 | Reporter: | Tomas Jelinek <tojeline> | ||||
Component: | pcs | Assignee: | Tomas Jelinek <tojeline> | ||||
Status: | CLOSED ERRATA | QA Contact: | cluster-qe <cluster-qe> | ||||
Severity: | unspecified | Docs Contact: | |||||
Priority: | medium | ||||||
Version: | 7.5 | CC: | cfeist, cluster-maint, idevat, jpokorny, omular, phagara, rsteiger, tojeline | ||||
Target Milestone: | rc | Keywords: | EasyFix | ||||
Target Release: | --- | ||||||
Hardware: | Unspecified | ||||||
OS: | Unspecified | ||||||
Whiteboard: | |||||||
Fixed In Version: | pcs-0.9.165-1.el7 | Doc Type: | Bug Fix | ||||
Doc Text: |
Cause:
The user runs the "pcs resource update" command on changing no meta attributes on a resource with no defined meta attributes.
Consequence:
An empty meta_attributes element is created in the CIB for the resource.
Fix:
Do not create an empty meta_attributes element on resource update.
Result:
An empty meta_attributes element is not created during "pcs resource update"
|
Story Points: | --- | ||||
Clone Of: | Environment: | ||||||
Last Closed: | 2018-10-30 08:06:06 UTC | Type: | Bug | ||||
Regression: | --- | Mount Type: | --- | ||||
Documentation: | --- | CRM: | |||||
Verified Versions: | Category: | --- | |||||
oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
Cloudforms Team: | --- | Target Upstream Version: | |||||
Embargoed: | |||||||
Attachments: |
|
Description
Tomas Jelinek
2018-04-17 10:32:32 UTC
Created attachment 1422994 [details]
proposed fix
Note that "cibadmin --upgrade" will drop some of these "orphaned" elements automatically, because that's how upgrade-2.10.xsl works. After Fix: [ant ~] $ rpm -q pcs pcs-snmp pcs-0.9.165-1.el7.x86_64 pcs-snmp-0.9.165-1.el7.x86_64 [ant ~] $ pcs resource create dummy ocf:pacemaker:Dummy [ant ~] $ pcs cluster cib | grep -A 10 -m 1 'id="dummy"'|grep meta [ant ~] $ pcs resource update dummy fake=test [ant ~] $ pcs cluster cib | grep -A 10 -m 1 'id="dummy"'|grep meta [ant ~] $ See also [bug 1598197 comment 6] for why doing the pruning part (note this bug deals with just a tiny fraction of where it is in fact applicable) and overall "canonicalization" of the modification outcomes is important to keep the (possibibly accumulated) bit rot away. (That's also what CIB 2 -> 3 upgrade process autonomously triggers for the parts it effectively touches in the course of the upgrade, per [comment 3]). Therefore might be worth (eventually) reviewing other similar parts as well. Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2018:3066 |