This service will be undergoing maintenance at 00:00 UTC, 2017-10-23 It is expected to last about 30 minutes
Bug 1310959 - oc tag does not point to correct image of image stream
oc tag does not point to correct image of image stream
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Image Registry (Show other bugs)
3.1.0
All Linux
high Severity high
: ---
: ---
Assigned To: Maciej Szulik
Wei Sun
:
Depends On:
Blocks: 1267746
  Show dependency treegraph
 
Reported: 2016-02-22 21:37 EST by Qi Yong
Modified: 2016-06-13 08:39 EDT (History)
11 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-05-12 12:30:04 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Qi Yong 2016-02-22 21:37:15 EST
Description of problem:
oc tag does not point to correct image of image stream

Version-Release number of selected component (if applicable):
[root@master1 ~]# oc version
oc v3.1.1.6
kubernetes v1.1.0-origin-1107-g4c8e6f4

How reproducible:


Steps to Reproduce:
[root@master1 ~]# oc describe is
Name:                   test
Created:                3 days ago
Labels:                 <none>
Annotations:            openshift.io/image.dockerRepositoryCheck=2016-02-19T08:50:28Z
Docker Pull Spec:       172.20.1.1:5000/test/test

Tag     Spec            Created         PullSpec                                                                                                Image
latest  <pushed>        3 days ago      172.20.1.1:5000/test/test@sha256:cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3
                        3 days ago      172.20.1.1:5000/test/test@sha256:e99dd2b55f9b7cd9ff8796714d6adf11aee9a83c14dc353306d1952a7d3d435f

[root@master1 ~]# oc tag test@sha256:cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3 test:1.0.49
Tag test:1.0.49 set to test@sha256:cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3.

[root@master1 ~]# oc get istag
NAME          DOCKER REF                                                                                            UPDATED         IMAGENAME
test:1.0.49   172.20.1.1:5000/test/test@sha256:e99dd2b55f9b7cd9ff8796714d6adf11aee9a83c14dc353306d1952a7d3d435f   6 seconds ago   sha256:e99dd2b55f9b7cd9ff8796714d6adf11aee9a83c14dc353306d1952a7d3d435f
test:latest   172.20.1.1:5000/test/test@sha256:cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3   3 days ago      sha256:cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3


Actual results:
test:latest and test:1.0.49 point to different images.

Expected results:
test:latest and test:1.0.49 both point to cafe742edf63376deab32fb5fea105a53a96b43d8a054e30c82178d498e10fa3


Additional info:
I did not found this issue on following version:
oc v3.1.0.4-16-g112fcc4
kubernetes v1.1.0-origin-1107-g4c8e6f4
Comment 1 Maciej Szulik 2016-02-24 06:00:33 EST
That problem was addressed with complete redo of mechanisms behind image streams for version 3.2. Marking for re-test.
Comment 2 Wei Sun 2016-02-24 20:42:57 EST
Verified this bug using oc v3.1.1.906

Result:
$ oc tag ruby-22-centos7@sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba ruby-22-centos7:test
Tag ruby-22-centos7:test set to ruby-22-centos7@sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba.

$ oc get istag
NAME                     DOCKER REF                                                                                       UPDATED         IMAGENAME
ruby-22-centos7:latest   centos/ruby-22-centos7@sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba   7 minutes ago   sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba
ruby-22-centos7:test     centos/ruby-22-centos7@sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba   9 seconds ago   sha256:98cef73f621fa92e1bd8f701d7c7d0e4830d234e8d1f44e6e180dfd02029c7ba
Comment 4 Wei Sun 2016-03-01 01:51:11 EST
Tested this bug again with multiple images in image stream.

Result:
$ oc describe is perl
Name:			perl
Created:		29 minutes ago
Labels:			<none>
Annotations:		openshift.io/image.dockerRepositoryCheck=2016-03-01T06:06:20Z
Docker Pull Spec:	172.31.91.240:5000/wsunaep/perl

Tag	Spec					Created		PullSpec						Image
latest	5.20					29 minutes ago	centos/perl-520-centos7@sha256:d2ca9c9456c5c7...	<same>
5.20	centos/perl-520-centos7:latest		29 minutes ago	centos/perl-520-centos7@sha256:d2ca9c9456c5c7...	<same>
5.16	openshift/perl-516-centos7:latest	29 minutes ago	openshift/perl-516-centos7@sha256:083630e582d7c2...	<same>


$ oc tag perl@sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011  perl:tagtest
Tag perl:tagtest set to perl@sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011.


$ oc get istag|grep perl
perl:tagtest        openshift/perl-516-centos7@sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011        19 seconds ago   sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011
perl:5.16           openshift/perl-516-centos7@sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011        31 minutes ago   sha256:083630e582d7c24ae1de4d2fa9e0463d5ef5c94960bc88a27d365a081aac1011
perl:5.20           centos/perl-520-centos7@sha256:d2ca9c9456c5c745e74adfc8fe388a3b4b7dd27053ec32ba20a3132e058b05d5           31 minutes ago   sha256:d2ca9c9456c5c745e74adfc8fe388a3b4b7dd27053ec32ba20a3132e058b05d5
perl:latest         centos/perl-520-centos7@sha256:d2ca9c9456c5c745e74adfc8fe388a3b4b7dd27053ec32ba20a3132e058b05d5           31 minutes ago   sha256:d2ca9c9456c5c745e74adfc8fe388a3b4b7dd27053ec32ba20a3132e058b05d5
Comment 11 errata-xmlrpc 2016-05-12 12:30:04 EDT
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.

https://access.redhat.com/errata/RHSA-2016:1064

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