Bug 1766287 - "hello-openshift" template application wrong binary format
Summary: "hello-openshift" template application wrong binary format
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: OpenShift Container Platform
Classification: Red Hat
Component: Management Console
Version: 4.2.z
Hardware: s390x
OS: Linux
medium
high
Target Milestone: ---
: 4.8.0
Assignee: Samuel Padgett
QA Contact: Douglas Slavens
URL:
Whiteboard: multi-arch
Depends On:
Blocks: OCP/Z_4.2 ocp-42-45-z-tracker 2004946
TreeView+ depends on / blocked
 
Reported: 2019-10-28 18:02 UTC by Cheryl A Fillekes
Modified: 2021-09-16 13:45 UTC (History)
27 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Cause: "hello-openshift" template application wrong binary format Consequence: Unable to build and run some sample workloads Fix: Yes. Integrate sample workloads (except pod) to use the ImageStream Result: The sample workloads build and runs successfully.
Clone Of:
Environment:
Last Closed: 2021-04-14 13:00:15 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
exec format error in sample code (93.86 KB, image/png)
2019-10-28 18:02 UTC, Cheryl A Fillekes
no flags Details
Screen shot of which button to push to bring up 'hello-openshift' sample by default (134.15 KB, image/png)
2021-02-09 12:11 UTC, Cheryl A Fillekes
no flags Details
Screen shot of default pod example yaml created from web console (265.04 KB, image/png)
2021-02-09 12:12 UTC, Cheryl A Fillekes
no flags Details
Screen shot of default pod going to 'Crash-Loop-Backoff' state (166.20 KB, image/png)
2021-02-09 12:29 UTC, Cheryl A Fillekes
no flags Details
Screen shot of default pod log showing standard_init_linux.go:219: exec user process caused: exec format error (164.28 KB, image/png)
2021-02-09 12:31 UTC, Cheryl A Fillekes
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github openshift cluster-samples-operator pull 350 0 None closed Bug 1766287: Improve usability of hello-openshift imagestream 2021-02-18 02:37:03 UTC
Github openshift console pull 7186 0 None closed Bug 1766287: - "hello-openshift" template application wrong binary format 2021-02-18 02:37:03 UTC
Github openshift console pull 7646 0 None closed Bug 1766287: Fix use of hello-openshift imagestream 2021-02-18 02:37:03 UTC
Github openshift console pull 8459 0 None open Bug 1766287: Use httpd in workload YAML templates 2021-03-24 18:51:09 UTC
Github openshift origin pull 25435 0 None closed Bug 1766287: Add CI Dockerfile for hello-openshift 2021-02-18 02:37:03 UTC

Description Cheryl A Fillekes 2019-10-28 18:02:02 UTC
Created attachment 1629882 [details]
exec format error in sample code

Description of problem:

Making an 'example' pod which uses the 'hello-openshift' image fails with 'exec format error'

How reproducible: easily


Steps to Reproduce:
1. from the Web Console, create a new workload in the default project with the example 'hello-openshift' application
2. build and run it
3.

Actual results:

runtime fails with 'exec format error'


Expected results:

the example pods run flawlessly


Additional info:

Comment 5 Alexander Klein 2020-03-06 08:14:18 UTC
since this is the first thing i would try as a new customer i think we should get the hello-openshift container built for z to not leave a bad first impression, shouldn't be too much effort.

Comment 6 Jeremy Poulin 2020-06-04 16:55:49 UTC
Is this fixed or blocked by the cluster-samples-operator enablement?

Comment 7 David Benoit 2020-06-04 17:04:58 UTC
Yes, I tested this manually (using a CVO override) with Yaakov's patches several months ago and I was able to run this sample.  I believe this is now only blocked by the general incompatibilities of s390x/ppc64le cluster-samples-operator with CI.

Comment 8 Douglas Slavens 2020-06-16 22:58:40 UTC
Assigning this to Jeremy since Renin is working on a fix.

Comment 9 W. Trevor King 2020-06-24 20:13:42 UTC
Bug was reported against 4.2.z, so we should leave that as it stands to show where the breakage starts.  Target Release tracks where we want the fix to land, so I'm setting that to 4.6.0.  Once the fix lands in master, this bug will get cloned back with Target Release pointing at previous z streams (depending on how far it seems appropriate to backport).  The '/cherrypick ...' GitHub/Prow bot will automatically create those backport bugs as needed.

Comment 10 Douglas Slavens 2020-07-07 17:24:03 UTC
Closing this bug as a duplicate of https://bugzilla.redhat.com/show_bug.cgi?id=1835112.

*** This bug has been marked as a duplicate of bug 1835112 ***

Comment 11 Douglas Slavens 2020-07-07 19:32:54 UTC
reopening for tracking purposes. still assigned to Jeremy.

Comment 12 Jeremy Poulin 2020-07-13 19:37:36 UTC
Moving to ON_QA since this should be available for 4.6 samples, and is just a test effort.

Comment 13 Cheryl A Fillekes 2020-07-13 20:38:06 UTC
In OCP 4.5.0-0.nightly-s390x-2020-07-03-213659  on Z

from Administrator->Workloads->Pods->Create Pod

are offered the option of creating a "hello-openshift" sample workload with the yaml:

piVersion: v1
kind: Pod
metadata:
  name: example
  labels:
    app: hello-openshift
  namespace: check-samples
spec:
  containers:
    - name: hello-openshift
      image: openshift/hello-openshift
      ports:
        - containerPort: 8080


But hitting the "Create" button at the bottom results in a pod that goes into a CrashLoopBackoff state with:


standard_init_linux.go:210: exec user process caused "exec format error"

Comment 14 Yaakov Selkowitz 2020-07-13 21:05:11 UTC
I'm not quite sure why this would be related to cluster-samples.  As noted in comment 3, the image docker.io/openshift/hello-openshift is still only built for amd64, and was not manifest-listed, so this would be the expected result.  The only fix for this is for that image to be rebuilt multi-arch, either on docker.io or at some other location (in which case the image: value would have to be modified accordingly).

Comment 15 David Benoit 2020-07-13 21:25:26 UTC
Yeah, this is not related to cluster samples.  My apologies for any confusion my comment caused.  I had misunderstood and thought we were discussing one of these templates:

https://bugzilla.redhat.com/show_bug.cgi?id=1766364

Comment 18 Steve Kuznetsov 2020-08-20 19:07:59 UTC
DPTP does not publish this image.

Comment 19 Samuel Padgett 2020-08-20 20:46:55 UTC
Moving this to console. We can use a different image in the YAML samples.

Comment 22 Samuel Padgett 2020-09-10 18:50:27 UTC
We're working on adding this image to the release in 4.7 so it supports other architectures.

Comment 25 Yaakov Selkowitz 2020-10-13 17:09:40 UTC
The image is built but to make the console's aforementioned template actually work, further changes are required.

Comment 26 Samuel Padgett 2020-11-04 15:08:54 UTC
(In reply to Yaakov Selkowitz from comment #25)
> The image is built but to make the console's aforementioned template
> actually work, further changes are required.

Hi, Yaakov. Do you know what work remains and what the console team needs to do?

Comment 27 Yaakov Selkowitz 2020-11-04 19:07:53 UTC
All uses of openshift/hello-openshift, starting with those that are user facing (and then to those in __tests__) needs to be changed to point to the new image or imagestream.

Comment 30 Yadan Pei 2020-11-27 02:46:14 UTC
fix is not included in 4.7.0-0.nightly-2020-11-26-201843 yet

Comment 31 Yanping Zhang 2020-12-01 09:22:41 UTC
Tested against pr: https://github.com/openshift/console/pull/7186.
Create pod/deployment/deploymentconfig/daemonset with default example yaml from console, no pod could be running normally, all failed with error "ImagePullBackOff", and pods are using image "registry.redhat.io/openshift4/ose-hello-openshift-rhel8" by default.

Comment 32 Yaakov Selkowitz 2020-12-01 14:07:58 UTC
That is the pullspec expected to be used, but it won't work until 4.7 GA.  Either this should be VERIFIED on this basis then, or otherwise the imagestream needs to be used to get the image from the release payload.

Comment 33 Dan Li 2020-12-02 15:18:32 UTC
Adding "UpcomingSprint" as team is waiting for 4.7 GA to re-test

Comment 34 Samuel Padgett 2020-12-08 18:18:16 UTC
The sample workloads (except pod) use the ImageStream, so we should investgiate why it's not working.

Comment 35 Yaakov Selkowitz 2020-12-22 21:30:55 UTC
Another console PR will be needed after Samples' merges.

Comment 37 Yanping Zhang 2021-01-07 04:07:46 UTC
Checked on ocp 4.7 cluster with payload 4.7.0-0.nightly-2021-01-06-160219 containing fix prs.
Our cluster nodes are x86_64 arch, creating pod/deployment/deploymentconfig/daemonset with default example yaml from console succeeds.
@Cheryl, since you reported the bug against arch:s390x, could you have a try on your cluster with s390x arch to confirm the fixs work on your cluster?

Comment 38 Cyril 2021-01-25 13:58:09 UTC
@cfillekes Could you please verify this fix? Thanks

Comment 39 Jeremy Poulin 2021-02-08 21:08:54 UTC
Hey Doug - can you take a stab at testing this on P & Z.

Just spin up a 4.7 cluster on each and try to create a pod using the template provided in https://bugzilla.redhat.com/show_bug.cgi?id=1766287#c13.

Comment 40 Cheryl A Fillekes 2021-02-09 12:08:45 UTC
Still throws an exec format error on Z15 running OCP 4.7.0-fc4

Comment 41 Cheryl A Fillekes 2021-02-09 12:11:01 UTC
Created attachment 1755904 [details]
Screen shot of which button to push to bring up 'hello-openshift' sample by default

Comment 42 Cheryl A Fillekes 2021-02-09 12:12:17 UTC
Created attachment 1755905 [details]
Screen shot of default pod example yaml created from web console

Comment 43 Cheryl A Fillekes 2021-02-09 12:29:11 UTC
Created attachment 1755926 [details]
Screen shot of default pod going to 'Crash-Loop-Backoff' state

Comment 44 Cheryl A Fillekes 2021-02-09 12:31:30 UTC
Created attachment 1755927 [details]
Screen shot of default pod log showing   standard_init_linux.go:219: exec user process caused: exec format error

Comment 45 Douglas Slavens 2021-02-11 17:44:35 UTC
This is still not working on s390x - setting it back to assigned.

Comment 47 Jakub Hadvig 2021-02-12 12:52:44 UTC
Joe let me know if you need help on this one.

Comment 48 Samuel Padgett 2021-02-12 13:04:19 UTC
It looks like the console change fixes all of the workloads except for Pod, presumably since we couldn't use an image stream trigger there.

https://github.com/openshift/console/blob/master/frontend/public/models/yaml-templates.ts#L435

Comment 54 Dan Li 2021-03-17 14:20:00 UTC
Adding "Reviewed-in-Sprint" as solution has been discussed in previous comments, but the bug likely will not be fixed before the end of this sprint.

Comment 56 Yadan Pei 2021-04-08 01:47:08 UTC
Hi, could you help verify if the fix is working?

Comment 57 Douglas Slavens 2021-04-08 04:12:24 UTC
Hi Yadan, yes I am working with Cheryl to get this tested.

Comment 58 Tom Dale 2021-04-14 13:00:15 UTC
I've verified the fix on s390x. Now default new pod uses template image "image-registry.openshift-image-registry.svc:5000/openshift/httpd:latest" instead of hello-openshift image. I assume this is "the fix" you are referring to. Pod starts fine and image is s390x compatible.

Comment 59 Tom Dale 2021-04-14 13:00:40 UTC
I've verified the fix on s390x. Now default new pod uses template image "image-registry.openshift-image-registry.svc:5000/openshift/httpd:latest" instead of hello-openshift image. I assume this is "the fix" you are referring to. Pod starts fine and image is s390x compatible.

Comment 60 Tom Dale 2021-04-14 13:01:15 UTC
I've verified the fix on s390x. Now default new pod uses template image "image-registry.openshift-image-registry.svc:5000/openshift/httpd:latest" instead of hello-openshift image. I assume this is "the fix" you are referring to. Pod starts fine and image is s390x compatible.


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