OpenShift Disconnected creating mirror registry and mandatory environment variables

Solution Verified - Updated -

Issue

  • Syncing of registry (for example, while updating to a new release) following redhat official document fails with follow error message
oc adm release mirror -a ${LOCAL_SECRET_JSON} --from=quay.io/${PRODUCT_REPO}/${RELEASE_NAME}:${OCP_RELEASE}-${ARCHITECTURE}   --to=${LOCAL_REGISTRY}/${LOCAL_REPOSITORY} --apply-release-image-signature
info: Mirroring 109 images to mirror-host.redhat.com:5000/ocp4/openshift4 ...
mirror-host.redhat.com:5000/
  ocp4/openshift4
    blobs:
      quay.io/openshift-release-dev/ocp-release sha256:a1d58de198fba13b08680865f20baba74946670ecd70665d3c69eb707877c12a 1.619KiB
      quay.io/openshift-release-dev/ocp-release sha256:bb0da44cdbced801240e74437a617d4fe0e39c29cf3bbabb7f6a96d2620cfeaa 1.689KiB
      quay.io/openshift-release-dev/ocp-release sha256:0da8676ea7fb89bfb90682558c3edf2d058a881db3536a539f32c90ba13f7580 608.1KiB
      quay.io/openshift-release-dev/ocp-release sha256:e8913ff394b521ade2e6bd6e79ab0866dbd8596e36c796a0e68c422581991335 3.341MiB
      quay.io/openshift-release-dev/ocp-release sha256:6c37764d5c158dac2bf384857e5db6a67f70e81efac73c6243e93e85a4fb717d 7.859MiB
      quay.io/openshift-release-dev/ocp-release sha256:766e1c1a4e86e97b8d315359e0240da4d5a0e3c10bd789d88d06f344c4e3288e 18.5MiB
      quay.io/openshift-release-dev/ocp-release sha256:a03401a44180b6581a149376d6fd2d5bd85d938445fd5b5ad270e14ddde4937c 72.71MiB
    blobs:
      quay.io/openshift-release-dev/ocp-v4.0-art-dev sha256:617efbbbdbe4eeb2b966b3717f3a0410bce2f0462f09dff8284f856c38641135 631B
      quay.io/openshift-release-dev/ocp-v4.0-art-dev sha256:264aaa453271eaaf6bc92b521f62e38cbda4f01e1a3fbf50abdb8b466be58a64 1.676KiB
      quay.io/openshift-release-dev/ocp-v4.0-art-dev sha256:bb0da44cdbced801240e74437a617d4fe0e39c29cf3bbabb7f6a96d2620cfeaa 1.689KiB
...
    manifests:
      sha256:01b3bfcb50f573b77ccb83bc2754dda27ab9d8c338d7db6730f7cda0ae94ba3f -> 4.4.11-ironic-machine-os-downloader
      sha256:03fec3ade06855f439040f20b4a59b2753ef0b09fbd348ed9b10afa0bec45ae5 -> 4.4.11-local-storage-static-provisioner
      sha256:0452411f7d3a059dec052b10e3104f6d368271d6f80299f50d5c8fdb852bed74 -> 4.4.11-kube-etcd-signer-server
      sha256:05f8e6d1f6d516eb96e7b0a692562a8bae4648f55fd9adcc954b5e782f1bfc0d -> 4.4.11-cluster-kube-scheduler-operator
      sha256:0653f3775e17b86e020110ae60985b44c7882c883730596c1410933edcce9368 -> 4.4.11-ironic
      sha256:0ce89f309f822dcd40de2dde4d7b0dda71f2011116bb7c2645d3b583a7207595 -> 4.4.11-cluster-update-keys
...
  stats: shared=5 unique=222 size=5.484GiB ratio=0.98

phase 0:
  mirror-host.redhat.com:5000 ocp4/openshift4 blobs=227 mounts=0 manifests=109 shared=5

info: Planning completed in 20.88s
error: unable to upload blob sha256:e8913ff394b521ade2e6bd6e79ab0866dbd8596e36c796a0e68c422581991335 to mirror-host.redhat.com:5000/ocp4/openshift4: unauthorized: authentication required
error: unable to upload blob sha256:6c37764d5c158dac2bf384857e5db6a67f70e81efac73c6243e93e85a4fb717d to mirror-host.redhat.com:5000/ocp4/openshift4: unauthorized: authentication required
error: unable to upload blob sha256:a03401a44180b6581a149376d6fd2d5bd85d938445fd5b5ad270e14ddde4937c to mirror-host.redhat.com:5000/ocp4/openshift4: unauthorized: authentication required
error: unable to upload blob sha256:b01d36a9bb984bd795b99d00f5a7ece1a8e65f42496aa4784fb97c0ce71741e4 to mirror-host.redhat.com:5000/ocp4/openshift4: unauthorized: authentication required

Environment

  • Red Hat OpenShift Container Platform 4.4

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content