Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1512005 - 10.2. Converting the Openshift Container Platform Registry with Container-Native Storage - step 18, sub-step iv - documentation issue
Summary: 10.2. Converting the Openshift Container Platform Registry with Container-Nat...
Keywords:
Status: NEW
Alias: None
Product: Red Hat Gluster Storage
Classification: Red Hat
Component: doc-Container_Native_Storage_with_OpenShift
Version: cns-3.6
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: ---
Assignee: storage-doc
QA Contact: storage-qa-internal@redhat.com
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2017-11-10 15:54 UTC by Ian Tewksbury
Modified: 2019-01-18 07:56 UTC (History)
8 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed:


Attachments (Terms of Use)

Description Ian Tewksbury 2017-11-10 15:54:28 UTC
Document URL: https://access.redhat.com/documentation/en-us/red_hat_gluster_storage/3.3/html-single/container-native_storage_for_openshift_container_platform/#idm139750773805488

Section Number and Name: 10.2. Converting the Openshift Container Platform Registry with Container-Native Storage - step 18, sub-step iv

Describe the issue: 

The documentation as written does not work.

```
Run rsync of data from old registry to the Red Hat Gluster Storage registry by executing the following command:
# oc rsync $REGISTRY_POD:/registry/ $REGISTRY_POD:/gluster-registry/
```

If you try to run this command you get an error from the `oc` tools that rsync command can only be used for local to remote sync and not for local to local.

Suggestions for improvement: 

Need to update the step to do an rsh into the pod and do rsync local to pod.

For example:

```
export REGISTRY_POD=$(oc get po --selector="docker-registry=default" -n default -o go-template --template='{{printf "%s" ((index .items 1).metadata.name)}}')
oc rsh ${REGISTRY_POD} rsync -r -v /registry/ /gluster-registry/
```

Additional information: 

I wrote a sample script that does the entire migration here: https://github.com/itewk/ocp-utilities/blob/master/scripts/storage/swap-registry-storage-for-gluster

Comment 2 Jose A. Rivera 2018-08-06 12:52:41 UTC
Best I can tell, the command you ran is not what was documented. Your command remotes into the pod and executes rsync within the container. Try running the "oc rsync" command as documented.

Comment 3 Jose A. Rivera 2018-08-06 12:58:43 UTC
OH, ugh, too early in the morning here. I see what you did. Unfortunate to see that the READONLY mode doesn't work, so we'll need to document that the admin should make sure to stop all traffic some other way. In any case, looks good enough to me.

Comment 5 Jose A. Rivera 2018-08-28 11:48:26 UTC
We will probably have to settle for a solution that completely brings the registry down for a short period of time. Scaling the registry down to zero should suffice.


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