5
I have a Jenkins server that orchestrates my build. Overall, it performs lighter builds, but I need the slave to build GWT projects by SSD. I have some freedom with that slave, but he is a resource borrowed from another company.
By the way, in this machine that the other company has kindly given, there is a Jenkins server on which the product of this other company is built. And I wouldn’t want to bother with any change of JDK without having control that the change will be completely Sandboxed not to affect the product of others.
JDK builds options available:
I set up Jenkins to build with Jdk8u91 as per the image:
Getting the following error message:
Installing PATH/TO/SLAVE/tools/Hudson.model.JDK/Jdk_8u91/jdk.exe
[Jdk_8u91] $ PATH/TO/SLAVE/tools/Hudson.model.JDK/Jdk_8u91/jdk.exe /s ADDLOCAL="Toolsfeature" REBOOT=Reallysuppress INSTALLDIR=PATH TO SLAVE tools Hudson.model.JDK Jdk_8u91 /L PATH TO SLAVE tools Hudson.model.JDK install21157619502298069log log
ERROR: SEVERE ERROR occurs
org.jenkinsci.lib.envinject.Envinjectexception: java.io.Ioexception: Cannot run program "PATH/TO/SLAVE/tools/Hudson.model.JDK/Jdk_8u91/jdk.exe" (in directory "PATH TO SLAVE Hudson.model.JDK Jdk_8u91"): Createprocess error=740, The requested operation requires elevation
at org.jenkinsci.plugins.envinject.service.EnvInjectVariableGetter.getBuildVariables(Envinjectvariablegetter.java:91)
[... lines omitted because they appear to be irrelevant ...]
Caused by: java.io.Ioexception: Cannot run program "PATH/TO/SLAVE/Hudson.model.JDK/Jdk_8u91/jdk.exe" (in directory "PATH TO SLAVE tools Hudson.model.JDK Jdk_8u91"): Createprocess error=740, The requested operation requires elevation
at java.lang.Processbuilder.start(Unknown Source)
[... lines omitted because they appear to be irrelevant ...]
Caused by: java.io.Ioexception: Createprocess error=740, Requested operation requires upgrade
at java.lang.Processimpl.create(Native Method)
[... lines omitted because they appear to be irrelevant ...]
I accessed the server slave and run the installation command line manually at the prompt with administrator permissions:
PATH/TO/SLAVE/tools/hudson.model.JDK/JDK_8u91/jdk.exe /s ADDLOCAL="ToolsFeature" REBOOT=ReallySuppress INSTALLDIR=PATH\TO\SLAVE\tools\hudson.model.JDK\JDK_8u91 /L PATH\TO\SLAVE\tools\hudson.model.JDK\install2115761959202298069log
However, when trying to build again, I got exactly the same error message. As if Jenkins hadn’t identified the existence of the newly installed JDK.
When trying to select Jdk8u25, Jenkins thought it was installed because it did not try to run the installer, but it is actually having an inconsistency in the system because the executable is not in the desired place:
[project-gwt] $ OTHER JENKINS tools Hudson.model.JDK Jdk_8u25 jdk1.8.0_25/bin/java -cp PATH/TO/SLAVE/maven31-agent.jar;PATH TO SLAVE tools Hudson.tasks.Maven_maveninstallation MVN_311 boot plexus-classworlds-2.5.1.jar;PATH TO SLAVE tools Hudson.tasks.Maven_maveninstallation MVN_311/conf/logging Jenkins.maven3.agent.Maven31main PATH/TO/SLAVE/tools/Hudson.tasks.Maven_maveninstallation/MVN_311 PATH TO USER Appdata Locallow Sun Java Deployment cache 6.0 3 893ffc3-1f519d29 PATH/TO/SLAVE/maven31-Interceptor.jar PATH/TO/SLAVE/maven3-Interceptor-Commons.jar 51822
ERROR: Failed to parse Poms
java.io.Ioexception: Cannot run program "OTHER JENKINS tools Hudson.model.JDK Jdk_8u25 jdk1.8.0_25/bin/java" (in directory "PATH TO SLAVE Workspace Geosales_portal portal"): Createprocess error=2, The system cannot find the specified file
at java.lang.Processbuilder.start(Unknown Source)
[... lines omitted because they appear to be irrelevant ...]
- How to install JDK via Jenkins on slave without needing high access?
- Or else, how to get around this situation, install so Sandboxed the JDK and be able to indicate to Jenkins that?
About fixing the GWT project to make the build fast... we’re working on it. There are 109 classes dealing with asynchronous GWT requests, made by passing HashMap
and receiving List
or List<HashMap>
as an answer. Yes, it was done raw originally. But the legacy work is too big to fix, we are working since last year between one customization and another to decrease the time that GWT is processing the oracle typing things, or using specific classes for the required purpose.
But this is not feasible to fix in the short term...
Is the slave running as a Windows service there on the other side? Maybe this gives a light (I don’t try to answer I don’t have any Windows machines here to try to replicate the problem, haha): https://community.smartbear.com/t5/TestComplete-General-Discussions/Jenkins-execution-gt-The-requested-operation-requires-elevationtd-p/144347
– nunks
@nunks.lol is not service,
jnlp
makes sense? That name came to mind– Jefferson Quesado
@nunks.lol, my VPN is not working. Monday I try to explore these options
– Jefferson Quesado
makes sense, jnlp is extension of Java Web Start, those services in which you download an applet... In this link q pasted one of the possible exits is to run the agent JNLP as a service in remote Windows.
– nunks