Bug 1805155 - Failed to force the deployment to use local name lookup
Summary: Failed to force the deployment to use local name lookup
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: openshift-controller-manager
Version: 4.4
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
: 4.5.0
Assignee: Tomáš Nožička
QA Contact: zhou ying
Depends On:
Blocks: 1801095
TreeView+ depends on / blocked
Reported: 2020-02-20 11:40 UTC by Tomáš Nožička
Modified: 2020-07-13 17:16 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: image-resolve-plugin wasn't resolving images if the alpha.image.policy.openshift.io/resolve-names annotation was added later on. Consequence: Images weren't resolved. Fix: image-resolve-plugin now resolves images even if the alpha.image.policy.openshift.io/resolve-names annotation is added after resource creation. Result: it works
Clone Of:
Last Closed: 2020-07-13 17:16:20 UTC
Target Upstream Version:

Attachments (Terms of Use)

System ID Priority Status Summary Last Updated
Github openshift origin pull 24530 None closed Bug 1805155: Fix image resolve plugin on updates and add tests 2020-06-30 18:34:24 UTC
Red Hat Product Errata RHBA-2020:2409 None None None 2020-07-13 17:16:49 UTC

Description Tomáš Nožička 2020-02-20 11:40:56 UTC
This bug was initially created as a copy of Bug #1801095

I am copying this bug because: 

Description of problem:
Failed to force the deployment to use local name lookup

Version-Release number of selected component (if applicable):
[root@dhcp-140-138 ~]# oc version 
Client Version: 4.4.0-0.nightly-2020-02-10-035806
Kubernetes Version: v1.17.1

How reproducible:

Steps to Reproduce:
1. Create ImageStream:
  `oc tag openshift/deployment-example:v1 --source=docker app:v1`
2. Create deploy to use the Imagestream:
  `oc create deployment app --image=app:v1`
3. Set deployment to use local image lookup
  `oc set image-lookup deployment/app`

Actual results:
3.Deploy failed with error:
[root@dhcp-140-138 ~]#  oc describe deployment/app
Name:                   app
Namespace:              zhouy
CreationTimestamp:      Mon, 10 Feb 2020 16:46:13 +0800
Labels:                 app=app
Annotations:            deployment.kubernetes.io/revision: 2879
Selector:               app=app
Replicas:               1 desired | 1 updated | 1 total | 0 available | 1 unavailable
StrategyType:           RollingUpdate
MinReadySeconds:        0
RollingUpdateStrategy:  25% max unavailable, 25% max surge
Pod Template:
  Labels:       app=app
  Annotations:  alpha.image.policy.openshift.io/resolve-names: *
    Image:        app:v1
    Port:         <none>
    Host Port:    <none>
    Environment:  <none>
    Mounts:       <none>
  Volumes:        <none>
  Type           Status  Reason
  ----           ------  ------
  Available      False   MinimumReplicasUnavailable
  Progressing    True    NewReplicaSetCreated
OldReplicaSets:  app-858f464854 (1/1 replicas created), app-b797c6d6d (1/1 replicas created)

`oc get event`
Failed to create pod sandbox: rpc error: code = Unknown desc = failed to create pod network sandbox k8s_app-db87ffc99-cnf8j_zhouy_f02be028-d947-4306-81d3-e9a39ea32faa_0(4da67f3b9df5232326a7df46ddabfc5aba08241e2c0b70d9c76d6ab87ec2cd8e): Multus: error adding pod to network "openshift-sdn": delegateAdd: cannot set "openshift-sdn" interface name to "eth0": validateIfName: no net namespace /proc/725663/ns/net found: failed to Statfs "/proc/725663/ns/net": no such file or directory

Expected results:
3. Pod running

Additional info:

Comment 3 zhou ying 2020-03-09 02:26:37 UTC
Confirmed with payload: 4.5.0-0.nightly-2020-03-06-190457, the issue has fixed:

[yinzhou@localhost ~]$ oc tag openshift/deployment-example:v1 --source=docker app:v1
Tag app:v1 set to openshift/deployment-example:v1.
[yinzhou@localhost ~]$ oc create deployment app --image=app:v1
deployment.apps/app created
[yinzhou@localhost ~]$ oc set image-lookup deployment/app
deployment.apps/app image lookup updated
[yinzhou@localhost ~]$ oc get po 
NAME                   READY   STATUS    RESTARTS   AGE
app-5fd88b6f9d-9qtzk   1/1     Running   0          2m30s

Comment 5 errata-xmlrpc 2020-07-13 17:16:20 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, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.


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