Bug 1937371

Summary: OCS 4.7: Change "ocs-osd-removal job" name on Device Replacement doc, also clarify that multiple Devices can be replaced with one oc process command in 4.7
Product: [Red Hat Storage] Red Hat OpenShift Container Storage Reporter: Oded <oviner>
Component: documentationAssignee: Disha Walvekar <dwalveka>
Status: CLOSED CURRENTRELEASE QA Contact: Oded <oviner>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 4.7CC: asriram, dwalveka, ikave, nberry, ocs-bugs, sdudhgao
Target Milestone: ---Keywords: Automation
Target Release: OCS 4.7.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-03-02 07:11:51 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: 1921782    

Description Oded 2021-03-10 13:58:31 UTC
Describe the issue:
The osd-removal job name is general and not for specific OSD-ID

Describe the task you were trying to accomplish:

Suggestions for improvement:

step 4 OCS4.6 doc:
Remove the old OSD from the cluster so that a new OSD can be added. 
oc delete -n openshift-storage job ocs-osd-removal-${osd_id_to_remove}

Need to change on step 4 OCS4.7 doc:
$ oc delete -n openshift-storage job ocs-osd-removal-job
job.batch "ocs-osd-removal-job" deleted


step 11 OCS4.6 doc:
Delete the ocs-osd-removal job(s).
$ oc delete -n openshift-storage job ocs-osd-removal-${osd_id_to_remove}

Need to change on step 11 OCS4.7 doc:
$ oc delete -n openshift-storage job ocs-osd-removal-job
job.batch "ocs-osd-removal-job" deleted




Full configuration:
$ oc get job -n openshift-storage
NAME                                                           COMPLETIONS   DURATION   AGE
ocs-osd-removal-job                                            1/1           9s         19h

$ oc delete -n openshift-storage job ocs-osd-removal-job
job.batch "ocs-osd-removal-job" deleted





Document URL:
https://access.redhat.com/documentation/en-us/red_hat_openshift_container_storage/4.6/html-single/replacing_devices/index?lb_target=preview#replacing-operational-or-failed-storage-devices-on-clusters-backed-by-local-storage-devices_rhocs

Chapter/Section Number and Title:
4.3

Product Version:
OCS4.7

Environment Details:

Any other versions of this document that also needs this update:

Additional information:

Comment 3 Servesha 2021-03-11 05:38:08 UTC
@Neha Sure! will do.

Comment 4 Servesha 2021-03-11 09:04:26 UTC
Some changes we need apart from mentioned in the description:

1] Step 5: Verify that the OSD is removed successfully by checking the status of the ocs-osd-removal pod.

# oc get pod -l job-name=ocs-osd-removal-${osd_id_to_remove} -n openshift-storage

Change: job-name=ocs-osd-removal-${osd_id_to_remove} should be job-name=ocs-osd-removal-job

2] We need to make the same change to the job name under the `Note` as well.

oc logs -l job-name=ocs-osd-removal-${osd_id_to_remove} -n openshift-storage --tail=-1

Change: oc logs -l job-name=ocs-osd-removal-job -n openshift-storage --tail=-1

Comment 11 Oded 2021-03-31 10:27:26 UTC
QA_Failed

step 4 on section 2.1("Replacing operational or failed storage devices on VMware user-provisioned infrastructure")
does not changed:

"oc delete -n openshift-storage job ocs-osd-removal-${osd_id_to_remove}" need to change to

$ oc delete -n openshift-storage job ocs-osd-removal-job
job.batch "ocs-osd-removal-job" deleted


https://access.redhat.com/documentation/en-us/red_hat_openshift_container_storage/4.7/html-single/replacing_devices/index?lb_target=preview#replacing-operational-or-failed-storage-devices-on-vmware-user-provisioned-infrastructure_rhocs

Comment 12 Disha Walvekar 2021-03-31 13:40:58 UTC
Hi Oded, 

I see that this section was not mentioned earlier hence I did not make any changes to the commands in this section.

I have made the changes now. If you can verify the changes.

LINK - https://access.redhat.com/documentation/en-us/red_hat_openshift_container_storage/4.7/html-single/replacing_devices/index?lb_target=preview#replacing-operational-or-failed-storage-devices-on-vmware-user-provisioned-infrastructure_rhocs

Thank you!

Comment 14 Oded 2021-03-31 15:59:40 UTC
Hi Disha Walvekar,

I checked all the doc and there are some mistakes on Section 2.1.


  
Section: 2.1. Replacing operational or failed storage devices on VMware user-provisioned infrastructure


step 5:
old: 
oc get pod -l job-name=ocs-osd-removal-${osd_id_to_remove} -n openshift-storage

new:
$ oc get pod -l job-name=ocs-osd-removal-job -n openshift-storage
NAME                        READY   STATUS      RESTARTS   AGE
ocs-osd-removal-job-5kdkt   0/1     Completed   0          62s

step 7:
old:
oc delete -n openshift-storage job ocs-osd-removal-${osd_id_to_remove}

new:
$ oc delete -n openshift-storage job ocs-osd-removal-job
job.batch "ocs-osd-removal-job" deleted

Comment 18 Oded 2021-04-13 12:15:51 UTC
On step 2.1.7, Delete the ocs-osd-removal job.
"oc delete -n openshift-storage job ocs-osd-removal-${osd_id_to_remove}" change to "oc delete -n openshift-storage job ocs-osd-removal-job"

https://access.redhat.com/documentation/en-us/red_hat_openshift_container_storage/4.7/html-single/replacing_devices/index?lb_target=preview#replacing-operational-or-failed-storage-devices-on-vmware-user-provisioned-infrastructure_rhocs

Comment 20 Oded 2021-04-18 09:21:24 UTC
Hi Disha, 


On Step 2.1.5 need to change  " oc get pod -l job-name=ocs-osd-removal-${osd_id_to_remove} -n openshift-storage" to 
                               "oc get pod -l job-name=ocs-osd-removal-job -n openshift-storage"


Why does it change every time?

Thanks,
Oded

Comment 22 Red Hat Bugzilla 2023-09-18 00:25:07 UTC
The needinfo request[s] on this closed bug have been removed as they have been unresolved for 120 days