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

slave-status : Would be nice to have the ability to assign slave-status port on a "per slave" basis

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Major Major
    • slave-status-plugin
    • None
    • slave-status 1.4
      hudson 1.345

      i have a single Sun box with 2 users. Each user is assigned a hudson slave on the same machine.
      i keep those two environments distinct because one is used for "CI builds" and the other to trigger "automated installation of our product". Keeping them separated allows me to do some damage control if, for example an automated installation came to get out of it's $WORKSPACE.

      Now to my problem : after reverifying, it seems that it affects the slavestatus listener :

      both point to the same machine (yet on different login account) with the same 3141 port. I suppose there is no way for it to know who's who.

      Feb 11, 2010 3:23:37 PM com.youdevise.hudson.slavestatus.SlaveListener call

      INFO: Slave-status listener starting

      Feb 11, 2010 3:23:37 PM com.youdevise.hudson.slavestatus.SlaveListener$1 run

      SEVERE: Could not listen on port

      java.net.BindException: Address already in use

      at java.net.PlainSocketImpl.socketBind(Native Method)

      at java.net.PlainSocketImpl.bind(PlainSocketImpl.java:365)

      at java.net.ServerSocket.bind(ServerSocket.java:319)

      at java.net.ServerSocket.<init>(ServerSocket.java:185)

      at java.net.ServerSocket.<init>(ServerSocket.java:97)

      at com.youdevise.hudson.slavestatus.SocketHTTPListener.waitForConnection(SlaveListener.java:129)

      at com.youdevise.hudson.slavestatus.SlaveListener$1.run(SlaveListener.java:63)

      at com.youdevise.hudson.slavestatus.Daemon.go(Daemon.java:16)

      at com.youdevise.hudson.slavestatus.SlaveListener.call(SlaveListener.java:83)

      at hudson.remoting.UserRequest.perform(UserRequest.java:114)

      at hudson.remoting.UserRequest.perform(UserRequest.java:48)

      at hudson.remoting.Request$2.run(Request.java:270)

      at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)

      at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)

      at java.util.concurrent.FutureTask.run(FutureTask.java:138)

      at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)

      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)

      at java.lang.Thread.run(Thread.java:619)

          [JENKINS-5616] slave-status : Would be nice to have the ability to assign slave-status port on a "per slave" basis

          I don't personally plan to fix this as we don't run multiple slaves on one machine at my shop and I don't think this is very common. However I'd be very pleased if someone else added the required features to slave-status. I think you'd need some way to assign ports per slave; I think you'd do that by
          1. putting a port setting on the configuration for each slave;
          2. leaving a common port setting on the main config page, as most people won't need to override on any of their slaves; and
          3. using the rule "listen on the common port, unless this particular slave has a port override, in which case listen on that".

          douglassquirrel added a comment - I don't personally plan to fix this as we don't run multiple slaves on one machine at my shop and I don't think this is very common. However I'd be very pleased if someone else added the required features to slave-status. I think you'd need some way to assign ports per slave; I think you'd do that by 1. putting a port setting on the configuration for each slave; 2. leaving a common port setting on the main config page, as most people won't need to override on any of their slaves; and 3. using the rule "listen on the common port, unless this particular slave has a port override, in which case listen on that".

          Oleg Nenashev added a comment -

          Fixed the component

          Oleg Nenashev added a comment - Fixed the component

          Yury Skindersky added a comment - - edited

          I have the same issue. I have a separate virtual machine for running GUI tests where slave agent is running from command line (because windows service configuration fails to run GUI tests even with desktop interaction enabled). But it seems I also need to setup active RDC connection to run my tests successfully. I decided to run one more slave on the same machine under another user which will setup loopback RDC connection to the same machine before main job start. But it fails to start the second slave on the same machine due to slave-status plugin which is listen to the same 3141 port. It seems Jenkins treats this case as a valid as we can see in official wiki page here: Running Multiple Agents on the Same Machine

          Yury Skindersky added a comment - - edited I have the same issue. I have a separate virtual machine for running GUI tests where slave agent is running from command line (because windows service configuration fails to run GUI tests even with desktop interaction enabled). But it seems I also need to setup active RDC connection to run my tests successfully. I decided to run one more slave on the same machine under another user which will setup loopback RDC connection to the same machine before main job start. But it fails to start the second slave on the same machine due to slave-status plugin which is listen to the same 3141 port. It seems Jenkins treats this case as a valid as we can see in official wiki page here: Running Multiple Agents on the Same Machine

            douglassquirrel douglassquirrel
            mmorizot mmorizot
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: