Bug 2060278

Summary: ceph orch rm should validate the given service_name
Product: [Red Hat Storage] Red Hat Ceph Storage Reporter: Ameena Suhani S H <amsyedha>
Component: CephadmAssignee: Redouane Kachach Elhichou <rkachach>
Status: CLOSED ERRATA QA Contact: Manasa <mgowri>
Severity: low Docs Contact: Anjana Suparna Sriram <asriram>
Priority: unspecified    
Version: 5.1CC: adking, akraj, kdreyer, rkachach, vereddy
Target Milestone: ---Keywords: Rebase
Target Release: 5.2   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: ceph-16.2.8-2.el8cp Doc Type: Enhancement
Doc Text:
.`ceph orch rm <service-name>` command informs users if the service they attempted to remove exists or not Previously, removing a service would always return a successful message, even for non-existent services causing confusion among users. With this release, running `ceph orch rm _SERVICE_NAME_` command informs users if the service they attempted to remove exists or not in `cephadm`.
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-08-09 17:37:39 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:
Bug Depends On:    
Bug Blocks: 2102272    

Description Ameena Suhani S H 2022-03-03 08:03:43 UTC
Description of problem:
When we use random service_name with ceph orch rm command it shows the service has been removed need validation or appropriate msg to be displayed that the given service_name does not exist.
(note: dummy is a non-existent service_name which is not listed when ceph orch ls o/p is captured)

eg: # ceph orch rm dummy
Removed service dummy


Version-Release number of selected component (if applicable):
ceph version 16.2.7-74.el8cp 

How reproducible:
2/2

Steps to Reproduce:
1. Have a 5.1 cluster
2. use ceph orch rm command with random service name and see the displayed msg which says as below


Actual results:
# ceph orch rm dummy_name
Removed service dummy_name

Expected results:
 # ceph orch rm dummy_name
Service dummy_name does not exist

Comment 1 Redouane Kachach Elhichou 2022-03-09 13:30:50 UTC
PR to fix the issue: https://github.com/ceph/ceph/pull/45314

Comment 13 errata-xmlrpc 2022-08-09 17:37:39 UTC
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 (Moderate: Red Hat Ceph Storage Security, Bug Fix, and Enhancement Update), 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/RHSA-2022:5997