Bug 1755076

Summary: Jenkins Image 3.11.146-1 is failing to start
Product: OpenShift Container Platform Reporter: Adler <afleuran>
Component: JenkinsAssignee: Akram Ben Aissi <abenaiss>
Status: CLOSED DUPLICATE QA Contact: XiuJuan Wang <xiuwang>
Severity: urgent Docs Contact:
Priority: unspecified    
Version: 3.11.0CC: vbobade
Target Milestone: ---   
Target Release: 3.11.z   
Hardware: x86_64   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2019-09-24 17:38:55 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 1754968    
Bug Blocks:    

Description Adler 2019-09-24 17:19:25 UTC
Description of problem:


Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. Start Jenkins using image 3.11.146-1

Actual results:
Failing to start with below error message:

```
OpenShift client and server versions are oc v3.11.146
kubernetes v1.11.0+d4cacc0
features: Basic-Auth GSSAPI Kerberos SPNEGO

Server https://10.26.0.1:443 
openshift v3.10.119
kubernetes v1.10.0+b81c8f8
alternatives version 1.7.4 - Copyright (C) 2001 Red Hat, Inc.
This may be freely redistributed under the terms of the GNU Public License.

usage: alternatives --install <link> <name> <path> <priority>
                    [--initscript <service>]
                    [--family <family>]
                    [--slave <link> <name> <path>]*
       alternatives --remove <name> <path>
       alternatives --auto <name>
       alternatives --config <name>
       alternatives --display <name>
       alternatives --set <name> <path>
       alternatives --list

common options: --verbose --test --help --usage --version --keep-missing
                --altdir <directory> --admindir <directory>
OPENSHIFT_JENKINS_JVM_ARCH='', CONTAINER_MEMORY_IN_MB='2048', using /usr/lib/jvm/java-1.8.0-openjdk-1.8.0.222.b10-1.el7_7.x86_64/jre/bin/java and /usr/lib/jvm/java-11-openjdk-11.0.4.11-1.el7_7.x86_64/bin/javac
/usr/local/bin/jenkins-common.sh: line 33: java: command not found
mkdir: cannot create directory ‘/var/lib/jenkins/logs’: File exists
Administrative monitors that contact the update center will remain active
/usr/libexec/s2i/run: line 434: [: uNpAdf:2a7b5f00d05f28f5b8e09f7b547423580bd7cb82c1de5a57eb07cdbcd63480f8: unary operator expected
Migrating slave image configuration to current version tag ...
+ exec java -XX:+UseParallelGC -XX:MinHeapFreeRatio=5 -XX:MaxHeapFreeRatio=10 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -XX:MaxMetaspaceSize=1000m -Xmx1024m -Dfile.encoding=UTF8 -Djavamelody.displayed-counters=log,error -Duser.home=/var/lib/jenkins -Djavamelody.application-name=JENKINS -jar /usr/lib/jenkins/jenkins.war
/usr/libexec/s2i/run: line 485: exec: java: not found
```

Expected results:

Would start successfully.

Additional info:
The latest image is a mix bag containing java 11 and java 8.
It's interesting to see all of these openjdk packages:
OpenJDK Runtime Environment 8
OpenJDK Headless Runtime Environment 8
OpenJDK Runtime Environment 11
OpenJDK Development Environment 11
OpenJDK Headless Runtime Environment 11

Comment 1 Akram Ben Aissi 2019-09-24 17:31:24 UTC
duplicates https://bugzilla.redhat.com/show_bug.cgi?id=1754968

Comment 2 Akram Ben Aissi 2019-09-24 17:38:55 UTC

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