Error extracting the `openshift-install` binary with an ImageContentSourcePolicy (ICSP) file from OpenShift mirror in a disconnected environment

Solution Verified - Updated -

Issue

  • Command oc adm release extract --icsp-file='imageContentSourcePolicy.yaml' is failing when the ICSP file contains multiple ImageContentSourcePolicy CRDs

  • Error trying to extract openshift-install binary from an image:

# oc adm release extract --icsp-file='ImageContentSourcePolicy.yaml' -a registry.json --command=openshift-install registry.lab:8443/ocp4/openshift4@sha256:96bf74ce789ccb22391deea98e0c5050c41b67cc17defbb38089d32226dba0b8

error: unable to read image quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:8d9f83d4228e746719250c5d53dad5884c8392db0a6e7cda0dad9761c332deda: Get "https://quay.io/v2/": dial tcp: lookup quay.io on 192.168.122.1:53: server misbehaving

or

# oc adm release extract --icsp-file='ImageContentSourcePolicy.yaml' -a registry.json --command=openshift-install registry.lab:8443/ocp4/openshift4@sha256:96bf74ce789ccb22391deea98e0c5050c41b67cc17defbb38089d32226dba0b8

error: unable to read image quay.io/openshift-release-dev/ocp-v4.0-art-dev@sha256:8d9f83d4228e746719250c5d53dad5884c8392db0a6e7cda0dad9761c332deda: Get "https://quay.io/v2/": dial tcp: lookup quay.io on 192.168.122.1:53: lame referral

Environment

  • Red Hat OpenShift Container Platform
    • 4.12

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