Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-5408

Quoting Issue with JDK Installer with Windows Slave

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Major Major
    • core
    • Hudson 1.342 on Windows XP Master w/ Windows XP Slaves

      When installing a new JDK on a windows slave, there appears to be a quoting issue with the arguments passed to the installer. From the console output:

      [jdk-1.6.0_17] $ C:\hudson-tmp\tools\jdk-1.6.0_17\jdk.exe /s '/v/qn REBOOT=Suppress INSTALLDIR=\"C:\hudson-tmp\tools\jdk-1.6.0_17\" /L \"C:\hudson-tmp\tools\jdk-1.6.0_17\jdk.exe.install.log\"'

      Notice how the /s is outside of the single quotes where the rest of the options are (/v/qn ...). Comments in the WINDOWS case of JDKInstaller.java#install seem to indicate that the options to the installer should be passed as one string. However, the code adds two strings - one for /s and another for the rest of the options.

      The result is that the jdk fails to install. However, executing C:\hudson-tmp\tools\jdk-1.6.0_17\jdk.exe /s /v/qn REBOOT=Suppress INSTALLDIR=\"C:\hudson-tmp\tools\jdk-1.6.0_17\" /L \"C:\hudson-tmp\tools\jdk-1.6.0_17\jdk.exe.install.log\" on a command prompt successfully installs the JDK.

          [JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave

          Rob Techstuff added a comment -

          Glad to see that this has been fixed. What needs to be done to get the fix into the next LTS version? Our Jenkins build farm runs both Linux and Windows slaves, and this problem forces us to manually install and configure OS-specific JDK versions on all slaves.

          Thanks.

          Rob Techstuff added a comment - Glad to see that this has been fixed. What needs to be done to get the fix into the next LTS version? Our Jenkins build farm runs both Linux and Windows slaves, and this problem forces us to manually install and configure OS-specific JDK versions on all slaves. Thanks.

          Halvor Platou added a comment -

          Any chance of getting this into the release soon? Looks like the pull request is still open.

          Halvor Platou added a comment - Any chance of getting this into the release soon? Looks like the pull request is still open.

          Halvor Platou added a comment -

          Please...

          Halvor Platou added a comment - Please...

          Pretty please?

          Christoph Linder added a comment - Pretty please?

          Diogo Guerra added a comment -

          I've tried @sogabe patch on 1.510 and it works. could you please accept the pull request?

          Diogo Guerra added a comment - I've tried @sogabe patch on 1.510 and it works. could you please accept the pull request?

          Code changed in jenkins
          User: Seiji Sogabe
          Path:
          core/src/main/java/hudson/tools/JDKInstaller.java
          http://jenkins-ci.org/commit/jenkins/fd4ccc106f603edfa5818befca271f1400bdbf96
          Log:
          [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Seiji Sogabe Path: core/src/main/java/hudson/tools/JDKInstaller.java http://jenkins-ci.org/commit/jenkins/fd4ccc106f603edfa5818befca271f1400bdbf96 Log: [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave

          Code changed in jenkins
          User: Seiji Sogabe
          Path:
          core/src/main/java/hudson/tools/JDKInstaller.java
          http://jenkins-ci.org/commit/jenkins/c86b6d7055a03db1add27acd4a0159ad7d024c17
          Log:
          Merge pull request #657 from ssogabe/JENKINS-5408

          [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave

          Compare: https://github.com/jenkinsci/jenkins/compare/d33e22d392a3...c86b6d7055a0

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Seiji Sogabe Path: core/src/main/java/hudson/tools/JDKInstaller.java http://jenkins-ci.org/commit/jenkins/c86b6d7055a03db1add27acd4a0159ad7d024c17 Log: Merge pull request #657 from ssogabe/ JENKINS-5408 [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave Compare: https://github.com/jenkinsci/jenkins/compare/d33e22d392a3...c86b6d7055a0

          dogfood added a comment -

          Integrated in jenkins_main_trunk #2452
          [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave (Revision fd4ccc106f603edfa5818befca271f1400bdbf96)

          Result = SUCCESS
          Seiji Sogabe : fd4ccc106f603edfa5818befca271f1400bdbf96
          Files :

          • core/src/main/java/hudson/tools/JDKInstaller.java

          dogfood added a comment - Integrated in jenkins_main_trunk #2452 [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave (Revision fd4ccc106f603edfa5818befca271f1400bdbf96) Result = SUCCESS Seiji Sogabe : fd4ccc106f603edfa5818befca271f1400bdbf96 Files : core/src/main/java/hudson/tools/JDKInstaller.java

          Code changed in jenkins
          User: Seiji Sogabe
          Path:
          core/src/main/java/hudson/tools/JDKInstaller.java
          http://jenkins-ci.org/commit/jenkins/9976bdfe18fdc5900064799448b49a6f5414b294
          Log:
          [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave
          (cherry picked from commit fd4ccc106f603edfa5818befca271f1400bdbf96)

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Seiji Sogabe Path: core/src/main/java/hudson/tools/JDKInstaller.java http://jenkins-ci.org/commit/jenkins/9976bdfe18fdc5900064799448b49a6f5414b294 Log: [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave (cherry picked from commit fd4ccc106f603edfa5818befca271f1400bdbf96)

          Code changed in jenkins
          User: Kohsuke Kawaguchi
          Path:
          http://jenkins-ci.org/commit/jenkins/47c122063cb2659e394ffd1e9260656e8ae15faf
          Log:
          Merge pull request #657 from ssogabe/JENKINS-5408

          [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave

          Cherry-picked-from: c86b6d7055a03db1add27acd4a0159ad7d024c17

          Compare: https://github.com/jenkinsci/jenkins/compare/f6a4832c5f8c^...47c122063cb2

          SCM/JIRA link daemon added a comment - Code changed in jenkins User: Kohsuke Kawaguchi Path: http://jenkins-ci.org/commit/jenkins/47c122063cb2659e394ffd1e9260656e8ae15faf Log: Merge pull request #657 from ssogabe/ JENKINS-5408 [FIXED JENKINS-5408] Quoting Issue with JDK Installer with Windows Slave Cherry-picked-from: c86b6d7055a03db1add27acd4a0159ad7d024c17 Compare: https://github.com/jenkinsci/jenkins/compare/f6a4832c5f8c ^...47c122063cb2

            Unassigned Unassigned
            calculu5 calculu5
            Votes:
            6 Vote for this issue
            Watchers:
            13 Start watching this issue

              Created:
              Updated:
              Resolved: