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

Windows service install fails with file in use

    XMLWordPrintable

    Details

    • Similar Issues:

      Description

      I want to install a slave service on a Windows machine. I start the slave using the launch button on the Web page. This works fine. I then select Rile/Install as Windows Service on the slave pop-up, and click OK. This results in a large stack trace (unfortunately not in a window with copy and paste) starting with:

      java.io.FileNotFoundException: c:\JenkinsTest\jenkins-slave.exe (The process cannot access the file because it is being used by another process)

        Attachments

          Activity

          Hide
          aberent Anthony Berent added a comment -

          There seems to be something slightly random about the behaviour. I have tried this a few more times on the same machine, and it occasionally works. It also worked on a different machine.

          Show
          aberent Anthony Berent added a comment - There seems to be something slightly random about the behaviour. I have tried this a few more times on the same machine, and it occasionally works. It also worked on a different machine.
          Hide
          ffromm Frederik Fromm added a comment -

          moved to master-slave component

          Show
          ffromm Frederik Fromm added a comment - moved to master-slave component
          Hide
          oleg_nenashev Oleg Nenashev added a comment -

          The error means there is already a service running in the directory. If there is an issue, it needs to be retested and reconfirmed after 5 years. Please reopen the ticket if it still happens

          Show
          oleg_nenashev Oleg Nenashev added a comment - The error means there is already a service running in the directory. If there is an issue, it needs to be retested and reconfirmed after 5 years. Please reopen the ticket if it still happens
          Hide
          mcimasze Marcin Cimaszewski added a comment -

          Just for future and not search after obvious things. I have reproduced that case.

          Steps to reproduce:

          1. master1 UI > Manage Jenkins > Manage Nodes
          2. add new node
          3. connect your agent1 to master1 via jnlp
          4. install connection as a service
          5. master2 UI > Manage Jenkins > Manage Nodes
          6. add new node
          7. connect your agent1 to master2 via jnlp
          8. try to install connection as a service

          Effect:
          Popup with statement as in description:

          java.io.FileNotFoundException: c:\JenkinsTest\jenkins-slave.exe (The process cannot access the file because it is being used by another process)
          

          To cross check that service is running execute from cmd:

          c:\JenkinsTest\jenkins-slave.exe status
          

          Resolution:
          Choose which master should utilize that agent and use another agent for another master

          Show
          mcimasze Marcin Cimaszewski added a comment - Just for future and not search after obvious things. I have reproduced that case. Steps to reproduce: master1 UI > Manage Jenkins > Manage Nodes add new node connect your agent1 to master1 via jnlp install connection as a service master2 UI > Manage Jenkins > Manage Nodes add new node connect your agent1 to master2 via jnlp try to install connection as a service Effect: Popup with statement as in description: java.io.FileNotFoundException: c:\JenkinsTest\jenkins-slave.exe (The process cannot access the file because it is being used by another process) To cross check that service is running execute from cmd: c:\JenkinsTest\jenkins-slave.exe status Resolution: Choose which master should utilize that agent and use another agent for another master

            People

            Assignee:
            oleg_nenashev Oleg Nenashev
            Reporter:
            aberent Anthony Berent
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: