Jenkins | Google Compute Engine Plugin Slave node Error

Hello Team,

I am using Google Compute Engine plugin to configure the Jenkins slave node. I have created the instance template and also wrote the script to install java 11 and have set its path as well in the startup script. But when i am configuring the slave node, the node is able to authenticate successfully but after the SSH connection is established successfully it is throwing error in the next step in which it verifies java executable path 

INFO: Verifying: /usr/lib/jvm/java-11-openjdk-amd64/bin/java -fullversion bash: line 1: /usr/lib/jvm/java-11-openjdk-amd64/bin/java: No such file or directory Jan 30, 2024 5:55:57 PM null WARNING: Java is not installed at /usr/lib/jvm/java-11-openjdk-amd64/bin/java

Jenkins Version: 2.401.3

GCE Plugin Version: 4.558.va_28ff1201886

2 1 106
1 REPLY 1

Hi @aayushsood1994,

Welcome to the Google Cloud Community!

I assume you have already installed Java 11, but Jenkins isn't finding the right path. Kindly try doing the solution posted in these StackOverflow threads:

Let me know if it worked so I can assist you further. Thank you.