Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1317097 - Runtime Error when using registry.access.redhat.com/rhel6 image for oc new-app
Runtime Error when using registry.access.redhat.com/rhel6 image for oc new-app
Status: CLOSED ERRATA
Product: OpenShift Container Platform
Classification: Red Hat
Component: Image (Show other bugs)
3.1.0
Unspecified Unspecified
medium Severity medium
: ---
: ---
Assigned To: Ben Parees
Wang Haoran
:
Depends On:
Blocks: 1267746
  Show dependency treegraph
 
Reported: 2016-03-11 18:39 EST by Eric Jones
Modified: 2016-05-12 12:32 EDT (History)
9 users (show)

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


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2016:1064 normal SHIPPED_LIVE Important: Red Hat OpenShift Enterprise 3.2 security, bug fix, and enhancement update 2016-05-12 16:19:17 EDT

  None (edit)
Description Eric Jones 2016-03-11 18:39:55 EST
Description of problem:
After pulling, tagging, and pushing the registry.access.redhat.com/rhel6 image to my integrated docker registry I try to run either `oc new-app --image=mytest/rhel6` or `oc new-app --image-stream=rhel6` and I get the following error messages [0].


[0] http://paste-platops.itos.redhat.com/pksei8bxt/rrpnog

Version-Release number of selected component (if applicable):
openshift version
openshift v3.1.1.6
kubernetes v1.1.0-origin-1107-g4c8e6f4
etcd 2.1.2


How reproducible:
Everytime

Steps to Reproduce:
1. docker pull registry.access.redhat.com/rhel6
2. docker tag registry.access.redhat.com/rhel6 myregistry.apps.example.com/mytest/rhel6
3. docker push myregistry.apps.example.com/mytest/rhel6
4. `oc new-app --image=mytest/rhel6` or `oc new-app --image-stream=rhel6`

Actual results:
The error message shown in [0].

Expected results:
Deploy the pod and create all necessary resources
Comment 2 XiuJuan Wang 2016-03-14 03:49:07 EDT
@Eric
I don't meet your error in OSE3.2.0.1 environments with registry.access.redhat.com/rhel6(imageid is 31b925c88737).

But can't create container with below error.

Events:
  FirstSeen	LastSeen	Count	From					SubobjectPath		Type		Reason		Message
  ---------	--------	-----	----					-------------		--------	------		-------
  <invalid>	<invalid>	1	{default-scheduler }						Normal		Scheduled	Successfully assigned rhel6-1-jb2vp to ip-172-18-0-241.ec2.internal
  <invalid>	<invalid>	4	{kubelet ip-172-18-0-241.ec2.internal}	spec.containers{rhel6}	Normal		Pulling		pulling image "registry.access.redhat.com/rhel6:latest"
  <invalid>	<invalid>	4	{kubelet ip-172-18-0-241.ec2.internal}	spec.containers{rhel6}	Normal		Pulled		Successfully pulled image "registry.access.redhat.com/rhel6:latest"
  <invalid>	<invalid>	4	{kubelet ip-172-18-0-241.ec2.internal}	spec.containers{rhel6}	Warning		Failed		Failed to create docker container with error: API error (500): No command specified

  <invalid>	<invalid>	4	{kubelet ip-172-18-0-241.ec2.internal}		Warning	FailedSync	Error syncing pod, skipping: failed to "StartContainer" for "rhel6" with RunContainerError: "runContainer: API error (500): No command specified\n"
Comment 3 Eric Jones 2016-03-14 11:12:14 EDT
@XiuJuan

Can you test it on 3.1.1.6?

The customer _and_ I experienced this issue there.

Is there a way to determine what changed between the 2 so we can get this fixed? Or backported maybe?
Comment 4 Brenton Leanhardt 2016-03-14 14:00:56 EDT
My assumption is that the error in comment #2 is expected.  You can't simply run the rhel6 image.  It's not an s2i image and you aren't passing any source in.  It's not an image that has an entrypoint that is going to do anything.  I suspect that's why "No command specified" is probably accurate.  I suspect in 3.1.1.6 we simply didn't do a good job of exposing that error message.

I think the real question to ask is what is the end goal?  I would think you would want to create a build that would add a layer on top of the rhel6 image and actually run a service.
Comment 5 Eric Jones 2016-03-14 14:17:30 EDT
The ultimate goal was to use the rhel6 image as the base for a dockerfile, but they got the same error message that I got when I simply tried to deploy the image.

I understand that the image will ultimately fail when you try to deploy _just_ the image, but it shouldn't fail with the error that I got in comment #1 which is the same error that the customer got when they tried to use it properly.
Comment 6 Shanna Chan 2016-03-14 14:22:31 EDT
This is what the customer using.
a very basic Dockerfile with the following:
 
FROM rhel6:latest
 
EXPOSE 80
 
COPY base.repo /etc/yum.repos.d/
 
RUN yum clean all -y && \
    yum install -y httpd && \
    yum clean all -y
 
CMD /usr/sbin/httpd -DFOREGROUND

and they are getting the same error.

Thanks & regards,
Shanna
Comment 7 XiuJuan Wang 2016-03-14 23:25:04 EDT
@Eric
Rreproduce this bug with ose 3.1.1.6 environment and oc v3.1.1.6-21-gcd70c35 client.
But works with ose 3.1.1.6 environment and latest oc version.
Just my opinion,looks like oc client issue.
Comment 8 Andy Goldstein 2016-03-18 15:22:11 EDT
This was fixed in origin by https://github.com/openshift/origin/pull/6670
Comment 9 Andy Goldstein 2016-03-18 15:30:00 EDT
Available in latest 3.2 puddle
Comment 10 XiuJuan Wang 2016-03-21 03:30:49 EDT
This bug has been fixed with
$oc version
oc v3.2.0.4
kubernetes v1.2.0-origin-41-g91d3e75

No error when create rhel6 image using new-app cmd.
$ oc get  is 
NAME      DOCKER REPO                         TAGS      UPDATED
rhel6     172.31.168.158:5000/xiuwang/rhel6   latest    Less than a second ago
[wxj@dhcp-129-163 ~]$ oc new-app rhel6 --name=myrhel6 
--> Found image 31b925c (2 weeks old) in image stream rhel6 under tag "latest" for "rhel6"

    * This image will be deployed in deployment config "myrhel6"
    * The image does not expose any ports - if you want to load balance or send traffic to this component
      you will need to create a service with 'expose dc/myrhel6 --port=[port]' later

--> Creating resources with label app=myrhel6 ...
    deploymentconfig "myrhel6" created
--> Success
    Run 'oc status' to view your app.

new-app should create the app pointing to the destination tag instead of "latest".
$ oc get is mysql  -n openshift 
	NAME      DOCKER REPO                           TAGS             UPDATED
mysql     172.31.168.158:5000/openshift/mysql   5.5,5.6,latest   37 hours ago
[wxj@dhcp-129-163 ~]$ oc new-app mysql 
--> Found image 09a304f (2 weeks old) in image stream "mysql" in project "openshift" under tag "5.6" for "mysql"
Comment 12 errata-xmlrpc 2016-05-12 12:32:36 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.