ESM Upgrade to 23.2 Notes Part 1 - Update JDK and Jenkins

Upgrading ESM, for the most part is one of the rare "Banner" things which is relatively painless. You login into ESM, then click update, wait for a few minutes ... and then for the most part; you are done.

That all changes with ESM 23.2

Please note, that if you decide to upgrade to ESM 23.2, you will also need to upgrade to the most recently supported version of Jenkins (which is 2.401.1). This version of Jenkins also requires Java version 11, which you will most likely also need to install.

 

So for today, let's look at updating Jenkins to the highest support version for Banner. You should do this prior to the ESM upgrade.

Thus prior to upgrading ESM 23.2+ you need to perform the following steps.

  • Install Java 11 on the ESM system and ALL Jenkins servers AND its slave nodes. you can download JDK 11 from the following URL:
  • I would recommend that you install using a TGZ file, particularly on the jobsub server since all Banner Jobs still need to run under JDK 1.8 and install using YUM might cause conflicts.
  • Extract the above TGZ somewhere (e.g. /usr/local/jdk-11.0.2)
  • Download the most recently supported versions of Jenkins from the following URL:
  • https://get.jenkins.io/war-stable/2.401.1/jenkins.war
  • On the ESM server (as the user esmadmin), go to /u01/jenkins, rename the original jenkins.war to jenkins.war.old (mv jenkins.war jenkins.war.old)
  • copy the jenkins.war that you download from the URL above into this directory
  • edit the jenkins start file so that the java home now points to newly created JDK all home. Then start the jenkins.war file with the new JDK 11 version of java
  • When you are done, the new start.sh file should look something like this:

#!/bin/bash

# contents of jenkins server start script on ESM server

export JENKINS_HOME=/u01/jenkins
cd $JENKINS_HOME
export JAVA_HOME=/usr/local/jdk-11.0.2
nohup $JAVA_HOME/bin/java -jar jenkins.war --httpPort=8080  > jslave.log 2>&1 &
echo $! > jenkins.pid

At this point, the Jenkins server upgrade is complete. You will now need to upgrade all Jenkins slave agents.

Once the Jenkins server upgrade is complete, go to Manage Jenkins->Nodes and Clouds on the jenkins server an click on a node.

You will see a download link for a new agent.jar using a curl command:

Copy this line into your agent start curl before the agent start line.

You can also add an rm command to remove the old agent file:

When you are done, your agent start command should look something like this:

#!/bin/bash
export JAVA_HOME=/usr/local/jdk-11.0.2 # be sure to install JDK11 on all agent nodes also !!
export PATH=$JAVA_HOME/bin:$PATH
cd /u01/app/bmui_jenkins_prod
rm agent.jar
curl -sO http://my.jenkins.com:8080/jnlpJars/agent.jar
nohup java -jar agent.jar -jnlpUrl http://my.jenkins.com:8080/computer/node1_BMUI_JENKINS_PROD/slave-agent.jnlp -secret xxxxxxxxxxxxxxxxx -workDir "/u01/app/bmui_jenkins" > jslave.log 2>&1 &
echo $! > jenkins.pid

Now continue until all nodes have the updated JDK and agent.jar

Once you are done, proceed to update ESM