Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 961836 - CLI - user delete does not work
Summary: CLI - user delete does not work
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Hammer
Version: Nightly
Hardware: Unspecified
OS: Unspecified
medium
high
Target Milestone: Unspecified
Assignee: Eric Helms
QA Contact: Katello QA List
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-05-10 14:12 UTC by Hayk Hovsepyan
Modified: 2019-09-26 13:40 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-07-18 21:21:11 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Hayk Hovsepyan 2013-05-10 14:12:54 UTC
Description of problem:
When deleting user by CLI, user still exists in outputs of 'user info' and 'user list' commands.

Version-Release number of selected component (if applicable):
katello-configure-1.4.3-1.el6.noarch
katello-glue-candlepin-1.4.2-1.git.222.82e7958.el6.noarch
katello-1.4.2-1.git.222.82e7958.el6.noarch
katello-qpid-client-key-pair-1.0-1.noarch
katello-cli-common-1.4.2-1.git.39.6fb67c1.el6.noarch
katello-qpid-broker-key-pair-1.0-1.noarch
katello-common-1.4.2-1.git.222.82e7958.el6.noarch
katello-selinux-1.4.3-1.git.3.ce8227b.el6.noarch
katello-glue-pulp-1.4.2-1.git.222.82e7958.el6.noarch
katello-all-1.4.2-1.git.222.82e7958.el6.noarch
katello-cli-1.4.2-1.git.39.6fb67c1.el6.noarch
katello-repos-1.4.2-1.el6.noarch
signo-katello-0.0.7-1.el6.noarch
katello-glue-elasticsearch-1.4.2-1.git.222.82e7958.el6.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-certs-tools-1.4.2-1.el6.noarch


How reproducible:
always

Steps to Reproduce:
1. Create user by CLI: 'user create --username "usr1" --password "password" --email "usr1@localhost"'
2.Delete user by CLI: 'user delete --username "usr1"'. It shows that user is deleted.
3. Try to list users in CLI, and you will see that just deleted user is listed there, which is bug.
4. Try to execute CLI 'user info --username "usr1"' and it shows information instead of error, which is bug. And in output it hows: "Disabled : False"
5. Try to delete user once again, and it will show error: "{"http_request_method": "DELETE", "exception": null, "error_message": "Missing resource(s): resource_id=usr-1368193901-1d0d4458", "_href": "/pulp/api/v2/roles/super-users/users/usr-1368193901-1d0d4458/", "http_status": 404, "traceback": null, "resources": {"resource_id": "usr-1368193901-1d0d4458"}}
 (com.redhat.qe.tools.SSHCommandRunner.runCommandAndWait)"
  
Actual results:
user delete shows that it is deleted, but in fact 'user list' and 'user info' shows that user.

Expected results:
user should be deleted, and 'user info' should show Error 65 that user does not exists, and 'user list' should not list deleted users.
Second time of deleting the same user, it must show shorter message that user does not exist.

Additional info:

Comment 2 Eric Helms 2013-05-17 14:05:01 UTC
This issue was broader than just the CLI. All user deletion was broken. The fix is being tracked here - https://github.com/Katello/katello/pull/2325

Comment 3 Eric Helms 2013-05-17 14:06:26 UTC
commit 25e4ce8fe2f8fcbbe7c8e7effe30859a2e687776
Author: Eric D Helms <ehelms>
Date:   Fri May 17 09:25:38 2013 -0400

    BZ 961836: Fixes broken user deletion.
    
    For new orchestration events, if there is no create or destroy event
    the functions would return the default nil and cause orchestration
    to fail. This manifested itself by preventing user deletion in the
    database but leaving the user deleted in Pulp.

Comment 4 Garik Khachikyan 2013-05-17 14:17:27 UTC
i really hope it's a generic fix: as like repo is affected (seen just today).

Comment 7 Sam Kottler 2013-05-23 23:40:16 UTC
Moving to ON_QA for drop 2.

Comment 8 Hayk Hovsepyan 2013-05-24 13:26:06 UTC
Verified on revision:
katello-certs-tools-1.4.2-2.el6sat.noarch
signo-katello-0.0.12-1.el6sat.noarch
katello-glue-pulp-1.4.2-7.el6sat.noarch
katello-configure-foreman-1.4.3-10.el6sat.noarch
katello-foreman-all-1.4.2-7.el6sat.noarch
ruby193-rubygem-katello_api-0.0.3-2.el6_4.noarch
katello-candlepin-cert-key-pair-1.0-1.noarch
katello-qpid-client-key-pair-1.0-1.noarch
katello-cli-1.4.2-6.el6sat.noarch
ruby193-rubygem-foreman-katello-engine-0.0.7-1.el6sat.noarch
katello-configure-1.4.3-10.el6sat.noarch
katello-common-1.4.2-7.el6sat.noarch
katello-selinux-1.4.3-3.el6sat.noarch
katello-glue-candlepin-1.4.2-7.el6sat.noarch
ruby193-rubygem-katello-foreman-engine-0.0.1-1.el6_4.noarch
katello-all-1.4.2-7.el6sat.noarch
katello-agent-1.4.2-4.el6sat.noarch
katello-cli-common-1.4.2-6.el6sat.noarch
katello-glue-elasticsearch-1.4.2-7.el6sat.noarch
katello-1.4.2-7.el6sat.noarch
katello-qpid-broker-key-pair-1.0-1.noarch

Comment 9 Mike McCune 2013-07-18 21:21:11 UTC
mass move to CLOSED:CURRENTRELEASE since MDP1 has been released.


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