Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-04 Thread Raouf
Of course i'm using a specific account when using ssh, however, when i 
disconnect (with the same account logged in) a slave from jenkins's 
interface, i get Disconnected by anonymous displayed

Concerning the FS, i was running the same version (1.456) for both masters 
and slaves, and it always worked well since each one launches a independent 
java process (some it doesn't matter whether they run from the same jar or 
not)

But when i moved to 1.518, it looks like there is some conflict (and i 
suspect the default port) when i launch two slaves, even with two different 
masters


Le jeudi 3 octobre 2013 22:24:27 UTC+2, LesMikesell a écrit :

 On Thu, Oct 3, 2013 at 1:52 PM, Raouf Abdelhamid 
 abdelham...@gmail.com javascript: wrote: 
  when not specified, jenkins seems to use an account called anonymous to 
  communicate with slaves 

 That doesn't make any sense to me in the context of ssh which is going 
 to need a specific matching account as a login on the target node. 

  What's the problem with using the same file system ? can you explain 
 please 
  ? 

 Where do the slave jar, etc., and other supporting files live?  Not to 
 mention the potential conflicts if you happen build the same job 
 concurrently. 

  ps: i'd like to remind you that it was working pretty well under 1.456, 
 so 
  what has changed since then ? 

 How many different versions of the slave.jar were you running then? 

 -- 
   Les Mikesell 
 lesmi...@gmail.com javascript: 


-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-04 Thread Les Mikesell
On Fri, Oct 4, 2013 at 2:51 AM, Raouf abdelhamid.ra...@gmail.com wrote:
 Of course i'm using a specific account when using ssh, however, when i
 disconnect (with the same account logged in) a slave from jenkins's
 interface, i get Disconnected by anonymous displayed

I think that refers to the user logged into the jenkins interface.
Did you log in and authenticate as some other user in the session
where you did the disconnect?

 Concerning the FS, i was running the same version (1.456) for both masters
 and slaves, and it always worked well since each one launches a independent
 java process (some it doesn't matter whether they run from the same jar or
 not)

How is running a different jar possible?   The server should
automatically download the current version of the jar files when
starting via ssh.

 But when i moved to 1.518, it looks like there is some conflict (and i
 suspect the default port) when i launch two slaves, even with two different
 masters

I thought you said it only happens when you start with your custom ssh
script, not the internal ssh support.  The ports used shouldn't
change.

-- 
   Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-04 Thread Les Mikesell
On Fri, Oct 4, 2013 at 2:09 PM, Raouf Abdelhamid
abdelhamid.ra...@gmail.com wrote:
 i was logged with another account (let's call it myAccount) however, when i
 shut down the slave from the jenkins nodes interface, it showed the previous
 message

This login was in the same web session?  Are you using the matrix
based security in jenkins, and if so, is the Anonymous user allowed to
connect/disconnect slaves?If you repeat this scenario, do you see
your login name in the top bar of the web page as you disconnect?

 i never said i was running a different jar, i said i was running a different
 java process.

I think it has to be a different jar if jenkins is starting it via
ssh, because it will download it for you.  Try setting up a different
user with no jars at all in the target directory.

 do you have any documentation about jenkins slaves ? I'd like to know more
 about the default behaviour in that kind of situation

No - but you could always poke through the source code.  But, I would
never have considered running two different masters for slaves in the
same space concurrently in the first place.   Why do you think they
shouldn't conflict with each other, especially when they need
different jars of the same name?Perhaps more to the point, why do
you want to do this?  Maybe there is a better approach to whatever it
is you are trying to do.

-- 
Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-03 Thread Raouf
By the way, i also noticed when using the built in ssh plugin, the slaves 
are launched by the anonymous account even if i created them with a 
specific admin user.


Le jeudi 3 octobre 2013 10:26:11 UTC+2, Raouf a écrit :

 What i don't understand is that my scripts worked well when i was using 
 1.456, i could use as many test slaves as i wanted without having conflicts 
 with the main slaves

 The issue occurs only since i moved my test instances to a 1.5xx version, 
 so i'd like to know what happened exactely, and how to get things back to 
 normal.

 Regards,
 Raouf.

 Le mardi 1 octobre 2013 17:42:12 UTC+2, LesMikesell a écrit :

 On Tue, Oct 1, 2013 at 10:18 AM, Raouf Abdelhamid 
 abdelham...@gmail.com wrote: 
  Actually i did try it and it worked well. But i don't know exactly wich 
  slave jar was lanched, and i can't just abandon the scripts since 
 they're 
  doing some other stuff (logging, restarting on fail ...etc.) 

 The built in support should take care of getting the right jar in the 
 right place for you - and probably doing everything else jenkins 
 needs... 

 In any case, I'd run under different users with different home 
 directories so the jars and other files don't clobber each other. 

 -- 
Les Mikesell 
  lesmi...@gmail.com 



-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-03 Thread Les Mikesell
On Thu, Oct 3, 2013 at 9:32 AM, Raouf abdelhamid.ra...@gmail.com wrote:
 By the way, i also noticed when using the built in ssh plugin, the slaves
 are launched by the anonymous account even if i created them with a specific
 admin user.


What is an anonymous account?

And are you trying to run in the same FS root?   I wouldn't expect
that to work at all, at least not concurrently.

-- 
   Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-03 Thread Raouf Abdelhamid
when not specified, jenkins seems to use an account called anonymous to
communicate with slaves

What's the problem with using the same file system ? can you explain please
?

ps: i'd like to remind you that it was working pretty well under 1.456, so
what has changed since then ?


2013/10/3 Les Mikesell lesmikes...@gmail.com

 On Thu, Oct 3, 2013 at 9:32 AM, Raouf abdelhamid.ra...@gmail.com wrote:
  By the way, i also noticed when using the built in ssh plugin, the slaves
  are launched by the anonymous account even if i created them with a
 specific
  admin user.
 

 What is an anonymous account?

 And are you trying to run in the same FS root?   I wouldn't expect
 that to work at all, at least not concurrently.

 --
Les Mikesell
  lesmikes...@gmail.com

 --
 You received this message because you are subscribed to a topic in the
 Google Groups Jenkins Users group.
 To unsubscribe from this topic, visit
 https://groups.google.com/d/topic/jenkinsci-users/sP31OAOj9k0/unsubscribe.
 To unsubscribe from this group and all its topics, send an email to
 jenkinsci-users+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-03 Thread Les Mikesell
On Thu, Oct 3, 2013 at 1:52 PM, Raouf Abdelhamid
abdelhamid.ra...@gmail.com wrote:
 when not specified, jenkins seems to use an account called anonymous to
 communicate with slaves

That doesn't make any sense to me in the context of ssh which is going
to need a specific matching account as a login on the target node.

 What's the problem with using the same file system ? can you explain please
 ?

Where do the slave jar, etc., and other supporting files live?  Not to
mention the potential conflicts if you happen build the same job
concurrently.

 ps: i'd like to remind you that it was working pretty well under 1.456, so
 what has changed since then ?

How many different versions of the slave.jar were you running then?

-- 
  Les Mikesell
lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Can't launch 2 slaves (having two different masters) on the same machine

2013-10-01 Thread Raouf
Hi everybody,

Ii'm using two servers, one for jenkins master, and one for the slave 
instance 

I'm using Jenkins 1.456 as a main stream version, and was trying to prepare 
an upgrade to 1.518, so i just installed another jenkins master for testing 
puropose, and defined different ports for each one (the main master and the 
test master)

then i added a slave node to the test-master, and i had already a slave 
node for the main master.

i launch each slave by calling a script through ssh, something like

ssh me@my-slaves-server '/home/me/ slave_test.ksh start'

and the script is calling slaves that way

nohup /.../JAVA-6/bin/java -Xms512m -Xmx1024m -Djava.io.tmpdir=/tmp -jar 
/.../hudson_slave/jar/${HUDSON_VERSION}/slave.jar -jnlpUrl 
http://${MASTER_HOST}:${MASTER_PORT}/computer/${SLAVE_HOST}/slave-agent.jnlp 
  

The problem is, each time i launch the test-slave the main-slave goes 
offline and i have this stack trace

ERROR: Unable to launch the slave agent for 
my-slaves-serverjava.io.EOFException 
http://stacktrace.jenkins-ci.org/search?query=java.io.EOFException: 
unexpected stream termination
at hudson.remoting.Channel.init(Channel.java:408) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.remoting.Channel.%3Cinit%3Eentity=method
at hudson.remoting.Channel.init(Channel.java:366) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.remoting.Channel.%3Cinit%3Eentity=method
at hudson.remoting.Channel.init(Channel.java:327) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.remoting.Channel.%3Cinit%3Eentity=method
at hudson.remoting.Channel.init(Channel.java:323) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.remoting.Channel.%3Cinit%3Eentity=method
at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:313) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.slaves.SlaveComputer.setChannelentity=method
at hudson.slaves.CommandLauncher.launch(CommandLauncher.java:122) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.slaves.CommandLauncher.launchentity=method
at hudson.slaves.SlaveComputer$1.call(SlaveComputer.java:200) 
http://stacktrace.jenkins-ci.org/search/?query=hudson.slaves.SlaveComputer$1.callentity=method
at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) 
http://stacktrace.jenkins-ci.org/search/?query=java.util.concurrent.FutureTask$Sync.innerRunentity=method
at java.util.concurrent.FutureTask.run(FutureTask.java:138) 
http://stacktrace.jenkins-ci.org/search/?query=java.util.concurrent.FutureTask.runentity=method
at 
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
 
http://stacktrace.jenkins-ci.org/search/?query=java.util.concurrent.ThreadPoolExecutor$Worker.runTaskentity=method
at 
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) 
http://stacktrace.jenkins-ci.org/search/?query=java.util.concurrent.ThreadPoolExecutor$Worker.runentity=method
at java.lang.Thread.run(Thread.java:662) 
http://stacktrace.jenkins-ci.org/search/?query=java.lang.Thread.runentity=method



Any ideas about this issue ?


Thanks in advance !


Regards,

Raouf.

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-01 Thread Les Mikesell
On Tue, Oct 1, 2013 at 9:30 AM, Raouf abdelhamid.ra...@gmail.com wrote:
 Hi everybody,

 Ii'm using two servers, one for jenkins master, and one for the slave
 instance

 I'm using Jenkins 1.456 as a main stream version, and was trying to prepare
 an upgrade to 1.518, so i just installed another jenkins master for testing
 puropose, and defined different ports for each one (the main master and the
 test master)

 then i added a slave node to the test-master, and i had already a slave node
 for the main master.

 i launch each slave by calling a script through ssh, something like

 ssh me@my-slaves-server '/home/me/ slave_test.ksh start'

 and the script is calling slaves that way

 nohup /.../JAVA-6/bin/java -Xms512m -Xmx1024m -Djava.io.tmpdir=/tmp -jar
 /.../hudson_slave/jar/${HUDSON_VERSION}/slave.jar -jnlpUrl
 http://${MASTER_HOST}:${MASTER_PORT}/computer/${SLAVE_HOST}/slave-agent.jnlp

 The problem is, each time i launch the test-slave the main-slave goes
 offline and i have this stack trace

 ERROR: Unable to launch the slave agent for my-slaves-server
 java.io.EOFException: unexpected stream termination
 at hudson.remoting.Channel.init(Channel.java:408)
 at hudson.remoting.Channel.init(Channel.java:366)
 at hudson.remoting.Channel.init(Channel.java:327)
 at hudson.remoting.Channel.init(Channel.java:323)
 at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:313)
 at hudson.slaves.CommandLauncher.launch(CommandLauncher.java:122)
 at hudson.slaves.SlaveComputer$1.call(SlaveComputer.java:200)
 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:662)



 Any ideas about this issue ?

What happens if you use the built-in ssh support instead of your own
script?   And for testing, I'd start the slave as a different user for
the 2nd instance.

-- 
   Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-01 Thread Raouf Abdelhamid
Actually i did try it and it worked well. But i don't know exactly wich
slave jar was lanched, and i can't just abandon the scripts since they're
doing some other stuff (logging, restarting on fail ...etc.)


2013/10/1 Les Mikesell lesmikes...@gmail.com

 On Tue, Oct 1, 2013 at 9:30 AM, Raouf abdelhamid.ra...@gmail.com wrote:
  Hi everybody,
 
  Ii'm using two servers, one for jenkins master, and one for the slave
  instance
 
  I'm using Jenkins 1.456 as a main stream version, and was trying to
 prepare
  an upgrade to 1.518, so i just installed another jenkins master for
 testing
  puropose, and defined different ports for each one (the main master and
 the
  test master)
 
  then i added a slave node to the test-master, and i had already a slave
 node
  for the main master.
 
  i launch each slave by calling a script through ssh, something like
 
  ssh me@my-slaves-server '/home/me/ slave_test.ksh start'
 
  and the script is calling slaves that way
 
  nohup /.../JAVA-6/bin/java -Xms512m -Xmx1024m -Djava.io.tmpdir=/tmp -jar
  /.../hudson_slave/jar/${HUDSON_VERSION}/slave.jar -jnlpUrl
  http://
 ${MASTER_HOST}:${MASTER_PORT}/computer/${SLAVE_HOST}/slave-agent.jnlp
 
  The problem is, each time i launch the test-slave the main-slave goes
  offline and i have this stack trace
 
  ERROR: Unable to launch the slave agent for my-slaves-server
  java.io.EOFException: unexpected stream termination
  at hudson.remoting.Channel.init(Channel.java:408)
  at hudson.remoting.Channel.init(Channel.java:366)
  at hudson.remoting.Channel.init(Channel.java:327)
  at hudson.remoting.Channel.init(Channel.java:323)
  at hudson.slaves.SlaveComputer.setChannel(SlaveComputer.java:313)
  at hudson.slaves.CommandLauncher.launch(CommandLauncher.java:122)
  at hudson.slaves.SlaveComputer$1.call(SlaveComputer.java:200)
  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:662)
 
 
 
  Any ideas about this issue ?

 What happens if you use the built-in ssh support instead of your own
 script?   And for testing, I'd start the slave as a different user for
 the 2nd instance.

 --
Les Mikesell
  lesmikes...@gmail.com

 --
 You received this message because you are subscribed to a topic in the
 Google Groups Jenkins Users group.
 To unsubscribe from this topic, visit
 https://groups.google.com/d/topic/jenkinsci-users/sP31OAOj9k0/unsubscribe.
 To unsubscribe from this group and all its topics, send an email to
 jenkinsci-users+unsubscr...@googlegroups.com.
 For more options, visit https://groups.google.com/groups/opt_out.


-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Can't launch 2 slaves (having two different masters) on the same machine

2013-10-01 Thread Les Mikesell
On Tue, Oct 1, 2013 at 10:18 AM, Raouf Abdelhamid
abdelhamid.ra...@gmail.com wrote:
 Actually i did try it and it worked well. But i don't know exactly wich
 slave jar was lanched, and i can't just abandon the scripts since they're
 doing some other stuff (logging, restarting on fail ...etc.)

The built in support should take care of getting the right jar in the
right place for you - and probably doing everything else jenkins
needs...

In any case, I'd run under different users with different home
directories so the jars and other files don't clobber each other.

-- 
   Les Mikesell
 lesmikes...@gmail.com

-- 
You received this message because you are subscribed to the Google Groups 
Jenkins Users group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.