Bug 1286664 - pcsd: deleting groups/clones from older cluster returns Internal Server Error
pcsd: deleting groups/clones from older cluster returns Internal Server Error
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: pcs (Show other bugs)
7.2
Unspecified Unspecified
medium Severity unspecified
: rc
: ---
Assigned To: Ondrej Mular
cluster-qe@redhat.com
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2015-11-30 08:05 EST by Radek Steiger
Modified: 2016-11-03 16:55 EDT (History)
4 users (show)

See Also:
Fixed In Version: pcs-0.9.151-1.el7
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-11-03 16:55:54 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:2596 normal SHIPPED_LIVE Moderate: pcs security, bug fix, and enhancement update 2016-11-03 08:11:34 EDT

  None (edit)
Description Radek Steiger 2015-11-30 08:05:27 EST
> Description of problem:

When using pcs 0.9.143 to manage an older cluster with pcs older than 0.9.143, deleting groups and/or clones in the tree view returns an Internal Server Error.

The problem is in the list of resources to be removed which includes both the group/clone name AND all the primitives inside. The old backend then tries to delete the group/clone first and then the primitives second, which are already gone however with the group/clone removal:

I, [2015-11-30T13:32:18.872390 #10163]  INFO -- : Running: /usr/sbin/pcs --force resource delete group21
I, [2015-11-30T13:32:19.868892 #10163]  INFO -- : Running: /usr/sbin/pcs --force resource delete dummy21
I, [2015-11-30T13:32:20.136211 #10163]  INFO -- : Remove resource errors:
Unable to remove: dummy21
::ffff:10.15.105.137 - - [30/Nov/2015 13:32:20] "POST /remote/remove_resource HTTP/1.1" 500 26 1.3123
::ffff:10.15.105.137 - - [30/Nov/2015 13:32:20] "POST /remote/remove_resource HTTP/1.1" 500 26 1.3125
::ffff:10.15.105.137 - - [30/Nov/2015:13:32:18 CET] "POST /remote/remove_resource HTTP/1.1" 500 26
- -> /remote/remove_resource

This should be fixed on the GUI side because only the parent should be sent in the list if the whole group/clone is meant to be removed. Also, please don't forget about the Select All tickbox is causing the same issue.


> Version-Release number of selected component (if applicable):

pcs-0.9.143-15.el7       (RHEL7.2)
+
pcs-0.9.137-13.el7_1.5   (RHEL7.1)


> How reproducible:

Always


> Steps to Reproduce:
1. Add a RHEL7.1 based cluster into RHEL7.2 GUI
2. Add a resource group/clone
3. Remove the whole group/clone by selecting the group/clone tickbox
Comment 1 Ondrej Mular 2016-02-01 10:06:08 EST
proposed fix:
https://github.com/feist/pcs/commit/c86f86f022dbd1d82a708259bb5e3c78b724e1b8

Test:
1. manage RHEL 7.1 cluster in GUI
2. create clone/group resource
3. remove whole clone/group by selecting the clone/group checkbox
4. resources are removed successfully with no error
Comment 2 Mike McCune 2016-03-28 19:15:27 EDT
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune@redhat.com with any questions
Comment 3 Ivan Devat 2016-05-31 08:18:21 EDT
Before fix:
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.143-15.el7.x86_64

1. Add a RHEL7.1 based cluster into RHEL7.2 GUI
2. Add a resource group/clone
3. Remove the whole group/clone by selecting the group/clone tickbox
4. On RHEL7.1 machine:
[rhel71-1 ~] cat /var/log/pcsd/pcsd.log|grep 500
::ffff:192.168.122.11 - - [27/May/2016 10:10:21] "POST /remote/remove_resource HTTP/1.1" 500 40 0.5792
::ffff:192.168.122.11 - - [27/May/2016 10:10:21] "POST /remote/remove_resource HTTP/1.1" 500 40 0.5796
vm-rhel72-1 - - [27/May/2016:10:10:20 CEST] "POST /remote/remove_resource HTTP/1.1" 500 40

After Fix:
[vm-rhel72-1 ~] $ rpm -q pcs
pcs-0.9.151-1.el7.x86_64

1. Add a RHEL7.1 based cluster into RHEL7.2 GUI
2. Add a resource group/clone
3. Remove the whole group/clone by selecting the group/clone tickbox
4. On RHEL7.1 machine:
[rhel71-1 ~] cat /var/log/pcsd/pcsd.log|grep 500
Comment 7 errata-xmlrpc 2016-11-03 16:55:54 EDT
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://rhn.redhat.com/errata/RHSA-2016-2596.html

Note You need to log in before you can comment on or make changes to this bug.