Re: Argument for removing old jobs

2015-07-16 Thread Sami Tikka
The old jobs take up disk space. The job configuration itself does not take
much, but if there are any build artifacts, there might be a lot of disk
space consumed by these jobs. Remember, Jenkins only deletes old build
artifacts when a new build has been run. If there are no new builds =>
nothing gets deleted.

The more jobs Jenkins has, the slower it is. Usually this is not a big
problem but if there are a lot of unnecessary jobs, your Jenkins will be
slower (and takes more RAM) than it needs.

The most important argument for deleting unnecessary jobs to me, however,
is clarity: If there are lots of jobs, it is more difficult to navigate and
find the job you are looking for. Good naming conventions and using Jenkins
views can help here but I have never had success getting people to follow
naming conventions...

Also, there might be maintenance overhead involved: For example, couple of
years ago my employer switched from Github Enterprise to Stash and I had to
go through a lot of jobs to reconfigure them. If you had old, obsolete
jobs, why would you reconfigure them? And if you didn't, they would not
work if anyone tried to run them. And what is the point of keeping jobs in
Jenkins that cannot be run? Jenkins is a job runner. Nothing else.

-- Sami


2015-07-16 17:21 GMT+03:00 VFloyd :

> Morning,
> Jumping straight to the point - we have jobs in our Jenkins instance that
> have not run in two years (successfully or unsuccessfully).  We have jobs
> that people set up months ago and have never run.  I have sent e-mails,
> made visits to peoples desks, made calls all trying to get people to take
> care of their jobs and I still have them out there.
>
> I started disabling anything that hadn't run successfully in 12 months.
> My boss says I am wrong for doing this.  I am also wrong for wanting to
> shelve or just put these job in a zip file.
>
> I have better things to do.  Can anyone give me a for or against leaving
> abandoned jobs in Jenkins?
>
> Vanetta
>
> --
> 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.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/jenkinsci-users/aa6a8dc4-a35c-4ea8-80ce-3fa7bf0bbb1d%40googlegroups.com
> 
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
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.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/jenkinsci-users/CAHW2-9EdZHN2-hTUytndecBzuDBUZ32tr0k-HZWYMYy8eGc6pQ%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.


Re: How to "link" a particular job with the promotion process without physically copying the artifacts

2013-07-12 Thread Sami Tikka
The easiest way is to copy one of the artifacts. I usually have an artifact 
which is a small file containing the output of "git describe". Because the file 
is small, it is quick to copy and fingerprint and can be used to link builds.

-- Sami

Marcin Zajączkowski  kirjoitti 10.7.2013 kello 17.24:

> Hi,
> 
> I'm currently playing with Promoted Build plugin in the pipeline managed by 
> Build Flow plugin.
> 
> In a simplified form I have three jobs (called from the master job using 
> Build Flow plugin):
> - a normal build of a project - job B
> - a deploy WAR artifact to a remote Tomcat - job D
> - a smoke testing runs against a remote Tomcat (with deployed app) - job S
> 
> I would like to promote a WAR built in a B job when it passes a smoke testing 
> (S).
> 
> The issue is that there is no relationship between B and other jobs (they are 
> triggered through a pipeline with a concrete B build specified as a 
> parameter). D uses artifacts from B (by Copy artifacts plugin), but S not. I 
> could copy artifacts from B or D to S, but it is very artificial - I don't 
> need them (and have performance drawbacks). I could also try to write some 
> Groovy code similar to the one used in FingerprintingCopyMethod in Copy 
> Artifacts plugin.
> 
> What is the easiest way to tell Jenkins (Promoted Build plugin) that given 
> artifact (fingerprint) is used by a specific build?
> 
> Marcin
> 
> -- 
> 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.
> 
> 

-- 
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: Execute shell withoout -xe in jenkins job

2013-07-10 Thread Sami Tikka
If you're worries about something semi-secret being visible in the console, 
perhaps https://wiki.jenkins-ci.org/display/JENKINS/Mask+Passwords+Plugin is 
something you could check.

-- Sami

VinodKumar  kirjoitti 10.7.2013 kello 15.47:

> Thanks for your reply Richard,
> my problem was actually that it shows up ppk files used in ssh or scp
> commands,
> plus It was not a good view of console if it prints each line of script in
> cosole.
> 
> Thanks & Regards
> 
> 
> 
> --
> View this message in context: 
> http://jenkins-ci.361315.n4.nabble.com/Execute-shell-withoout-xe-in-jenkins-job-tp4671266p4672391.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 

-- 
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: Execute shell withoout -xe in jenkins job

2013-07-07 Thread Sami Tikka
I blogged about this some time ago: 
http://thingsyoudidntknowaboutjenkins.tumblr.com/post/30255425955/why-does-jenkins-think-my-build-succeeded

-- Sami

VinodKumar  kirjoitti 1.7.2013 kello 10.36:

> Hi All,
> I am using execute shell option in jenkins.
> My problem is jenkins is using "/bin/sh -xe" to run the scripts
> thi "-xe" is causing failure for some options which are running fine without
> it.
> is there any option where I can avoid -xe option in jenkins?/
> 
> Thanks & Regards
> Vinod
> 
> 
> 
> --
> View this message in context: 
> http://jenkins-ci.361315.n4.nabble.com/Execute-shell-withoout-xe-in-jenkins-job-tp4671266.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 

-- 
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: Problem with database configuration - help appreciated

2013-05-14 Thread Sami Tikka
Are you trying to ste up database connections for DB2 in Jenkins or in a build 
that is executed by Jenkins?

Jave you set the CLASSPATH for Jenkins or in a build that is executed by 
Jenkins?

How did you set the CLASSPATH? If you want to set it in a build, have you 
verified it is there? How?

-- Sami

ifxtechie  kirjoitti 14.5.2013 kello 18.42:

> Hi,
> I am trying to setup database connections for DB2 in Jenkins; But, I am 
> getting the error as below:
> class not found:com.ibm.db2.jcc.db2driver
> I have included the environment variable to include the JDBC driver in the 
> CLASSPATH .I know this does not make sense to expect the database connection 
> to pick up this variable.
> I have tested this in a standalone program and works fine.
> I have invoked the similar java program as a job in Jenkins and it works.
> But, when tried to setup the Database Connections, it fails with the above 
> error.
> Any suggestion/help is much appreciated.
> Thanks
> Partha
> 
> -- 
> 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.
>  
>  

-- 
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: Manual deploy of the msbuild.zip plugin file into Jenkins

2013-05-14 Thread Sami Tikka
I believe Jenkins does not have any support for uploading msbuild/mstest into 
your Jenkins server. This is usually the case with build tools.

-- Sami

Matthew Wright  kirjoitti 14.5.2013 kello 22.24:

> Due to firewall restrictions, I have to download plugin packages and upload 
> them instead of using the update mechanism Jenkins provides.
> 
> How to do this for the msbuild.zip and mstest.zip deployment packages is the 
> question as I haven't found anything on this after a lengthy search.
> 
> TIA.
> 
> MW
> 
> -- 
> 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.
>  
>  

-- 
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: shutting down an apache instance in post-build actions

2013-05-14 Thread Sami Tikka
Try https://wiki.jenkins-ci.org/display/JENKINS/PostBuildScript+Plugin

-- Sami

Chris Withers  kirjoitti 13.5.2013 kello 13.46:

> Hi All,
> 
> How can I shut down an apache instance required for a job is the post-build 
> actions?
> 
> I want this to happen regardless of whether all of the build steps succeeded 
> or not...
> 
> cheers,
> 
> Chris
> 
> -- 
> Simplistix - Content Management, Batch Processing & Python Consulting
>- http://www.simplistix.co.uk
> 
> -- 
> 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.
> 
> 

-- 
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: Run job under different credentials

2013-05-12 Thread Sami Tikka
Use sudo or set up a dedicated slave for this job running in the same host 
running as the deploy user. I myself would use sudo because it allows better 
control on what exactly Jenkins can execute as the deploy user.

-- Sami

Aharon Twizer  kirjoitti 7.5.2013 kello 9.06:

> Hi Guys,
> 
> I'm trying to deploy my job artifacts to my Prod environment (All windows 
> servers).
> 
> The problem is that my Jenkins servers lays in one domain any my prod servers 
> are in a different one, so I must supply credentials for the deploy process.
> 
> How can I run specific job(The one that deploys to Prod) under different user 
> so the copy will be successful?
> 
> By the way I'm using proj script to copy the artifacts.
> 
> Thanks,
> -- 
> 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.
>  
>  

-- 
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: Force configuration in matrix build to be the last step

2013-04-04 Thread Sami Tikka
You cannot control the order in which matrix job builds its configurations.

You need to remove the configuration you want to run last and make a new 
non-matrix job. Then make the matrix job trigger a build of the non-matrix job.

If this is not good for you, please explain what you are trying to do and maybe 
we can suggest a better way to do it.

-- Sami

Adam Daughterson  kirjoitti 3.4.2013 kello 17.22:

> I have a matrix build with touchstone builds, multiple configurations, etc.  
> I have a step which should be the last step in the matrix (not a triggered 
> parameterized build, etc) and can't find a way to force the job to run that 
> last step last.
> I've tried using the "Run each configuration sequentially" option, but it 
> appears to only force the jobs to run serially.
> 
> Anyone have any suggestions on what I can do to get this desired 
> functionality?
> 
> Thanks in advance,
> 
> Adam
> 
> -- 
> 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.
>  
>  

-- 
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: Xcode Plugin: Unit test output stops

2013-04-02 Thread Sami Tikka
Do you mean the unit test output is lost but the tests complete? Do they anyway 
succeed?

Or did you mean the tests hang and never complete?

How did you install Jenkins? What is the environment?

-- Sami

Greg Cooksey  kirjoitti 20.3.2013 kello 16.54:

> Hi,
> 
> I'm having a problem with the Xcode plugin, and I'm not sure whether this is 
> the correct place to ask about plugin issues. Please let me know if there's 
> another place that would be more useful.
> 
> I'm working on getting application unit tests going in our CI environment, 
> and I'm seeing some weird behavior in Jenkins. All of my tests run, but I 
> only see the output from the first test in the Jenkins log. If I run 
> xcodebuild from the command line to run my unit tests, I get output from all 
> of the tests. Any ideas what could be going wrong, or suggestions for further 
> troubleshooting?
> 
> Thanks,
> 
> -Greg
> 
> -- 
> 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.
> 
> 

-- 
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: Copy Artifact from slave to master (ssh plugin) seems to take forever

2013-04-02 Thread Sami Tikka
I had a similar problem. I believe it was caused by Jenkins being unable to 
load and use some native code for file permissions or symlink creation. 

I solved it by upgrading Java to 1.7 in both master and slave.

-- Sami

David Mata  kirjoitti 26.3.2013 kello 9.57:

> I have had the same problem for months. Did you solve them?
> 
> -- 
> 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.
>  
>  

-- 
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: Workspaces and slave nodes

2013-04-02 Thread Sami Tikka
I myself have rarely considered this a problem. The workspace would anyway be 
overwritten by the next build, so it is better not to trust it's existence or 
contents.

If I need to debug a problem with a job, I either:

* Disable the job to prevent next build from overwriting the workspace or
* Configure the job to archive necessary debug logs and later access them via 
build artifacts.

If you really need to preserve the full workspace for your builds, you can of 
course tell Jenkins to archive every file in the workspace as build artifact or 
use https://wiki.jenkins-ci.org/display/JENKINS/Clone+Workspace+SCM+Plugin. 
This will be slow and might use a lot of disk space.

-- Sami

Kevin Fleming (BLOOMBERG/ 731 LEXIN)  kirjoitti 
26.3.2013 kello 22.25:

> This is my use case as well (slaves on EC2), and you are correct. I wouldn't 
> want to copy the entire workspace to the master after every job (that would 
> be quite time and disk space consuming), but not having it available later is 
> annoying.
> 
> I've got items on my to-do list to investigate whether some of the plugins I 
> use can be improved to not require the workspace to still be around, but this 
> only addresses part of the issue.
> 
> - Original Message -
> From: jenkinsci-users@googlegroups.com
> To: jenkinsci-users@googlegroups.com
> At: Mar 26 2013 16:02:16
> 
> OK, thanks for the explanation. In the case of using EC2 slaves that come
> and go quite frequently this seems to be problematic. I see there is a
> plugin that allows for copying from a slave to a master but even then it
> seems unlikely the workspace link would function correctly.
> 
> 
> On Tue, Mar 26, 2013 at 12:42 PM, Kevin Fleming (BLOOMBERG/ 731 LEXIN) <
> kpflem...@bloomberg.net> wrote:
> 
> > Yes, this is how it is expected to work. Access to the workspace is
> > performed through the open connection to the Jenkins slave on the node; the
> > workspace is not copied to the Jenkins master. This causes problems in some
> > areas; for example, the Warnings plugin does not copy referenced source
> > files to the master, it assumes they will still be available in the
> > workspace, which means if the node is not available, or the workspace has
> > been cleaned out, or the files have been changed, the linked-to file is not
> > available or doesn't match the warning.
> >
> > - Original Message -
> > From: jenkinsci-users@googlegroups.com
> > To: jenkinsci-users@googlegroups.com
> > At: Mar 26 2013 13:37:08
> >
> > I see the same behavior and certainly assume it is by design. The
> > workspaces are likely still there and can be accessed directly if
> > you're on that node itself, just not through Jenkins.
> >
> > Scott
> >
> > On Tue, Mar 26, 2013 at 12:30 PM, Robert Moore 
> > wrote:
> > > This behavior seems new to me but perhaps I've just overlooked it in the
> > > past. We are building slave nodes and after the nodes have gone offline
> > are
> > > not able to access the workspace (we see "Error: no workspace" when
> > trying
> > > to access it). Is this by design or a bug?
> > >
> > > Thanks,
> > >
> > > Rob
> > >
> > > --
> > > 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.
> > >
> > >
> >
> > --
> > 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.
> >
> >
> > --
> > 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/2Sfzzfz40T0/unsubscribe?hl=en
> > .
> > 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.
> >
> >
> >
> 
> 
> 
> --
> Robert Moore
> Architect
> PIF Data
> K-12 Technology
> 
> 400 Center Ridge Drive
> Austin, TX 78753-1034
> 
> D: 512.989.5476 (*Intra-Pearson: 22-5476*)
> M: 512.567.5192
> *
> *
> *Pearson*
> Always Learning
> 
> --
> 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.
> 
> 
> 
> -- 
> 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 je

Re: Jenkins fail to run any commands related to Tortoise

2013-04-02 Thread Sami Tikka
Having only passing knowledge of Windows development, I may be completely off 
the mark but here's my guess:

Tortoise is a GUI tool. You may have installed Jenkins as a service and by 
default services or processes started by them are not allows to interact with 
the GUI session. Check 
https://wiki.jenkins-ci.org/display/JENKINS/My+software+builds+on+my+computer+but+not+on+Jenkins
 under heading "Desktop access"

-- Sami

weirpenguin  kirjoitti 1.4.2013 kello 20.35:

> I was using the batch command "%SVN%\TortoiseProc.exe" /command:update
> /path:"%SOURCE%" /closeonend:1 " or calling the batch file from Jenkins to
> make svn update but failed, while it works when I run the batch file out of
> Jenkins. 
> In the output console, Jenkins just keeps running after the command related
> to tortoise 
> And it seems it is not authentication problem as it failed when I tried
> ""%SVN%\TortoiseProc.exe" /command:about", Jenkins just acted the same. 
> 
> As I am really new to Jenkins, is it possible that I miss some setting of
> Jenkins to make it work with Tortoise?
> 
> 
> 
> --
> View this message in context: 
> http://jenkins.361315.n4.nabble.com/Jenkins-fail-to-run-any-commands-related-to-Tortoise-tp4661143.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 

-- 
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: Newbie question: How to configure Jenkins to use bash with rcfile?

2013-04-01 Thread Sami Tikka
If you want to know how Jenkins runs the shell, why not ask Jenkins?

Let's do it programmatically by creating a small job and running it.

Create the job by running this:

cat <<'EOF' | curl -v -X POST -H "content-type: text/xml" --data-binary @- 
"$JENKINS_URL/createItem?name=shellkind" >/dev/null


  
  
  false
  
  
  true
  false
  false
  false
  
  false
  

  echo $-
case "$-" in
*i*) echo Interactive ;;
*l*) echo Login ;;
esac

  
  
  

EOF

Then trigger the build:

curl -v "$JENKINS_URL/job/shellkind/build"

Then read the console output of the job:

curl "$JENKINS_URL/job/shellkind/lastSuccessfulBuild/consoleText"

For me, it prints:

+ echo ehxB
ehxB
+ case "$-" in
Finished: SUCCESS

Because $- did not include i or l, the bash Jenkins runs for me is neither 
interactive nor login shell.

-- Sami

Hua  kirjoitti 31.3.2013 kello 18.24:

> Hi Sami,
> 
> Thank you very much for your reply. I have read the man page of bash and it
> helped me understanding the context much better. At the same time I got more
> questions. But first I probably should explain my case a little better:
> 
> Basically the projects we are trying to compile here through Jenkins are
> FPGA design projects. We usually use the tools from FPGA suppliers to
> compile the design in windows environment, both GUI and commanding line
> tools are available. For the command line tools, the supplier uses a batch
> file to setup the environment variables needed for their tools and then
> launches bash.exe in the cygwin/bin directory with --rcfile option to load
> their bash environment.
> 
> After I posted my question, I was able to source their rcfile in the
> beginning of my compilation script to get the bash environment right... But
> now I feel that's probably not the elegant way of solving the problem. So
> here comes my questions:
> 
> 1. When Jenkins launches bash, does it launch bash into interactive but no
> login mode? If not, which mode does it launch into?
> 2. Does Jenkins know where my home is in the cygwin environment? Even though
> the FPGA design tools comes with a cygwin installation, but it is tailed by
> the supplier so the paths and environment variables comes with a normal
> cygwin installation are intentionally removed from windows environment (so
> they can have multiple copies of their tools, therefore cygwin
> installations, coexisting in a PC... I think). For me however, I just need
> one copy of the tools visible to Jenkins, so I guess I could add those paths
> and environment variables in Jenkins. But do you know what are they?
> 
> I hope my questions are not too newbie-isheven a pointer to the right
> reading material would be much appreciated. 
> 
> Thanks again for your time!
> Hua
> 
> 
> 
> 
> 
> 
> 
> --
> View this message in context: 
> http://jenkins.361315.n4.nabble.com/Newbie-question-How-to-configure-Jenkins-to-use-bash-with-rcfile-tp4661046p4661091.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 

-- 
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: Newbie question: How to configure Jenkins to use bash with rcfile?

2013-03-31 Thread Sami Tikka
If you run "man bash" or check the bash man page online, you will see in the 
section "FILES" where the initialization files are and when they are read. Also 
check the section "INVOCATION" for more information.

-- Sami

Hua Ai  kirjoitti 30.3.2013 kello 18.32:

> The bash shell is from cygwin, I know I can invoke the rcfile I want by run 
> bash.exe with a --rcfile switch in Windows Commandline window, but how can I 
> achieve the same thing through Jenkins?
> 
> 
> On Saturday, March 30, 2013 12:56:42 AM UTC-6, Hua Ai wrote:
> Hi there,
> 
> I need to configure Jenkins to run bash.exe with a custom bashrc, is it 
> possible? I know I can provide the absolute path to shell executable in 
> configuration page, and tried adding --rcfile to it and it didn't work.
> 
> Thanks,
> Hua
> 
> -- 
> 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.
>  
>  

-- 
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: Looking for good Linux bash script examples

2013-03-31 Thread Sami Tikka
It never ceases to amaze me how people refuse to make use of the exit code of 
unix commands to write readable shell scripts.

So, instead of writing

> make my_target
> if [[ $? -ne 0 ]]; then
>   ret=1
>   echo "Make has failed" >&2
> fi

You could make it simpler:

if ! make my_target; then
echo "Make has failed" >&2
fi

I usually keep the if command simple and write that as:

if make my_target; then
:
else
echo "Make has failed" >&2
fi

However, I do not usually go for such structures in Jenkins scripts. Jenkins 
runs the scripts with "/bin/sh -xe", which is a good choice: You see the steps 
executed and the first step that fails, aborts the script. Just like when you 
use make and Makefile, usually you want all the steps in your build step to 
succeed, or at least I do.

The few places that I do not care, I either wrap into set +e/set -e or append " 
|| true", if it was just a single command.

If you use the scripts also interactively, it is good to have code to clean up 
background processes. If the scripts are for Jenkins, you do not need to care. 
Jenkins will find the background processes and kill them.

-- Sami

bl0ck3r  kirjoitti 31.3.2013 kello 5.42:

> Bash is very good when the problem is solved by running unix commands. 
> Learning bash is key, and I strongly recommend the O'Reilly book "Learning 
> the bash shell". The bash shell is mature and even if the book does not cover 
> bash 4, all the fundamentals are there. I can recommend three sites for bash:
> http://mywiki.wooledge.org/EnglishFrontPage
> http://wiki.bash-hackers.org/doku.php
> http://tldp.org/LDP/abs/html/
> 
> Exit codes are easy to master. An exit code of zero means the command has 
> "passed", anything else means the command has failed somehow. For example:
> make my_target
> if [[ $? -ne 0 ]]; then
>   ret=1
>   echo "Make has failed" >&2
> fi
> 
> I keep all my problems in the pass/fail category, and I never try to 
> interpret non-zero exit codes because it gets too complicated. However it is 
> key that any script underneath returns an exit code to its caller, all the 
> way up to Jenkins, so make sure your Jenkins build step has an exit statement 
> with an exit code that represents the "worst" error reported underneath.
> 
> If you use pipes, you should always use "set -o pipefail". This will make 
> sure that the pipe will not hide a failure (see man bash):
> $ (exit 1 | echo "hi")
> hi
> $ echo $?
> 0
> $ set -o pipefail
> $ (exit 1 | echo "hi")
> hi
> $ echo $?
> 1
> 
> Now regarding Jenkins, when you have a parametrized build, Jenkins exports 
> those parameters as shell variables that match your parameter names. You can 
> see them in the console by adding the "env" command to your free style build. 
> Also I recommend you always use the shebang to start your free style build 
> (Jenkins will run your script with the -e option, but there are too many 
> exceptions to "set -e", so I just use #!/bin/bash, see: 
> http://mywiki.wooledge.org/BashFAQ/105)
> 
> If you background jobs, you will need to keep track of their process ids, for 
> example set a trap:
> function onKill {
>   kill $pid
>   ... other clean up you might want to do goes here
> }
> ./my_script & pid=$!
> trap 'onKill; exit 1;' SIGINT SIGTERM
> wait $pid
> if [[ $? -ne 0 ]];
>   echo "my_script failed" &2
> fi
> 
> You will also need to generate JUnit XML reports in the format that Jenkins 
> understand. Java is not the language of my builds, and it was very painful to 
> figure out what Jenkins supported. It was a lot of trial an error, and there 
> are many unclear explanations on the internet. I ended up with something 
> similar to this: 
> http://pzolee.blogs.balabit.com/2012/11/jenkins-vs-junit-xml-format/
> 
> My bash build step does not generate XML reports, but commands inside GNU 
> Make, which is called by my script, do (it is actually many layers below the 
> Jenkins "script window" in my case).
> 
> Last advice, keep the code in the build phase window to the bare minimum: put 
> all the smarts in a script that Jenkins calls instead. This way you don't 
> have to copy and paste bug fixes when you have the same script in multiple 
> builds: you simply fix the script that Jenkins calls.
> 
> Bash is very powerful if you learn it well. If you need to manipulate data 
> structures, then you will need to move up to a higher level language like 
> python, but if all your build does is call commands and watch exit codes, 
> bash will do the job really well.
> 
> Good luck.
> 
> -- 
> 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.
>  
>  

-- 
You received this message because you are subscribed to the Google Groups 
"Jenkins Users" group.
To unsubscribe from this group and stop rece

Re: Jenkins empties folders sometimes?? - why

2013-03-08 Thread Sami Tikka
Yes, Jenkins does that sometimes. I think the idea is to make sure the 
workspace is kept clean and also to free up disk space by getting rid of 
sources on slaves that have not been used for a while. If this is a problem for 
you, take a look at property hudson.model.WorkspaceCleanupThread.disabled at 
https://wiki.jenkins-ci.org/display/JENKINS/Features+controlled+by+system+properties

-- Sami

Kenneth Nielsen  kirjoitti 8.3.2013 kello 15.37:

> Hi there,
> 
> I've setup Jenkins to run on some virtual clients. I monitor subversion, and 
> can get source from that. but sometimes Jenkins (or something else) deletes 
> the folders on my virtual PC. causing Jenkins to need a full checkout.
> Has anyone run into that behavior before? 
> 
> thanks for any tips
> Kenneth
> 
> -- 
> 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.
>  
>  

-- 
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: build test failed while using selenium in jenkins

2013-03-02 Thread Sami Tikka
Just a guess, but check 
https://wiki.jenkins-ci.org/display/JENKINS/My+software+builds+on+my+computer+but+not+on+Jenkins
under the title "Desktop access"

-- Sami

Aqy  kirjoitti 27.2.2013 kello 10.10:

> hi, 
> 
> im using selenium in jenkins..i have done configure build.xml file but when i 
> run the build now..build became failed on console output..can anyone help?im 
> already redirect the ant folder to here 
>  C:\Program 
> Files\apache-ant-1.8.4-bin\apache-ant-1.8.4\lib\seleniun_ant_script\seleniumTask\selenium_server.jar
> 
> 
> 
> -- 
> 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.
>  
>  

-- 
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: Frequent crashes

2013-03-02 Thread Sami Tikka
Unless someone comes up with better advice, I would suggest you remove/disable 
the Active Directory plugin and try if it still crashes.

-- Sami

Michael Fowler  kirjoitti 28.2.2013 kello 18.21:

> So It crashed again last night. No one was logged into the server and no jobs 
> were running. Any idea what happened? From the err.log
> 
> Feb 27, 2013 6:56:21 PM winstone.Logger logInternal
> WARNING: Untrapped Error in Servlet
> java.lang.NullPointerException
> at 
> hudson.plugins.active_directory.ActiveDirectoryAuthenticationProvider.retrieveUser(ActiveDirectoryAuthenticationProvider.java:88)
> at 
> org.acegisecurity.providers.dao.AbstractUserDetailsAuthenticationProvider.authenticate(AbstractUserDetailsAuthenticationProvider.java:119)
> at 
> org.acegisecurity.providers.ProviderManager.doAuthentication(ProviderManager.java:195)
> at 
> org.acegisecurity.AbstractAuthenticationManager.authenticate(AbstractAuthenticationManager.java:45)
> at 
> org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:138)
> at 
> hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
> at jenkins.security.ApiTokenFilter.doFilter(ApiTokenFilter.java:64)
> at 
> hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
> at 
> org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
> at 
> hudson.security.HttpSessionContextIntegrationFilter2.doFilter(HttpSessionContextIntegrationFilter2.java:66)
> at 
> hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:87)
> at 
> hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
> at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:164)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at 
> org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:50)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at 
> hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at winstone.RequestDispatcher.forward(RequestDispatcher.java:331)
> at 
> winstone.RequestHandlerThread.processRequest(RequestHandlerThread.java:227)
> at winstone.RequestHandlerThread.run(RequestHandlerThread.java:150)
> at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
> at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
> at java.util.concurrent.FutureTask.run(Unknown Source)
> at winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
> at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
> at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
> at java.lang.Thread.run(Unknown Source)
> 
> 
> 
> stdout: 
> #
> # A fatal error has been detected by the Java Runtime Environment:
> #
> #  EXCEPTION_ACCESS_VIOLATION (0xc005) at pc=0x77cae3be, pid=4648, 
> tid=2960
> #
> # JRE version: 6.0_41-b02
> # Java VM: Java HotSpot(TM) Client VM (20.14-b01 mixed mode, sharing 
> windows-x86 )
> # Problematic frame:
> # C  [ntdll.dll+0x2e3be]
> #
> # An error report file with more information is saved as:
> # C:\Windows\system32\hs_err_pid4648.log
> #
> # If you would like to submit a bug report, please visit:
> #   http://java.sun.com/webapps/bugreport/crash.jsp
> # The crash happened outside the Java Virtual Machine in native code.
> # See problematic frame for where to report the bug.
> #
> 
> [error occurred during error reporting , id 0xc005]
> 
> 
> On Tue, Feb 19, 2013 at 10:07 AM, Michael Fowler  
> wrote:
> Thanks James,
>  I've added that to the config, we'll see what happens next time it crashes.
> -Michael
> 
> 
> On Tue, Feb 19, 2013 at 4:38 AM, teilo  wrote:
> Presumably the service account under which Jenkins is running does not have 
> write permissions in the system32 folder.
> 
> You may want to add 
> “-XX:ErrorFile=c:\some\path\where\jenkins\can\write\hs_err_.log” to your 
> Jenkins JVM startup options so that in the event of a crash the log can be 
> found.  
> 
> It may be caused by a fault in the JDK - and you may want to submit a bug 
> report to Oracle with this log file.
> 
> /James
> 
> 
> On Monday, 18 February 2013 19:47:50 UTC, MDKF wrote:
> Hi Stuart,
>  Thanks for the link. It has happened while viewing the console output, but 
> we don't have any slave machines, just two executors on the master. But as in 
> the bug report we don't have .log files either. 
> 
> 
> On Mon, Feb 18, 2013 at 2:40 PM, Stuart Whelan 
>  wrote:
> Could it be related

Re: SVN 1.4 and SVN 1.7.5

2013-03-02 Thread Sami Tikka
I haven't used subversion a lot but according to my understanding, it really is 
not a concern.

http://subversion.apache.org/docs/release-notes/1.7.html says:

"Older clients and servers interoperate transparently with 1.7 servers and 
clients."

Or did you test it and found the compatibility was not working as advertised?

Maybe you could tell us a bit more why you need "2 different versions of SVN"?

-- Sami

Rahul k a  kirjoitti 28.2.2013 kello 22.11:

> Hi,
>  
> How to use 2 different versions of SVN (1.4 & 1.7.5) for 2 different 
> projects.?
>  
> Thanks,
> Rahul
> 
> -- 
> 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.
>  
>  

-- 
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: Jenkins Master slave connection issue

2013-03-02 Thread Sami Tikka
Sometimes you might be able to use "external jobs": 
https://wiki.jenkins-ci.org/display/JENKINS/Monitoring+external+jobs

They aren't as feature rich as normal jobs, but maybe you can use it as a 
workaround.

-- Sami

"Mandeville, Rob"  kirjoitti 28.2.2013 kello 21.24:

> As far as I can tell, Jenkins slaves cannot handle connectivity blips.  I 
> think that it assumes LAN connectivity.  Maybe you can ask your network admin 
> and see if there’s a way to keep those connections up, or at least make it 
> look like they are.
>  
> Failing that, can you put a second Jenkins server on the remote site?
>  
> --Rob
>  
> From: jenkinsci-users@googlegroups.com 
> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of Arvi
> Sent: Thursday, February 28, 2013 2:20 PM
> To: jenkinsci-users@googlegroups.com
> Subject: Jenkins Master slave connection issue
>  
> Hi All, 
> 
> We are using Jenkins model of Upstream-downstream builds. 
> I have number of Slaves hosted in a remote office and the tests are triggered 
> by Main build. These tests runs for hours. 
> The issue I have is, some times we see network blips which disconnects slave 
> for few seconds 
> and the whole build is lost and have no way to retrieve it or restore the 
> build back once the connection is re-established. 
> 
> Is there anyway in Jenkins to handle such network blips !? 
> May be using the Process ID and tracking or something or I'm I missing some 
> key configurations? 
> Its really painful to kill all the stray jobs from previous build, then 
> re-kick the jobs and  wait for hours. 
> 
> Appreciate your help, 
> Thanks!
> 
> -- 
> 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.
>  
>  
> The information in this message is for the intended recipient(s) only and may 
> be the proprietary and/or confidential property of Litle & Co., LLC, and thus 
> protected from disclosure. If you are not the intended recipient(s), or an 
> employee or agent responsible for delivering this message to the intended 
> recipient, you are hereby notified that any use, dissemination, distribution 
> or copying of this communication is prohibited. If you have received this 
> communication in error, please notify Litle & Co. immediately by replying to 
> this message and then promptly deleting it and your reply permanently from 
> your computer.
> 
> -- 
> 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.

-- 
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: Jobs starting on slaves with no disk space

2013-03-02 Thread Sami Tikka
I have a couple of jobs also that screw up the slave so badly it has to be 
taken offline and fixed before it can be used again. I do it using the Groovy 
plugin and this system groovy script which runs in a build step:

import hudson.model.*
def thr = Thread.currentThread()
def build = thr?.executable
build.getBuiltOn().toComputer().setTemporarilyOffline(true)

The upside is it requires no authentication and does not require the slave to 
be able to connect to master. These slaves happen to run in an isolated network 
that blocks connections to the network where the master sits.

-- Sami

William Soula  kirjoitti 1.3.2013 kello 21.56:

> Create a downstream job that kills the slave by running the following command:
> curl -d 
> "offlineMessage=&json=%7B%22offlineMessage%22%3A+%22%22%7D&Submit=Yes" 
> http://[user]:[userApi]@[jenkinsServer]/computer/[slaveName]/doDisconnect
> 
> you can leave off [user]:[userApi] if authentication is not necessary.  
> Probably need to change the setting for keeping the slave online.
> 
> Will
> 
> 
> From: jenkinsci-users@googlegroups.com [jenkinsci-users@googlegroups.com] on 
> behalf of Pawel [pgronkiew...@gmail.com]
> Sent: Monday, February 25, 2013 2:29 AM
> To: jenkinsci-users@googlegroups.com
> Subject: Re: Jobs starting on slaves with no disk space
> 
> That's not a solution I can accept - I need those workspaces at least for
> some time. They are being wiped out every 24h.
> For me it looks like a bug in Jenkins - as problems like that shouldn't
> happen.
> 
> 
> 
> --
> View this message in context: 
> http://jenkins.361315.n4.nabble.com/Jobs-starting-on-slaves-with-no-disk-space-tp4656054p4656972.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 
> -- 
> 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.
> 
> 

-- 
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: Multi-configuration job

2013-02-27 Thread Sami Tikka
The subdirectory "default" is not created if you do not use a 
multiconfiguration project. 

This reply is probably not useful for you. Could you explain why you need to 
get rid of the default directory? I myself have never needed to customize the 
directory layout of JENKINS_HOME

-- Sami

Aswini Rajasekaran  kirjoitti 25.2.2013 kello 
14.45:

> Hi,
> 
> When I create a multi-configuration job in Jenkins, it creates a directory 
> called default inside jobs//workspace directory.
> This is not the case with free-style jobs or Maven jobs. What should I do to 
> get rid of the default directory?
> Thanks
> -- 
> 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.
>  
>  

-- 
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: Run Jenkins under different Linux user

2013-02-27 Thread Sami Tikka
It depends on how you installed Jenkins.  If you used the Jenkins Debian 
package, you probably want to check /etc/default/jenkins.

-- Sami

mwpowellhtx  kirjoitti 27.2.2013 kello 13.33:

> Hello,
> 
> I've installed under Ubuntu Linux and have the service running as
> "anonymous". I want it to run under a jenkins user, and set the home
> to something other than /var/lib/path/to/workspace, more like /home/
> jenkins/path/to/workspace.
> 
> I've identified the /etc/init.d/jenkins script. Is it here where we
> set the JENKINS_USER, JENKINS_BASEDIR, and so on?
> 
> https://wiki.jenkins-ci.org/display/JENKINS/JenkinsLinuxStartupScript
> 
> I'm thinking probably so, but I wonder if anyone has done this before
> and can witness.
> 
> Regards,
> 
> Michael
> 
> -- 
> 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.
> 
> 

-- 
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: copying build artifacts from triggering parent of a triggering job

2013-02-27 Thread Sami Tikka
You could pass a parameter to Middle, telling it where to copy artifacts. Child 
can then copy from Middle

-- Sami

Chris Withers  kirjoitti 27.2.2013 kello 16.11:

> Hi All,
> 
> I have a job hierarchy like this:
> 
> 
> 
> Middle copies an artifact from either parent1 or parent2, depending on which 
> job triggered it.
> When middle succeeds, it triggers child.
> I would like child to copy artifacts from the upstream parent1 or parent2 job 
> that triggered middle.
> 
> I've done the recommended trick of putting "copy artifacts" into middle for 
> both parent1 and parent2, selecting "upstream build that triggered this job" 
> and also checking "optional". 
> 
> Sadly, this doesn't work for child. I would expected the "upstream build that 
> triggered this job" of parent1, even in child, to work, but it appears that 
> only directly triggering jobs count. That's a shame, I guess the artifact 
> copier plugin should be improved?
> 
> In the meantime, can anyone explain how I can get the triggering and artifact 
> flow that I want?
> 
> cheers,
> 
> Chris
> -- 
> Simplistix - Content Management, Batch Processing & Python Consulting
> - http://www.simplistix.co.uk
> -- 
> 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.
>  
>  

-- 
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: error Code 500 trying to use git plugin in jenkins

2013-02-25 Thread Sami Tikka
Would it be possible to see your job configuration?

-- Sami

Kamal Ahmed  kirjoitti 25.2.2013 kello 20.27:

> I am using Jenkins 1.500 on ubuntu 12.04
> and using git plugin version 1.2.0 
> https://wiki.jenkins-ci.org/display/JENKINS/Git+Client+Plugin
> The target system is debian
> 
> I have created a Dummy user on the Target System ( Where the git repo is ) 
> user =  "jenkins"
> 
> from my slave  i am able to do a git clone :
> 
> on command line it works:
> 
> git clone n.n.n.n:/../repo.git
> Cloning into 'repo'...
> remote: Counting objects: 1106, done.
> remote: Compressing objects: 100% (844/844), done.
> remote: Total 1106 (delta 401), reused 590 (delta 141)
> Receiving objects: 100% (1106/1106), 46.40 MiB | 19.58 MiB/s, done.
> Resolving deltas: 100% (401/401), done.
> 
> i have also used : Global Config user.name Value = jenkins in the Git plugin 
> section , and email = my valid email.
> 
> but when i try to use the same URL, i get:
> 
>  Code: 500
> Exception: java.lang.NullPointerException
> Stacktrace:
> 
> javax.servlet.ServletException: java.lang.NullPointerException
> at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:615)
> at org.kohsuke.stapler.Stapler.invoke(Stapler.java:658)
> at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:241)
> at 
> org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
> at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:573)
> at org.kohsuke.stapler.Stapler.invoke(Stapler.java:658)
> at org.kohsuke.stapler.MetaClass$6.doDispatch(MetaClass.java:241)
> at 
> org.kohsuke.stapler.NameBasedDispatcher.dispatch(NameBasedDispatcher.java:53)
> at org.kohsuke.stapler.Stapler.tryInvoke(Stapler.java:573)
> at org.kohsuke.stapler.Stapler.invoke(Stapler.java:658)
> at org.kohsuke.stapler.Stapler.invoke(Stapler.java:487)
> at org.kohsuke.stapler.Stapler.service(Stapler.java:164)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:45)
> at winstone.ServletConfiguration.execute(ServletConfiguration.java:248)
> at winstone.RequestDispatcher.forward(RequestDispatcher.java:333)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:376)
> at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:95)
> at 
> net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:206)
> at 
> net.bull.javamelody.MonitoringFilter.doFilter(MonitoringFilter.java:179)
> at 
> net.bull.javamelody.PluginMonitoringFilter.doFilter(PluginMonitoringFilter.java:86)
> at 
> org.jvnet.hudson.plugins.monitoring.HudsonMonitoringFilter.doFilter(HudsonMonitoringFilter.java:84)
> at hudson.util.PluginServletFilter$1.doFilter(PluginServletFilter.java:98)
> at hudson.util.PluginServletFilter.doFilter(PluginServletFilter.java:87)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at hudson.security.csrf.CrumbFilter.doFilter(CrumbFilter.java:47)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at 
> hudson.security.ChainedServletFilter$1.doFilter(ChainedServletFilter.java:84)
> at 
> hudson.security.ChainedServletFilter.doFilter(ChainedServletFilter.java:76)
> at hudson.security.HudsonFilter.doFilter(HudsonFilter.java:164)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at 
> org.kohsuke.stapler.compression.CompressionFilter.doFilter(CompressionFilter.java:50)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at 
> hudson.util.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:81)
> at winstone.FilterConfiguration.execute(FilterConfiguration.java:194)
> at winstone.RequestDispatcher.doFilter(RequestDispatcher.java:366)
> at winstone.RequestDispatcher.forward(RequestDispatcher.java:331)
> at 
> winstone.RequestHandlerThread.processRequest(RequestHandlerThread.java:215)
> at winstone.RequestHandlerThread.run(RequestHandlerThread.java:138)
> 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 winstone.BoundedExecutorService$1.run(BoundedExecutorService.java:77)
> 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)
> Caused by: java.lang.NullPointerException
> at 
> hudson.plugins.git.UserRemoteConfig$DescriptorImpl.doCheckUrl(UserRemoteConf

Re: Configuration error

2013-02-25 Thread Sami Tikka
Or the use running Jenkins is not allowed to see that file. Those pesky file 
permissions...

-- Sami

alok kumar  kirjoitti 25.2.2013 kello 16.23:

> Hi,
> Try giving the ip address of the machine on which you have that srcsafe.ini 
> and see if it works.
> I guess that the machine on which the job is running isn't able to resolve 
> inv23webapps4.
> 
> Thanks
> 
> On Mon, Feb 25, 2013 at 5:11 PM, Share Point 2010  
> wrote:
>> Hello,
>> 
>> I am newbie in Jenkins.I am trying to run one command on command prompt 
>> window and given the following configuration, please refer the attached 
>> screenshot of configuration and following is the error which i am facing:
>> 
>> Building remotely on inv23webapps2 in workspace E:\Jenkins\workspace\Testing 
>> [checkout] Checking previous build [history] Getting list of changes since 
>> Mon Feb 25 16:26:11 IST 2013 java.io.IOException: 
>> \\inv23webapps4\VSSData\srcsafe.ini doesn't exist. Configuration error?
>> at scm.vss.VSSSCM.getHistoryEntries(VSSSCM.java:286) at 
>> scm.vss.VSSSCM.getHistoryEntries(VSSSCM.java:266) at 
>> scm.vss.VSSSCM.checkout(VSSSCM.java:200) at 
>> hudson.model.AbstractProject.checkout(AbstractProject.java:1342) at 
>> hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:683)
>>  at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88) at 
>> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:588)
>>  at hudson.model.Run.execute(Run.java:1568) at 
>> hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) at 
>> hudson.model.ResourceController.execute(ResourceController.java:88) at 
>> hudson.model.Executor.run(Executor.java:237) Finished: FAILURE 
>> 
>> Thanks,
>> Shweta
>> -- 
>> 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.
> 
> -- 
> 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.
>  
>  

-- 
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: Guidance: setting up to build linux distribution

2013-02-24 Thread Sami Tikka
Jenkins will not build your linux distribution for you. But if you have a 
script that does it, Jenkins can run that script.

So it all depends on how your linux distribution is built, what tools does it 
use, how are those tools run and where and in what kind of environment are they 
run...

In general, I think a linux distribution is such a huge piece of software that 
you are anyway better off studying the distribution's build process and using 
it as is or only tweaking it as little as possible for your needs. Coming up 
with your own build process with Jenkins in mind would probably be a gargantuan 
effort.

You can probably still use Jenkins to run the build scripts, distribute the 
work and collect the results. But how exactly to do that depends heavily on the 
details of the distro's build process.

-- Sami

mwpowellhtx  kirjoitti 23.2.2013 kello 21.02:

> Hello,
> 
> We've got a linux distribution we are customizing to target our
> embedded device. I'd like to automate this process through a CI server
> running on Ubuntu 10.04 so that we can capture distro updates,
> versions, etc. If it's germane, also get some clue how to capture any
> bootstrap processes as an outcome of the CI process: by capture I mean
> making the tools available that make it possible to bootstrap and
> install the OS and/or other services and apps in a production
> environment.
> 
> Obviously, I am asking the question here because I'd like to do it
> "simply" through something easier like a Jenkins. That's also more
> familiar because I am running Jenkins already for other products only
> from a Windows environment perspective, so accelerates time to market.
> 
> Thanks!
> 
> Regards,
> 
> Michael
> 
> -- 
> 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.
> 
> 

-- 
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: ActiveDirectory plugin is unable to detect group membership of one particular user

2013-02-22 Thread Sami Tikka
It might be useful to glance over the plugin source code and check what kind of 
things the plugin logs with debug level. Then go to Manage Jenkins, System Logs 
and set up a new debug level logger for the active directory plugin. Maybe you 
will learn more this way.

And if the plugin does not log enough, you could fork the plugin and add more 
logging yourself.

-- Sami

Markus KARG  kirjoitti 20.2.2013 kello 12.26:

> We're using the current ActiveDirectory plugin to authenticate and 
> role-based-authorize our AD users in Jenkins 1.502.
>  
> It is working well -- but not for one particular user. If she is logging in, 
> the following message is found in the log and no group memebership (hence no 
> role) is found:
>  
> WARNUNG: Failed to retrieve tokenGroups for CN=XXX 
> YYY,OU=My-Users,DC=MyDomain,DC=local
> In fact, with that account there is no special thing, she is in the same 
> group as we all are.
>  
> How to get more information what exactly made "retrieve tokenGroups" 
> impossible for Jenkins?
>  
> Thanks!
> -Markus
>  
> -- 
> 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.
>  
>  

-- 
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: github plugin on Jenkins does not work for me, Windows Server 2012

2013-02-22 Thread Sami Tikka
Clone the job. Remove the git SCM configuration and build steps. Instead enter 
a single build step which runs the command: set (I believe that prints 
environment vars on windows). Then study the difference in the environment of 
Jenkins job and your own session where things work.

-- Sami

Gong  kirjoitti 22.2.2013 kello 2.01:

> here is the error message. Very confusion to me. 
> a. The Jenkins slave is run from Java Web Starter, not a Windows Service. 
> b. If I login the slave, the git command always work. 
> c. If I start the slave from server, always fail. Here is the error message. 
> 
> Any tips on how to debug/trouble shooting this is very appreciated! This is 
> driving people crazy... 
> 
> 
> 
> Started by user Albert Cheng
> Building remotely on java-ci-2k12 in workspace 
> c:\jenkins\workspace\azure-sdk-for-java dev win2k12
> Checkout:azure-sdk-for-java dev win2k12 / 
> c:\jenkins\workspace\azure-sdk-for-java dev win2k12 - 
> hudson.remoting.Channel@44c7b1:java-ci-2k12
> Using strategy: Default
> Fetching changes from 1 remote Git repository
> Fetching upstream changes from origin
> ERROR: Problem fetching from origin / origin - could be unavailable. 
> Continuing anyway
> hudson.plugins.git.GitException: Command "C:\Program Files 
> (x86)\Git\bin\git.exe fetch -t origin +refs/heads/*:refs/remotes/origin/*" 
> returned status code 128:
> stdout: 
> stderr: Permission denied (publickey).
> fatal: Could not read from remote repository.
> 
> Please make sure you have the correct access rights
> and the repository exists.
> 
>   at 
> org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommandIn(CliGitAPIImpl.java:772)
>   at 
> org.jenkinsci.plugins.gitclient.CliGitAPIImpl.launchCommand(CliGitAPIImpl.java:738)
>   at 
> org.jenkinsci.plugins.gitclient.CliGitAPIImpl.fetch(CliGitAPIImpl.java:160)
>   at hudson.plugins.git.GitSCM.fetchFrom(GitSCM.java:797)
>   at hudson.plugins.git.GitSCM.access$000(GitSCM.java:57)
>   at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:976)
>   at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:941)
>   at hudson.FilePath$FileCallableWrapper.call(FilePath.java:2246)
>   at hudson.remoting.UserRequest.perform(UserRequest.java:118)
>   at hudson.remoting.UserRequest.perform(UserRequest.java:48)
>   at hudson.remoting.Request$2.run(Request.java:326)
>   at 
> hudson.remoting.InterceptingExecutorService$1.call(InterceptingExecutorService.java:72)
>   at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)
>   at java.util.concurrent.FutureTask.run(Unknown Source)
> -- 
> 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.
>  
>  

-- 
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: how to trigger one job if two other succeeds?

2013-02-22 Thread Sami Tikka
I believe the join plugin might be what you want. There might be other 
possibilities but then you will need to tell more about what you are trying to 
do.

-- Sami

Kenneth Nielsen  kirjoitti 22.2.2013 kello 8.50:

> Hi all,
> 
> I have a myriads of small jobs in Jenkins, to get fast feedback for my 
> projects.
> And I have two big ones, one that build a server, and one that does the 
> client.
> 
> I want my installer build to be triggered if both are succeeding - how do I 
> do that?
> 
> some job triggering logic like Job1 && Job2 would be nice.
> 
> Kenneth
> -- 
> 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.
>  
>  

-- 
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: Jobs starting on slaves with no disk space

2013-02-22 Thread Sami Tikka
Install post-build-task plugin and use that to clean the workspace at the end 
of the build.

-- Sami

Pawel  kirjoitti 18.2.2013 kello 13.01:

> Hi,
> 
> I have a problem with jobs being started on a slaves that are low on disk
> space. I know there is a setting to turn the slaves offline automatically
> when disk space falls behind a certain threshold, but it isn't reliable
> enough. I think the problem may be with how often the check is performed (as
> it can take up to an hour to turn the slave back online automatically after
> freeing up enough disk space). The problem in my situation is when I have
> big load on my slaves (many jobs and long queue). I have a job running on a
> slave X which makes it get low on disk space. After the job finishes the
> slaves doesn't get turned off automatically though - new jobs get assigned
> to this node and are started, but fail with "no space left on device" error
> message just a while later. Jenkins assigns all fitting jobs from the queue
> this way, resulting in multiple failures, before node gets turned offline.
> Is there any way to prevent this behavior?
> 
> 
> 
> --
> View this message in context: 
> http://jenkins.361315.n4.nabble.com/Jobs-starting-on-slaves-with-no-disk-space-tp4656054.html
> Sent from the Jenkins users mailing list archive at Nabble.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.
> 
> 

-- 
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: Where to place test dependent files

2013-02-19 Thread Sami Tikka
This question isn't really about Jenkins and there is no correct answer. It's 
like you asked which editor should you use, Emacs or Vi. Wars have been fought 
for lesser things.

There is a school which thinks the source/version control system should contain 
only the source code i.e. the files containing some programming language.

Then there is another school which thinks you should version control your code, 
configuration files, documentation, tests, tools, even your compiler and 
libraries too.

I guess most people are somewhere in between. I myself once worked in a team 
which had everything, including the compiler in the version control and I was 
very happy with it because a) I knew I could build just about everywhere 
without having to spend a week setting up the environment and 2) I knew exactly 
what went into the build.

So if you ask me, I'd say check in your jslint4java into version control. But 
I'm sure someone else will tell you something different.

-- Sami

Jonas Geiregat  kirjoitti 19.2.2013 kello 0.15:

> Hello,
>   
>   
>   
> I'm using Jenkins as a CI server for a python web based project.  
>   
> I'm using the Violations plugin and jslint to get some
>   
> information out of my javascript files.   
>   
> For this I use, jslin4java, which I use as  a Java jar.   
>   
>   
>   
> As I'm new to jenkins and see other such cases arise I should 
>   
> find a good solution to handle such dependent files.  
>   
>   
>   
> My issue is, where to put those files that my tests require but,  
>   
> should not be part of the projects source code ?  
>   
> I've considered putting them under VCS control, just like I do
>   
> with my project configuration files.
> 
> Jonas.
> 
> -- 
> 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.
>  
>  

-- 
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: Unable to add new node (Windows slave) after upgrade to 1.500

2013-02-19 Thread Sami Tikka
It might be related to 
https://wiki.jenkins-ci.org/display/SECURITY/Jenkins+Security+Advisory+2013-01-04

People have been unable to start JNLP slaves after upgrading their Jenkins. 
I've understood it is still possible to do it. You'd have to use a browser 
authenticate and to download the slave-agent.jnlp from the JNLP slave's own 
page ($JENKINS_URL/computer/SLAVENAME).

Then you would start the slave agent from the command line and provide it with 
a file:// url to the locally saved slave-agent.jnlp file.

I haven't tested this personally, I was only told by a colleque who has to care 
about a couple of windows slaves he had to do this.

-- Sami

Manjunath D G  kirjoitti 19.2.2013 kello 10.54:

> Hi All,
> I'm Able to connect Jenkins Windows Slave by using Launch Method as : "Launch 
> slave agent via Java web Start".
> 
> But not working with when i'm trying to use "Let Jenkins control this windows 
> slave as windows service".Provided with right "Administrator user 
> name","Password" and  "Host Name".
> 
> I don't see any problem with Jenkins slave which were configured before 
> migration.They are still working even after migration.Only problem is with 
> adding new windows slave.
> 
> Can some one help me on this
> Regards,
> Manju
> 
> On Thursday, February 14, 2013 5:03:19 PM UTC+5:30, Manjunath D G wrote:
> Hi,
> After my version upgrade from 1.427 to 1.500,I'm unable to add new 
> node.Getting
>  
> Connecting to 172.24.136.55
> Checking if Java exists
> java -version returned 1.7.0.
> Copying jenkins-slave.xml
> Copying slave.jar
> Starting the service
> 
>  
> And nothings happens.Do i need to install any new/ugrade specific plugins.
>  
> Can some one please do let me know what and all i should post upgrade ofr 
> Jenkins version from 1.427 to 1.501.
>  
> Thanks And Regards,
> Manju
> 
> -- 
> 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.
>  
>  

-- 
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: Locked pack files on windows slave

2013-02-19 Thread Sami Tikka
I have found the git plugin keeps some sort of state about the built branches 
in the workspace.

If we configure the workspace to be deleted in the beginning or end of the 
build, there's no predicting which branch Jenkins is going to build next. (Of 
course, we could specify the branch in the job configuration but there are some 
jobs for which we really like it when Jenkins can build and test whatever 
branch someone should push.)

So I have used a workaround: Check the "Clean after checkout" box in git SCM 
Advanced settings. I think it works as well as cleaning the workspace. It might 
actually make thing slightly faster because Jenkins does not have to clone the 
workspace from scratch. If you have a good-sized git repo, even the cloning 
might take a couple of minutes.

-- Sami

William Soula  kirjoitti 19.2.2013 kello 15.52:

> I am trying to build a git project on a windows slave using Jenkins 
> 1.501 with git plugin 1.1.17.  I like to wipe the workspace before 
> checking out so I have that option checked.  When I run the build 
> sometimes it is able to delete the workspace but a lot of the time it 
> can't delete the workspace due to a pack file being locked.  I checked 
> out what was locking the file and it is javaw.exe.  If I restart the 
> slave then I am able to build once and then another pack file is locked 
> by the slave process.
> 
> I have tried googling for a solution and apparently there is none 
> besides not using windows, which is not news to me, git is not a windows 
> tool, never supposed to be never will be.
> 
> So my question is if there is some way to restart the slave within 
> another job.  My idea is to have something like a the log analyzer 
> plugin detect the job failed due to the pack problem and kicks off 
> another job that kills the slave and restarts it and kicks off the first 
> job again.
> 
> Will
> 
> -- 
> 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.
> 
> 

-- 
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: SCM polling after build failure question...

2013-02-19 Thread Sami Tikka
The Jenkins SVN plugin has some dependency on time. To achieve best results you 
should have both Jenkins and SVN server clocks synchronized using NTP or 
similar.

-- Sami

Jeff  kirjoitti 19.2.2013 kello 18.44:

> We are using SVN (SVNBridge to TFS) for most of our projects.  It doesn't 
> seem to happen on all of our projects, just sometimes and it seems to be 
> related to type of build failure (compile vs. test vs. Sonar failure).  
> 
> 
> On Tue, Feb 19, 2013 at 9:39 AM, Michael Clarke  
> wrote:
> Which SCM are you using? Polling will continue regardless of build status, 
> but it's up to each SCM plugin to decide if it sees changes.
> 
> Thanks
> Michael
> 
> On 19 Feb 2013, at 16:28, Jeff  wrote:
> 
>> We had a check-in for a project that caused a compile error last night but 
>> it didn't get fixed until this morning.  
>> 
>> However, Jenkins polling (every 4 minutes) detected an SCM change and 
>> attempted to rebuild.  This repeated every 4 minutes, even though the SCM 
>> revision was the same for every build with the message "No changes."
>> 
>> Jenkins shouldn't do this should it?  If not, what do I look at?
>> 
>> -- 
>> Jeff Vincent
>> predato...@gmail.com
>> See my LinkedIn profile at:
>> http://www.linkedin.com/in/rjeffreyvincent
>> I ♥ DropBox !! 
>> 
>> -- 
>> 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.
>>  
>>  
> 
> -- 
> 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.
>  
>  
> 
> 
> 
> -- 
> Jeff Vincent
> predato...@gmail.com
> See my LinkedIn profile at:
> http://www.linkedin.com/in/rjeffreyvincent
> I ♥ DropBox !! 
> 
> -- 
> 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.
>  
>  

-- 
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: git on jenkins

2013-02-19 Thread Sami Tikka
I suggest you change your job configuration like this:

1) Remove the all the SCM configuration.

2) As first build step, add a shell script step which executes:

env
ssh -v 10.100.100.96 hostname

Then trigger the job to run. Then click open the build and the console. Check 
the output.

Then run the same commands from the command line where you are able to log in. 
Compare results with the output from Jenkins.

-- Sami

Kamal Ahmed  kirjoitti 19.2.2013 kello 19.25:

> Username = kahmed
> which is the same user which can do a git successfully on a command line.
> 
> 
> From: Johannes Wienke 
> To: Kamal Ahmed ; jenkinsci-users@googlegroups.com 
> Sent: Tuesday, February 19, 2013 12:12 PM
> Subject: Re: git on jenkins
> 
> On 19.02.2013 17:28 schrieb Kamal Ahmed:
> > 
> > Johannes,
> > 
> > sorry for the private message, just fat fingered when replying.
> > yes, i am using 
> > Launch slave on Unix machines using SSH" as start method
> > 
> > not sure what is the file to be configured
> > 
> > My network is 
> > 
> > [Jenkins Master ] ---> [ Slave ] ---> [10.100.100.96/cybage02] , cybage02, 
> > is where the git repo is setup.
> > 
> 
> That wasn't what I meant. If you look at the configuration of the slave
> in the jenkins web interface, what is the value of the username field,
> if you open open up the extended settings for the SSH connection?
> 
> Cheers,
> Johannes
> 
> 
> 
> 
> 
> -- 
> 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.
>  
>  

-- 
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: Cannot load Maven 3 on slave

2013-02-11 Thread Sami Tikka
No, but you can configure Jenkins to automatically install then when needed

-- Sami

Markus KARG  kirjoitti 9.2.2013 kello 20.52:

> C:\.jenkins\maven3-interceptor.jar 2988
> Error: Main class org.jvnet.hudson.maven3.agent.Maven3Main could not get 
> found or loaded
> ERROR: Failed to launch Maven. Exit code = 1
> Strange... I thought Jenkins is forwarding JDK and Maven automatically to any 
> slave...?
> -- 
> 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.
>  
>  

-- 
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: Jenkins 1.500 is totally running crazy, build totally weird chains...

2013-02-09 Thread Sami Tikka
Sorry, but ... Have you tried turning it off and on again? :)

And check the stdout and stderr of Jenkins. Is it printing exceptions and/or 
stacktraces? If so, put them into pastebin/gist and tell us. Also it might be 
helpful to see your config.xml files (and remember to remove any sensitive 
information from those before publishing).

Also, give us information just like you would if you were talking to an IT 
support person:

- What is the operating system on which you are running Jenkins?

- How did you install Jenkins? Used one of the platform-specific installers or 
rolled your own?

- Running inside a servlet container?

- Plugins and their versions?

- What did you do recently? Did you upgrade Jenkins? Or upgrade one or more 
plugins? Or upgrade something in the operating system?

- Pastebin/gist where Jenkins stdout+stderr can be found.

-- Sami

Markus KARG  kirjoitti 9.2.2013 kello 20.29:

> One more "nice" thing detected now... Clicked on "build now", build finished 
> successfully, then clicked on the build number to see the result, got "404 
> NOT FOUND"!
> 
> Am Samstag, 9. Februar 2013 19:28:21 UTC+1 schrieb Markus KARG:
> Til today my Jenkins 1.500 worked well.
> Then I started setting up a Windows slave, and added a few free style ant 
> projects running on that slave.
> It all was good, but since I copied one of that free style projects, my 
> dashboard is running crazy.
> It misses builds that just finished a minute ago.
> It shows builds starting without any reason.
> The total horror it showed one minute ago: I clicked on the "start build" 
> button on project X and INSTEAD it started project Y. Both have different 
> types and are totally independend. But when the build was gone, all builds 
> were gone.
> And so on. Just like a total crazy Jenkins that didn't take his pills in the 
> morning.
>  
> Please help, I don't know how to bring him back to reason!
> 
> -- 
> 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.
>  
>  

-- 
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: Detect command failure?

2013-02-09 Thread Sami Tikka
If you do not need the cross-platform properties of ant build step, I would 
recommend using a shell build step. It is much more flexible and is well suited 
to running processes and checking their exit codes, as well as capturing and 
filtering their output in various ways.

-- Sami

Adam Tong  kirjoitti 9.2.2013 kello 19.37:

> Sorry for the error in the last message, even if the value is true it
> does not detect phpunit crash.
> 
> But you answer made me thing about the possibility to personalize my
> ant file so that it can detect that. So my question would be more ant
> related than jenkins itself.
> 
> Thanks a lot
> 
> On Fri, Feb 8, 2013 at 5:45 PM, Sami Tikka  wrote:
>> I'm guessing you are using ant to execute phpunit.
>> 
>> Maybe you could tell ant to fail on error. Currently you have told ant to 
>> ignore the phpunit exit code.
>> 
>> -- Sami
>> 
>> Adam Tong  kirjoitti 9.2.2013 kello 0.17:
>> 
>>> Hi,
>>> 
>>> Here is the section of build.xml that configures the way phpunit is
>>> run by jenkins:
>>> 
>>> ---
>>> >>description="Run unit tests using PHPUnit and generates
>>> junit.xml and clover.xml">
>>>   
>>>   
>>>   
>>>   
>>> 
>>> --
>>> 
>>> It works perfectly, I can see the failures if any and everything.One
>>> day, we had a problem with phpunit that was blocking at some level,
>>> and I wondered if I can catch that at jenkins level.
>>> 
>>> As you see in the description of the configuration, phpunit generates
>>> the files junit.xml and clover.xml.
>>> 
>>> When phpunit crashes I could make a test if one of those files was
>>> correctly generated, but I do not know where to insert that test.
>>> 
>>> 
>>> Thank you
>>> 
>>> On Wed, Feb 6, 2013 at 4:12 PM, Sami Tikka  wrote:
>>>> We need more details to help you.
>>>> 
>>>> What type of job have you created?
>>>> 
>>>> How exactly are you executing phpunit? What is the build step you use? 
>>>> Shell, CMD, something else?
>>>> 
>>>> Can you show us the exact command or configuration?
>>>> 
>>>> More information is better than less.
>>>> 
>>>> -- Sami
>>>> 
>>>> Adam Tong  kirjoitti 5.2.2013 kello 21.13:
>>>> 
>>>>> Hi,
>>>>> 
>>>>> Where should I do this check exactly?
>>>>> 
>>>>> Is there a way to do that in build.xml?
>>>>> 
>>>>> Thank you
>>>>> 
>>>>> On Tue, Feb 5, 2013 at 12:03 PM, Mark Waite  wrote:
>>>>>> If your call to phpunit is expected to create a file, you could check 
>>>>>> that
>>>>>> file is created and then use "exit 1" to cause the build script to exit 
>>>>>> with
>>>>>> the failure.
>>>>>> 
>>>>>> Mark Waite
>>>>>> 
>>>>>> 
>>>>>> 
>>>>>> From: Adam Tong 
>>>>>> To: jenkinsci-users@googlegroups.com
>>>>>> Sent: Tuesday, February 5, 2013 9:17 AM
>>>>>> Subject: Detect command failure?
>>>>>> 
>>>>>> Hi,
>>>>>> 
>>>>>> I am running jenkins on Linux.
>>>>>> 
>>>>>> Yesterday, because of a memory issue, phpunit was not able to run the
>>>>>> hole tests suite. However the build was still successful.
>>>>>> 
>>>>>> I understand that if phpunit fails it does not return any errors or
>>>>>> failures.
>>>>>> 
>>>>>> Now I am wondering if there is a way to make Jenkins detect this kind of
>>>>>> issues.
>>>>>> 
>>>>>> Thank you
>>>>>> 
>>>>>> --
>>>>>> 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: How to publish artifact to a SMB / CIFS share?

2013-02-09 Thread Sami Tikka
I myself would use (and have used) smbclient to copy artifacts after the build 
has produced them. It doesn't have to a post-build step.

But Mac OS no longer has smbclient, so I hope you're using Linux. I suppose 
Windows can just do "net use..."

-- Sami

Markus KARG  kirjoitti 9.2.2013 kello 19.56:

> It is not clearly the OS's job. Any application software can connect, use, 
> and disconnect from a SMB / CIFS share, just as any user can have different 
> SMB / CIFS connections not shared with other users of the same client. I did 
> not talk about linking it into the local file system or providing it as a 
> drive letter. So Jenkins could simply connect, push the file, disconnect, 
> just as it does when installing itself on a Windows slave.
>  
> Anyways, the main problem is unsolved: How to tell Jenkins to copy an 
> artifact as a post-build step?
> 
> Am Samstag, 9. Februar 2013 16:29:03 UTC+1 schrieb Octavian Covalschi:
> How do you mount/connect that share? I mean, it's OS' job to mount a network 
> share with or w/o user/password and Jenkins would just copy your file to that 
> share.  
> 
> 
> On Sat, Feb 9, 2013 at 9:09 AM, Markus KARG  wrote:
> I need to publish an artifact to a password-protected SMB / CIFS share. How 
> can I do this?
> I noticed that there was a copy plugin, which seems to be obsolete.
> I also noticed that there is a ArtifactDeployer plugin, which seems to be so 
> fresh that it is not contained in the Jenkins Update system.
> What to do?
> 
> -- 
> 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-use...@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.
>  
>  

-- 
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: Building on 8 Operating Systems with 2 Systems

2013-02-08 Thread Sami Tikka
My Jenkins runs in VMware virtual machine and slaves in libvirt/KVM vms. No 
problems so far.

-- Sami

Raghavendra Achar  kirjoitti 8.2.2013 kello 7.37:

> Thanks a lot Andrew for the quick reply, Will Jenkins work on the virtual 
> configurations??Has it been tested by many??
> Can i make First system as Jenkins master and other 7 OS configurations as 
> virtual Jenkins Slaves in other system.
> Will this be the best approach??Please suggest
> 
> regards
> Raghavendra
> 
> On Friday, February 8, 2013 10:31:28 AM UTC+5:30, Andrew Melo wrote:
>> 
>> I would just roll 8 virtual machines
>> 
>> 
>> Andrew Melo
>> Sent from my secret fortress.
>> 
>> On Feb 7, 2013, at 22:57, Raghavendra Achar  wrote:
>> 
>>> Hello, 
>>>   I need to build my visual studio applications on 8 OS 
>>> configurations using Jenkins.But i have a constraint on the System 
>>> resource. 
>>> I have only 2 systems to use. Is this possible easily?What is the best 
>>> approach to do this.
>>> PC1 (32 bit): 
>>> - partition0: Windows XP – 32bit – English 
>>> - partition1: Windows XP – 32bit – Korean 
>>> - partition2: Windows7 – 32bit – English 
>>> - partition3: Windows7 – 32bit – Korean 
>>> PC2 (64 bit): 
>>> - partition0: Windows XP – 64bit – English 
>>> - partition1: Windows XP – 64bit – Korean 
>>> - partition2: Windows7 – 64bit – English 
>>> - partition3: Windows7 – 64bit – Korean 
>>> 
>>> Regards 
>>> raghavendra
>>> -- 
>>> 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-use...@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.
>  
>  

-- 
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: java.lang.OutOfMemoryError: PermGen space after upgrade to 1.500

2013-02-08 Thread Sami Tikka

Kamal Ahmed  kirjoitti 8.2.2013 kello 20.40:

> i increased the PermGen, like you suggested and for the last few minutes its 
> working ok, i even have a build going.
> Crossing Fingers.
> It would be nice to have RELEASE NOTES with every new build,

http://jenkins-ci.org/changelog, but it might not always be obvious the Jenkins 
memory requirements have changed. 

I guess the developers themselves might not always keep good track of that. 
Java is notorious for being a bit liberal with your RAM.

> or at least have a place where we can share our experiences about a 
> particular release.
> 

Click on the "Community ratings" on the changelog page. 

Another place for sharing experiences is this mailing list.

- Sami

> Thanks,
> -Kamal.
> 
> 
> From: Kamal Ahmed 
> To: "jenkinsci-users@googlegroups.com"  
> Sent: Friday, February 8, 2013 10:37 AM
> Subject: Re: java.lang.OutOfMemoryError: PermGen space after upgrade to 1.500
> 
> resolved for now, by downgrading jenkins to 1.494
> 
> But all the slaves are now off line, how do i bring the slaves back on ?
> Thanks,
> -Kamal.
> 
> 
> From: Kamal Ahmed 
> To: "jenkinsci-users@googlegroups.com"  
> Sent: Friday, February 8, 2013 8:53 AM
> Subject: Re: java.lang.OutOfMemoryError: PermGen space after upgrade to 1.500
> 
> This was working with the same amount of PermGen Space yesterday BEFORE the 
> upgrade.
> 
> jenkins JVM options:
> 
> 
> /usr/bin/daemon --name=jenkins --inherit --env=JENKINS_HOME=/var/lib/jenkins 
> --output=/var/log/jenkins/jenkins.log --pidfile=/var/run/jenkins/jenkins.pid 
> -- /usr/bin/java -Xmx2048m -jar /usr/share/jenkins/jenkins.war 
> --webroot=/var/cache/jenkins/war --httpPort=9000 --ajp13Port=-1
> 
> /usr/bin/java -Xmx2048m -jar /usr/share/jenkins/jenkins.war 
> --webroot=/var/cache/jenkins/war --httpPort=9000 --ajp13Port=-1
> 
> Thiis is what i see when i do ps -ef | grep java
> 
> 
> Java version:
> 
> java version "1.6.0_35"
> Java(TM) SE Runtime Environment (build 1.6.0_35-b10)
> Java HotSpot(TM) 64-Bit Server VM (build 20.10-b01, mixed mode)
> 
> 
> after i let the Jenkins stay initially at the main , i get the following 
> error in by browser ( this is in addition to the CPU being pegged 100% ) 
> 
> Content Encoding Error
> 
>   The page you are trying to view cannot be shown because it uses an 
> invalid or unsupported form of compression.
>   Please contact the website owners to inform them of this problem.
> 
> Some build's ago in 2009, i saw someone complain about the exact coding 
> error, and it was a plugin issue that Kohsuke fixed in the release plugin.
> 
> Thanks,
> -Kamal.
> From: "Mandeville, Rob" 
> To: "jenkinsci-users@googlegroups.com"  
> Sent: Friday, February 8, 2013 8:02 AM
> Subject: RE: java.lang.OutOfMemoryError: PermGen space after upgrade to 1.500
> 
> If you’re running out of PermGen space, your problem is with your JVM.  Your 
> CPU may be getting pegged because your JVM is desperately garbage collecting 
> to get every last byte of storage left, but I could be wrong.  Basically, 
> you’re going to have to tell the JVM running your Jenkins instance to give 
> you more PermGen space.
>  
> Find out (if you don’t already know) which application server you’re running 
> Jenkins with (if you’re launching it like “java –jar Jenkins.war”, you’re 
> using the onboard WinStone app server), and which JVM you’re running that 
> server in.  You’ll have to determine how much PermGen space you’re allocating 
> (likely the default that your JVM gives) and how to tell the JVM running your 
> App server to give it more.  Again, if you’re launching Jenkins as a plain 
> Java app and using WinStone, you can add the PermGen space arguments right to 
> the Java command line.
>  
> --Rob
>  
>  
> From: jenkinsci-users@googlegroups.com 
> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of Kamal Ahmed
> Sent: Friday, February 08, 2013 7:47 AM
> To: jenkinsci-users@googlegroups.com
> Subject: java.lang.OutOfMemoryError: PermGen space after upgrade to 1.500
>  
> Hi,
> After i upgraded Jenkins to 1.500 on ubuntu 12.04 host. I am getting 
> java.lang.OutOfMemoryError: PermGen space
> After i click any link on Jenkins page, the CPU gets pegged 100%
>  
>  
> This also happens when i let the page stay there and not click on anything.
>  
> Anyone found a resolution for this?
> Thanks,
> -Kamal.
> -- 
> 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.
>  
>  
> The information in this message is for the intended recipient(s) only and may 
> be the proprietary and/or confidential property of Litle & Co., LLC, and thus 
> protected from disclosure. If you are not the intended recipient(s), or an 
> employee or agent responsible for delivering this mes

Re: Detect command failure?

2013-02-08 Thread Sami Tikka
I'm guessing you are using ant to execute phpunit. 

Maybe you could tell ant to fail on error. Currently you have told ant to 
ignore the phpunit exit code.

-- Sami

Adam Tong  kirjoitti 9.2.2013 kello 0.17:

> Hi,
> 
> Here is the section of build.xml that configures the way phpunit is
> run by jenkins:
> 
> ---
>  description="Run unit tests using PHPUnit and generates
> junit.xml and clover.xml">
>
>
>
>
> 
> --
> 
> It works perfectly, I can see the failures if any and everything.One
> day, we had a problem with phpunit that was blocking at some level,
> and I wondered if I can catch that at jenkins level.
> 
> As you see in the description of the configuration, phpunit generates
> the files junit.xml and clover.xml.
> 
> When phpunit crashes I could make a test if one of those files was
> correctly generated, but I do not know where to insert that test.
> 
> 
> Thank you
> 
> On Wed, Feb 6, 2013 at 4:12 PM, Sami Tikka  wrote:
>> We need more details to help you.
>> 
>> What type of job have you created?
>> 
>> How exactly are you executing phpunit? What is the build step you use? 
>> Shell, CMD, something else?
>> 
>> Can you show us the exact command or configuration?
>> 
>> More information is better than less.
>> 
>> -- Sami
>> 
>> Adam Tong  kirjoitti 5.2.2013 kello 21.13:
>> 
>>> Hi,
>>> 
>>> Where should I do this check exactly?
>>> 
>>> Is there a way to do that in build.xml?
>>> 
>>> Thank you
>>> 
>>> On Tue, Feb 5, 2013 at 12:03 PM, Mark Waite  wrote:
>>>> If your call to phpunit is expected to create a file, you could check that
>>>> file is created and then use "exit 1" to cause the build script to exit 
>>>> with
>>>> the failure.
>>>> 
>>>> Mark Waite
>>>> 
>>>> 
>>>> 
>>>> From: Adam Tong 
>>>> To: jenkinsci-users@googlegroups.com
>>>> Sent: Tuesday, February 5, 2013 9:17 AM
>>>> Subject: Detect command failure?
>>>> 
>>>> Hi,
>>>> 
>>>> I am running jenkins on Linux.
>>>> 
>>>> Yesterday, because of a memory issue, phpunit was not able to run the
>>>> hole tests suite. However the build was still successful.
>>>> 
>>>> I understand that if phpunit fails it does not return any errors or
>>>> failures.
>>>> 
>>>> Now I am wondering if there is a way to make Jenkins detect this kind of
>>>> issues.
>>>> 
>>>> Thank you
>>>> 
>>>> --
>>>> 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.
>>>> 
>>>> 
>>>> 
>>>> 
>>>> --
>>>> 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.
>>> 
>>> --
>>> 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.
>> 
>> --
>> 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.
> 
> -- 
> 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.
> 
> 

-- 
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: Building jenkins: XStream2Test$Foo2 cannot be cast to XStreamTest$Foo

2013-02-07 Thread Sami Tikka
Did you try with jdk 1.7?

-- Sami

Viktor Tarasov  kirjoitti 7.2.2013 kello 11.26:

> Hello,
> 
> When trying to build jenkins from the current GH master branch 
> I'm getting following error:
> 
> $ mvn -Plight-test install
> ..
> Running hudson.util.XStreamTest
> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.09 sec <<< 
> FAILURE!
> testConcurrentHashMapSerialization(hudson.util.XStreamTest)  Time elapsed: 
> 0.078 sec  <<< ERROR!
> java.lang.ClassCastException: hudson.util.XStream2Test$Foo2 cannot be cast to 
> hudson.util.XStreamTest$Foo
>   at 
> hudson.util.XStreamTest.testConcurrentHashMapSerialization(XStreamTest.java:69)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
> 
> [INFO] Jenkins core .. FAILURE [1:52.501s]
> 
> $ mvn -version
> Apache Maven 3.0.4 (r1232337; 2012-01-17 09:44:56+0100)
> Maven home: /opt/apache-maven-3.0.4
> Java version: 1.6.0_33, vendor: Sun Microsystems Inc.
> Java home: /opt/jdk1.6.0_33/jre
> Default locale: fr_FR, platform encoding: UTF-8
> OS name: "linux", version: "2.6.38-13-generic-pae", arch: "i386", family: 
> "unix"
> 
> Any ideas, please?
> Viktor.
> -- 
> 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.
>  
>  

-- 
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: Error while building maven2 project.

2013-02-07 Thread Sami Tikka
Jenkins is running as different user and that user's cache dir does not have 
the same files as yours has, maybe.

-- Sami

Роман Бесолов  kirjoitti 7.2.2013 kello 14.24:

> I'm trying to build javamail1.4.5 
> (http://kenai.com/projects/javamail/downloads). I can build it manually (by 
> typing mvn install -DskipTests=true in terminal), but jenkins can't build it. 
> Jenkins is trying to download 
> http://maven.glassfish.org/content/groups/glassfish-group//org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.pom,
>  which doen't exists. I have no idea why it tries to download it. 
> 
>> [INFO] [enforcer:enforce {execution: enforce-maven}]
>> [INFO] [enforcer:enforce {execution: enforce-version}]
>> Downloading: 
>> http://maven.glassfish.org/content/groups/glassfish-group//org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.pom
>> 185b downloaded  (maven-plugin-api-2.0.4.pom)
>> [WARNING] *** CHECKSUM FAILED - Checksum failed on download: local = 
>> '6c9fd3d150b8a5f0ca676f49b8ed603793cabebb'; remote = '
>> 301' - RETRYING
>> Downloading: 
>> http://maven.glassfish.org/content/groups/glassfish-group//org/apache/maven/maven-plugin-api/2.0.4/maven-plugin-api-2.0.4.pom
>> 185b downloaded  (maven-plugin-api-2.0.4.pom)
>> [WARNING] *** CHECKSUM FAILED - Checksum failed on download: local = 
>> '6c9fd3d150b8a5f0ca676f49b8ed603793cabebb'; remote = '
>> 301' - IGNORING
>> [WARNING] POM for 'org.apache.maven:maven-plugin-api:pom:2.0.4:runtime' is 
>> invalid.
> 
> 
> Full log you can see in attachment. Thanks for help!
> 
> -- 
> 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.
>  
>  
> 

-- 
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: expect on Windows - quick question

2013-02-07 Thread Sami Tikka
You would get better help from Cygwin mailing list. 

I believe the problem is that after you start the Cygwin bash, you must stop 
using windows-style pathnames. I.e. you must use /cygdrive/c/install to run the 
installer.

-- Sami

Z W  kirjoitti 8.2.2013 kello 1.46:

> Hi All
> 
> Has anyone tried running expect script with Jenkins as a Windows shell ?
> We have a windows software to install and like to install it with Jenkins.
> We selected Windows shell build step but it fails.
> 
> [install] $ cmd /c call
> C:\Users\me\AppData\Local\Temp\hudson5137610208232380553.bat
> 
> c:\install>c:\cygwin\bin\bash.exe -c /cygdrive/c/scripts/test_install.exp
> spawn C:\install.exe -i console
> couldn't execute "C:\install.exe -i console": no such file or directory
>while executing
> "spawn "C:\\install.exe -i console""
>(file "/cygdrive/c/scripts/test_install.exp" line 5)
> 
> What are we doing wrong ?
> 
> thanks
> 
> -- 
> 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.
> 
> 

-- 
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: shell redirection

2013-02-07 Thread Sami Tikka
Since you chose not to share the console log, I'm only speculating, but I think 
you need to consider the possibility it is the python command that fails. Maybe 
it does not really fail, but anyway exits with nonzero code to indicate a 
problem in the pep8 analysis?

-- Sami

jonas  kirjoitti 7.2.2013 kello 23.54:

> Hello,
> 
> I'm using Jenkins as my CI server for some python projects.
> 
> I run all my tests,coverage reports etc .. using the shell script buildstep.
> One line of the script redirect some output: python -m pep8 *.py > 
> reports/pep8.report
> 
> But for some reason this fails, in the console log, the line is outputed as: 
> "python -m pep8 main.py tests.py".
> 
> I think it has something to do with the redirect, although the file 
> reports/pep8.report is created and contains the expected data.
> 
> If I move the line up or down it fails again, exactly at that line.
> 
> Any advice is appreciated.
> 
> Jonas.
> -- 
> 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.
>  
>  

-- 
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: jenkins clustering

2013-02-06 Thread Sami Tikka

Matteo Centonza  kirjoitti 5.2.2013 kello 10.45:

> But in case of master failure, even if running on slaves machines perfectly
> fit, jobs would be abrouptly stopped just because master <-> slave channel
> is interrupted.

Yes, if the master or slave breaks, you will always get a failed build. There 
is no way to prevent that in Jenkins. 

You could install the Naginator plugin to reschedule failed builds immediately. 
And talk to your manager to convince him it is not really an end of the 
world... :)

-- Sami

-- 
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: Beta Build Environment

2013-02-06 Thread Sami Tikka
I have developed instructions on how to set up Jenkins from scratch if our 
Jenkins would catch fire and burn to the ground.

I have also used the instructions to set up a 2nd Jenkins to run a newer 
version of Jenkins before upgrading.

You need the jenkins.war, the plugins, the global config.xml and config.xml 
files for every job. If you want to try your hand at automating, remember that 
the Jenkins cli can be used to upload plugins and job configurations.

-- Sami

"Mandeville, Rob"  kirjoitti 5.2.2013 kello 21.09:

> I work for an agile development group, so we like to test everything, 
> including our build environment.  I have been challenged to figure out how my 
> team can create a second build environment to test enhancements on.  This 
> would also involve creating a beta copy of our Jenkins instance.
>  
> We need to be able to test changes to (in order of importance) job 
> configurations, slave configurations, and (possibly) plugin configurations.  
> Is there any way to do this?  Has anyone ever tried?
>  
> Thanks in advance,
>  
> --Rob Mandeville
> The information in this message is for the intended recipient(s) only and may 
> be the proprietary and/or confidential property of Litle & Co., LLC, and thus 
> protected from disclosure. If you are not the intended recipient(s), or an 
> employee or agent responsible for delivering this message to the intended 
> recipient, you are hereby notified that any use, dissemination, distribution 
> or copying of this communication is prohibited. If you have received this 
> communication in error, please notify Litle & Co. immediately by replying to 
> this message and then promptly deleting it and your reply permanently from 
> your computer.
> 
> -- 
> 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.
>  
>  

-- 
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: Detect command failure?

2013-02-06 Thread Sami Tikka
We need more details to help you.

What type of job have you created?

How exactly are you executing phpunit? What is the build step you use? Shell, 
CMD, something else?

Can you show us the exact command or configuration?

More information is better than less.

-- Sami

Adam Tong  kirjoitti 5.2.2013 kello 21.13:

> Hi,
> 
> Where should I do this check exactly?
> 
> Is there a way to do that in build.xml?
> 
> Thank you
> 
> On Tue, Feb 5, 2013 at 12:03 PM, Mark Waite  wrote:
>> If your call to phpunit is expected to create a file, you could check that
>> file is created and then use "exit 1" to cause the build script to exit with
>> the failure.
>> 
>> Mark Waite
>> 
>> 
>> 
>> From: Adam Tong 
>> To: jenkinsci-users@googlegroups.com
>> Sent: Tuesday, February 5, 2013 9:17 AM
>> Subject: Detect command failure?
>> 
>> Hi,
>> 
>> I am running jenkins on Linux.
>> 
>> Yesterday, because of a memory issue, phpunit was not able to run the
>> hole tests suite. However the build was still successful.
>> 
>> I understand that if phpunit fails it does not return any errors or
>> failures.
>> 
>> Now I am wondering if there is a way to make Jenkins detect this kind of
>> issues.
>> 
>> Thank you
>> 
>> --
>> 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.
>> 
>> 
>> 
>> 
>> --
>> 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.
>> 
>> 
> 
> -- 
> 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.
> 
> 

-- 
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: Server usage pegged at 99%

2013-02-06 Thread Sami Tikka
Are there any errors/exceptions in Jenkins log files or stdout/stderr?

-- Sami

Andrew Melo  kirjoitti 6.2.2013 kello 22.13:

> Hey everyone,
> 
> Sorry for resurrecting that thread, but are there any solutions for
> this problem? It's basically killing our instance often.
> 
> best,
> Andrew
> 
> On Wed, Aug 1, 2012 at 11:47 AM, Andrew Melo  wrote:
>> Oh, wow, I didn't notice, but jenkins has autopopulated a user for
>> everyone that ever committed on the project. There's like 30 people,
>> ~4000 commits, so I could see why that would take a while :)
>> 
>> On Wed, Aug 1, 2012 at 11:42 AM, Andrew Melo  wrote:
>>> On Wed, Aug 1, 2012 at 11:37 AM, Slide  wrote:
 Can you gist your global config.xml and something from one of your
 jobs as well? Please remember to sanitize it.
>>> 
>>> We actually keep it stored in SCM. https://github.com/dmwm/jenkins/
>>> 
>>> And the following is the gist for the job we run each commit (didn't
>>> make it in for some reason...)
>>> 
>>> https://gist.github.com/3228599
>>> 
 
 On Wed, Aug 1, 2012 at 9:34 AM, Andrew Melo  wrote:
> On Wed, Aug 1, 2012 at 11:26 AM, Slide  wrote:
>> No, because its only looking for the email address because it wants to
>> send an email to that user.
> 
> I don't know who's getting emailed. I don't remember setting it up for
> anything, and we actually wrote some scripts that turn jenkins
> success/failures into Github issues, so having jenkins also send
> emails would be redundant.
> 
> I don't supposed there's a global flag to disable email? (I don't see
> one at "manage jenkins")
> 
> -Andrew
>> 
>> On Wed, Aug 1, 2012 at 9:24 AM, Andrew Melo  
>> wrote:
>>> On Wed, Aug 1, 2012 at 11:22 AM, Slide  wrote:
 This is a huge issue with the email-ext plugin as well when it does
 email address resolution. Quite a number of people have complained
 about how long it takes. I have yet to come up with a good solution.
 The perforce plugin has a similar issue.
>>> 
>>> If I just stick a dummy address in every user's profile, will that work?
>>> 
 
 slide
 
 On Wed, Aug 1, 2012 at 9:17 AM, Vojtech Juranek  
 wrote:
> Looks like you it does search for user's email:
> hudson.scm.SubversionMailAddressResolverImpl.findMailAddressFor
> and spends time parsing changelogs:
> hudson.scm.SubversionChangeLogParser.parse
> 
> I guess you have quite large instance, otherwise this operation would 
> be quite
> fast.
> If you have some job, which has set up option to send an email to 
> devs who
> broke the build, if the user hasn't specified an email, Jenkins tries 
> to find it
> e.g. in git or SVN changelogs and search all projects and builds so 
> if you
> have large instance with several dozen thousands of builds if can 
> take pretty
> long time.
> 
> You can fix it by setting up correct email for the user.
> If you have installed git plugin, make sure you have 1.1.16 (I hope 
> it was
> fixed in this version) or higher. Git plugin made this search even if 
> the user
> has set up email correctly
> 
> On Wednesday 01 August 2012 10:56:43 Andrew Melo wrote:
>> On Wed, Aug 1, 2012 at 10:36 AM, Vojtech Juranek 
>> 
> wrote:
>>> On Wednesday 01 August 2012 10:07:15 Andrew Melo wrote:
 On Wed, Aug 1, 2012 at 9:48 AM, Vojtech Juranek 
 
> wrote:
> quick way how to look what the thread consuming CPU is doing is 
> to do
> thread dump (e.g. using jstack $PID) and use top with threads on 
> (H
> option) and then look up, see e.g.
> http://code.nomad-labs.com/2010/11/18/identifying-which-java-thread-is-
> consuming-most-cpu/
 
 I see. I apparently don't have jstack on this machine :/. Does it 
 only
 come with the JDK, or can I find it somewhere on the JRE? Once I 
 find
 the offending thread, should it be pretty obvious what it does?
>>> 
>>> jstack is part of JDK
>>> 
>>> you can see the stack trace via Jenkins UI navigating to
>>> $JENKINS_URL/threadDump but not sure if your (or any) Jenkins 
>>> version
>>> provides thread IDs.
>>> 
>>> 
>>> Once you identify the offending thread, it should be obvious what 
>>> it does
>>> (but it may not be obvious why it does what it does:-)
>> 
>> Okay, I installed the jdk, and I looked some more.
>> 
>> Using top, I see one jenkins thread taking the lionsshare of the 
>> time:
>> 
>>  PID USER  

Re: How does Jenkins checkout sources from svn to the slaves?

2013-02-06 Thread Sami Tikka
What does it mean when you say "SSL is disabled"? How can you disable SSL? You 
have blocked access to SVN server port 443?

-- Sami

Mehdi Hayani Soujaa  kirjoitti 6.2.2013 kello 13.25:

> Hi, 
> 
> Thank you Nicolas for your answer, 
> 
> But, in my case,  wouldn't the sources code retrieval be affected the same as 
> using a simple svn client ? I mean since checkout does not work from the 
> slave because SSL is disabled, this should be the same using svnkit ??
> 
> 
> 
> Regards 
> Mehdi  
> 
> -- 
> 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.
>  
>  

-- 
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: jenkins clustering

2013-02-04 Thread Sami Tikka
Oh you really meant you want your slaves to HA!

Usually people just have so many slaves it doesn't matter if some go down.

-- Sami

Matteo Centonza  kirjoitti 4.2.2013 kello 16.37:

> Hello Sami, Rob,
> 
> thanks for your replies.
> 
> We are currently using redhat cluster to provide failover capabilities to 
> jenkins master.
> 
> Haven't tried Cloudbees Jenkins Enterprise either but from what' i've read, i 
> assume failover
> capabilities are restricted to master failover, so functionally equivalent to 
> what we have already
> achieved.
> 
> I can't find any reference on slave resiliency in the event of a master 
> failure, but i'll be really glad
> to be corrected from someone more knowledgeable than me on the enterprise 
> product :)
> 
> A presto,
> 
> -m
> 
> 
> 2013/2/4 Mandeville, Rob 
>> If you’re willing to pony up some money, you should talk to Cloudbees 
>> regarding their Enterprise version 
>> (http://www.cloudbees.com/jenkins-enterprise-by-cloudbees-overview.cb).  I 
>> haven’t tried it (yet), but it comes with several plugins you can’t get 
>> otherwise, and one of them is a High Availability plugin.  This specifically 
>> allows you to fail over to a second Jenkins master on the fly if the master 
>> dies.
>> 
>>  
>> 
>> --Rob
>> 
>>  
>> 
>> From: jenkinsci-users@googlegroups.com 
>> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of Matteo
>> Sent: Tuesday, January 22, 2013 2:24 PM
>> To: jenkinsci-users@googlegroups.com
>> Subject: jenkins clustering
>> 
>>  
>> 
>> Hello,
>> 
>>  
>> 
>> first i'd like to thank developers for this great project.
>> 
>>  
>> 
>> I'm sorry if already asked but i'm new on this list and searching the web
>> has produced no results.
>> 
>>  
>> 
>> We have a jenkins installation with 1 master and 5 slaves connected through 
>> ssh.
>> 
>>  
>> 
>> We are mostly a java shop and jenkins is central to our infrastructure since 
>> we
>> 
>> build and deploy releases to servers from it.
>> 
>>  
>> 
>> For this reason slave resiliency in the face of master failure is paramount 
>> to us.
>> 
>>  
>> 
>> My question:
>> 
>> Is there a way, in a master/slave configuration, to have slave builds
>> running to completion even in case of master failure (ideally refetching
>> console logs once the master is back up :))?
>> 
>>  
>> 
>> In our current setup, we get a proxy error on master UI and builds are 
>> aborted.
>> 
>>  
>> 
>> Thanks in advance for any hint,
>> 
>>  
>> 
>> -m
>> 
>> The information in this message is for the intended recipient(s) only and 
>> may be the proprietary and/or confidential property of Litle & Co., LLC, and 
>> thus protected from disclosure. If you are not the intended recipient(s), or 
>> an employee or agent responsible for delivering this message to the intended 
>> recipient, you are hereby notified that any use, dissemination, distribution 
>> or copying of this communication is prohibited. If you have received this 
>> communication in error, please notify Litle & Co. immediately by replying to 
>> this message and then promptly deleting it and your reply permanently from 
>> your computer.
>> -- 
>> 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.
> 
> -- 
> 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.
>  
>  

-- 
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: "don't keep this build forever" button does nothing

2013-02-03 Thread Sami Tikka
Jenkins only deletes builds when it runs the job. If you need the disk space 
vacated immediately, you can script it like described here:

http://jenkins.361315.n4.nabble.com/Is-there-a-way-to-make-quot-discard-old-builds-quot-happen-right-now-td3879634.html

-- Sami

Chris Withers  kirjoitti 20.1.2013 kello 0.43:

> Hi All,
> 
> I'd like to delete this build:
> 
> http://jenkins.simplistix.co.uk/job/testfixtures-tox/83/
> 
> ...however clicking the "don't keep this build forever" button does nothing.
> 
> What am I doing wrong?
> 
> Chris
> 
> -- 
> Simplistix - Content Management, Batch Processing & Python Consulting
>   - http://www.simplistix.co.uk

-- 
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: I did not spawn a child process to build my project, why am I getting this: Process leaked file descriptors. See wiki.jenkins-ci.org/display/JENKINS/… for more information ERROR: Failed to clean t

2013-02-03 Thread Sami Tikka
Well, everything is more difficult on Windows.

I do not use Windows but I work in an organization where people have to do 
battle with the same issues you are fighting with.

I think your issues might be caused by the "git" command not being a .exe but a 
.bat. 

-- Sami

hong...@steward.org kirjoitti 21.1.2013 kello 22.29:

>  have never configured a system as hard as this combination, Jenkins (1.499), 
> Git (1.8.0.msysgit.0), and Windows 7 32 bit. I have been stumped for three 
> days, did not make any progress. I have been googling crazily and all the 
> answers found here and there seemed to help me a little, ex: no space for Git 
> home. In Jenkins, for Git installation it is C:\Git\cmd\gitk.cmd, notice, 
> there is no space in the path (I reinstalled Git from Program Files\Git to 
> C:\Git to get rid of the space issue). My repository is a private one, so I 
> need to use an SSH protocol. I am able to do this git command in a command 
> line using my Windows account: git clone g...@github.com:mygitproject.git. I 
> have C:/Users/myaccount/.ssh/known_hosts, id_rsa, and id_rsa.pub. Since my 
> Jenksin is a Windows service, it runs under Local System Account, but the 
> known_hosts was generated when I logged in Windows using my Windows account, 
> so I thought I needed to change the Jenkins running user to my Windows 
> account and I did it. However nothing seems working.
>  
> When I try to build a job from a remote private Github repository, I get this 
> exception:
>  
> Started by user anonymous
> Building in workspace C:\Jenkins\workspace\Test
> Checkout:Test / C:\Jenkins\workspace\Test - hudson.remoting.LocalChannel@6846c
> Using strategy: Default
> Cloning the remote Git repository
> Cloning repository g...@github.com:stewardconnect/CARE.git
> git --version
> Process leaked file descriptors. See 
> http://wiki.jenkins-ci.org/display/JENKINS/Spawning+processes+from+build for 
> more information
> ERROR: Failed to clean the workspace
> java.io.IOException: Unable to delete C:\Jenkins\workspace\Test
> at hudson.Util.deleteFile(Util.java:243)
> at hudson.Util.deleteRecursive(Util.java:293)
> at hudson.FilePath$11.invoke(FilePath.java:983)
> at hudson.FilePath$11.invoke(FilePath.java:981)
> at hudson.FilePath.act(FilePath.java:852)
> at hudson.FilePath.act(FilePath.java:825)
> at hudson.FilePath.deleteRecursive(FilePath.java:981)
> at hudson.plugins.git.GitAPI.clone(GitAPI.java:241)
> at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1044)
> at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:986)
> at hudson.FilePath.act(FilePath.java:852)
> at hudson.FilePath.act(FilePath.java:825)
> at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:986)
> at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1142)
> at hudson.model.AbstractProject.checkout(AbstractProject.java:1325)
> at 
> hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:682)
> at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
> at 
> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:587)
> at hudson.model.Run.execute(Run.java:1543)
> at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
> at hudson.model.ResourceController.execute(ResourceController.java:88)
> at hudson.model.Executor.run(Executor.java:236)
> ERROR: Error cloning remote repo 'origin' : Failed to delete workspace
> hudson.plugins.git.GitException: Failed to delete workspace
> at hudson.plugins.git.GitAPI.clone(GitAPI.java:244)
> at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:1044)
> at hudson.plugins.git.GitSCM$2.invoke(GitSCM.java:986)
> at hudson.FilePath.act(FilePath.java:852)
> at hudson.FilePath.act(FilePath.java:825)
> at hudson.plugins.git.GitSCM.determineRevisionToBuild(GitSCM.java:986)
> at hudson.plugins.git.GitSCM.checkout(GitSCM.java:1142)
> at hudson.model.AbstractProject.checkout(AbstractProject.java:1325)
> at 
> hudson.model.AbstractBuild$AbstractBuildExecution.defaultCheckout(AbstractBuild.java:682)
> at jenkins.scm.SCMCheckoutStrategy.checkout(SCMCheckoutStrategy.java:88)
> at 
> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:587)
> at hudson.model.Run.execute(Run.java:1543)
> at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
> at hudson.model.ResourceController.execute(ResourceController.java:88)
> at hudson.model.Executor.run(Executor.java:236)
> Caused by: java.io.IOException: Unable to delete C:\Jenkins\workspace\Test
> at hudson.Util.deleteFile(Util.java:243)
> at hudson.Util.deleteRecursive(Util.java:293)
> at hudson.FilePath$11.invoke(FilePath.java:983)
> at hudson.FilePath$11.invoke(FilePath.java:981)
> at hudson.FilePath.act(FilePath.java:852)
> at hudson.FilePath.act(FilePath.java:825)
> at hudson.FilePath.deleteRecursive(FilePath.java:981)
> at hudson.plugins.git.GitAPI.clone(GitAPI.java:241)
> ... 14 more
> Trying next repository
> ERROR: Could not clone repository
> FATAL: Could not clone
> hudson.plugins.git.GitEx

Re: jenkins clustering

2013-02-03 Thread Sami Tikka
There is no such way. If this is critical to you, maybe you could check if you 
can turn your builds into "external jobs" like described in 
https://wiki.jenkins-ci.org/display/JENKINS/Monitoring+external+jobs

-- Sami

Matteo  kirjoitti 22.1.2013 kello 21.23:

> Hello,
> 
> first i'd like to thank developers for this great project.
> 
> I'm sorry if already asked but i'm new on this list and searching the web
> has produced no results.
> 
> We have a jenkins installation with 1 master and 5 slaves connected through 
> ssh.
> 
> We are mostly a java shop and jenkins is central to our infrastructure since 
> we
> build and deploy releases to servers from it.
> 
> For this reason slave resiliency in the face of master failure is paramount 
> to us.
> 
> My question:
> Is there a way, in a master/slave configuration, to have slave builds
> running to completion even in case of master failure (ideally refetching
> console logs once the master is back up :))?
> 
> In our current setup, we get a proxy error on master UI and builds are 
> aborted.
> 
> Thanks in advance for any hint,
> 
> -m

-- 
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: Jenkins/Slave connection via TelNet

2013-02-03 Thread Sami Tikka
Which Jenkins version are you using? Recent Jenkins versions allowed 
unauthenticated access to the slave-agent.jnlp URL, which makes starting JNLP 
slaves a bit more difficult.

I'm pretty sure the slave startup does not use -auth option to provide a 
username and password. Where did you pick that up?

You can use a browser to authenticate and download the slave-agent.jnlp and 
save file on the slave local disk. Then start the slave and profile a 
file://localhost/path/to/slave-agent.jnlp as URL on the slave command line.

-- Sami

Mehdi Hayani Soujaa  kirjoitti 1.2.2013 kello 11.38:

> Hii,
> 
> From the "Jenkins-The Definitive Guide" book we've tried to add the slave 
> based on the command line strategy. So, as mentioned in the book, we used the 
> following command: 
> 
> java -jar slave.jar -jnlpUrl 
> _http://**.**.**.**:/cip/computer/NewNode/slave-agent.jnlp -auth 
> user:password
> 
> But, the problem is that each time we execute this command, we get this error:
> 
> Failing to obtain 
> http://**.**.**.***:/cip/computer/NewNode/slave-agent.jnlp
> java.io.IOException: Failed to load 
> _http://**.**.**.***:/cip/computer/NewNode/slave-agent.jnlp: 404 Not Found
> at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:238)
> at hudson.remoting.Launcher.run(Launcher.java:200)
> at hudson.remoting.Launcher.main(Launcher.java:173)
> Waiting 10 seconds before retry
> 
> It seems that it can't find the slave agent file, But if we copy the URL in a 
> browser manually, the file is downloaded.
> 
> 
> Any idea about this issue ?? 
> 
> 
> Regards 
> Mehdi 
> 
> 
> -- 
> 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.
>  
>  

-- 
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: git: Can I change a barnach in 'Branches to build' in configuration after building a project in a specific branch

2013-02-02 Thread Sami Tikka
Yes, you can change the branch specification later.

I myself always like to explicitly specify the branch instead of leaving it 
blank. I really don't know what the git plugin does when you leave it blank. Is 
there a reason why you cannot specify the name of the branch in the job 
configuration?

And do not care about the (no branch) in the Jenkins workspace. The git plugin 
does not clone or checkout the same way you normally do. That's the reason why 
the workspace looks like it isn't on any branch, but that's just an illusion.

-- Sami

Ahmed Mubbashir Khan  kirjoitti 27.1.2013 kello 14.19:

> Plus on executing 'git branch -a'
> It doesn't list any of the other remote branch, see:
> $ git branch -a
> * (no branch)
>   master
>   remotes/origin/HEAD -> origin/master
>   remotes/origin/master
> 
> 
> 
> On Sunday, 27 January 2013 16:13:09 UTC+4, Ahmed Mubbashir Khan wrote:
> Hi All, 
> I configured a porject with a specific branch, then instead of specifiying a 
> branch I though it would be better if I go with the default behaviour that is 
> build every branch.
> I removed the the branch name from 'Branches to build' but on polling it 
> seems like that it is still looking for changes in the old branch.
> So the question is: Can I change a barnach in 'Branches to build' in 
> configuration after building a project in a specific branch
> 
> Following is the pooling log:
> Polling for changes in
> Seen branch in repository origin/HEAD
> Seen branch in repository origin/master   -> What it seems like that its 
> still looking only changes only in master
> Done. Took 5.1 sec
> No changes
> 
> 
> I am using jenkins version 1.499 and git plugin version 1.1.26
> 
> thoughts?

-- 
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: Which branch is build if there are multiple branches in a job and job has been configured for all jobs?

2013-02-02 Thread Sami Tikka
I guess you are using git as your version control system and your question is 
specific to the way the Jenkins git plugin works. It really would make 
answering these questions a bit easier if people would tell a little bit what 
kind of setup they have...

If the git plugin has been configured to follow all branches, it wants to build 
every branch at least once. After it has done that, it will only build the 
branches that get new commits.

If you have a lot of branches which have not been built, remove all branches 
you do not need anymore. You can also cancel the builds of branches you don't 
need. Jenkins git plugin consider a branch built when it has started building a 
branch. It does not matter if you cancel the build in mid-flight.

-- Sami

Ahmed Mubbashir Khan  kirjoitti 28.1.2013 kello 10.36:

> Hi All, 
> 
> Which branch is build if there are multiple branches in a job and job has 
> been configured for all jobs?
> What is the workflow? How jenkins determine what to build? 
> 
> Similarly:
> If a job was initially configured for master, and then we switch it to 
> monitor all branches. It seems like its building branches which doesn't have 
> any commits lately.
> The output is something like:
> Checking out Revision b6f8f39... (origin/sprint1)
> No change to record in branch origin/sprint1
> [workspace] $ /bin/sh -xe /home...   --> Still 
> executing.
> 
> Any thoughts?
> 
> --
> Regards, 
> Mubbashir

-- 
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: copy artifact fail

2013-02-02 Thread Sami Tikka
It looks like the artifact was being copied to a slave and the connection 
broke. The reason is not clear from the stacktrace. Is there anything in the 
logs on the slave side?

-- Sami

Chris Withers  kirjoitti 29.1.2013 kello 14.21:

> Hi All,
> 
> I've seen stack traces such as the following a couple of times:
> 
> """
> Deleting project workspace... ERROR: Failed to copy artifacts from
>  with filter: **
> hudson.util.IOException2: Failed to copy
> /var/lib/jenkins/jobs//builds/2013-01-29_08-01-48/archive/source/.tar.gz
> to
> /var/lib/jenkins/workspace//.tar.gz
>   at
> hudson.plugins.copyartifact.FingerprintingCopyMethod.copyOne(FingerprintingCopyMethod.java:91)
>   at 
> hudson.plugins.copyartifact.CopyArtifact.perform(CopyArtifact.java:248)
>   at 
> hudson.plugins.copyartifact.CopyArtifact.perform(CopyArtifact.java:215)
>   at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
>   at
> hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:717)
>   at hudson.model.Build$BuildExecution.build(Build.java:199)
>   at hudson.model.Build$BuildExecution.doRun(Build.java:160)
>   at
> hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:499)
>   at hudson.model.Run.execute(Run.java:1502)
>   at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
>   at hudson.model.ResourceController.execute(ResourceController.java:88)
>   at hudson.model.Executor.run(Executor.java:236)
> Caused by: java.io.InterruptedIOException
>   at hudson.remoting.ProxyOutputStream._write(ProxyOutputStream.java:120)
>   at hudson.remoting.ProxyOutputStream.write(ProxyOutputStream.java:103)
>   at hudson.remoting.RemoteOutputStream.write(RemoteOutputStream.java:110)
>   at java.security.DigestOutputStream.write(DigestOutputStream.java:100)
>   at hudson.remoting.RemoteOutputStream.write(RemoteOutputStream.java:110)
>   at hudson.Util.copyStream(Util.java:414)
>   at hudson.FilePath$33.invoke(FilePath.java:1605)
>   at hudson.FilePath$33.invoke(FilePath.java:1598)
>   at hudson.FilePath.act(FilePath.java:842)
>   at hudson.FilePath.act(FilePath.java:824)
>   at hudson.FilePath.copyTo(FilePath.java:1598)
>   at
> hudson.plugins.copyartifact.FingerprintingCopyMethod.copyOne(FingerprintingCopyMethod.java:74)
>   ... 11 more
> Caused by: java.lang.InterruptedException
>   at java.lang.Object.wait(Native Method)
>   at java.lang.Object.wait(Object.java:167)
>   at hudson.remoting.PipeWindow$Real.get(PipeWindow.java:177)
>   at hudson.remoting.ProxyOutputStream._write(ProxyOutputStream.java:118)
>   ... 22 more
> Build step 'Copy artifacts from another project' marked build as failure
> ...
> """
> 
> What's going on here? What actually failed and how?
> 
> cheers,
> 
> Chris
> 
> -- 
> 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.
> 
> 

-- 
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: How to lauch tomcat6 into /etc/init.d

2013-02-02 Thread Sami Tikka
It is not a good idea to run Jenkins as root. Unless you know what you are 
doing. And even then it is not a good idea.

And if you do not know how to do it, you definitely should not be doing it.

Maybe instead you could explain what you are trying to do and why do you think 
you need Jenkins to have root privileges? I'm sure there are better ways to do 
what you need to do without running Jenkins as root.

-- Sami

adrien ruffie  kirjoitti 29.1.2013 kello 18.40:

> Hello all I have a problem,
>  
> My tomcat is launch on the server with /etc/init.d/tomcat6 start/stop
> And only with following script because several properties were set into
> This script.
>  
> But Jenkins doesn’t have a a root privileges to run this script, how I can do 
> that
> With a job plz ?
> 
> -- 
> 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.
>  
>  

-- 
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: Installing operating systems on slaves via Jenkins

2013-02-02 Thread Sami Tikka
And if your slaves are not virtual machines, take a look at 
https://wiki.jenkins-ci.org/display/JENKINS/PXE+Plugin or 
https://wiki.jenkins-ci.org/display/JENKINS/Scripted+Cloud+plugin

-- Sami

Mark Waite  kirjoitti 30.1.2013 kello 14.31:

> If you need to restore an existing operating system to a known good state 
> each time, you could consider using a virtual machine and reverting to a 
> snapshot of the virtual machine.  There are several plugins for virtual 
> machine control from Jenkins.  The plugin you use depends on the virtual 
> machine hypervisor you choose.
> 
> If you need to install a new operating system (possibly you're testing an 
> operating system distribution that is changing?), you might consider "puppet" 
> or "chef" as ways to install a new operating system under Jenkins control.  I 
> believe the puppet team has one or more tutorials on how to use puppet with 
> Jenkins.
> 
> Mark Waite
> 
> From: Manish Singh 
> To: jenkinsci-users@googlegroups.com 
> Sent: Wednesday, January 30, 2013 12:06 AM
> Subject: Installing operating systems on slaves via Jenkins
> 
> Hello All,
> 
> I have a requirement, where I need to reinstall OS on slave machines before a 
> job is executed. This is needed as we need a clean OS before executing the 
> tests.
> 
> What are the best ways to do this via Jenkins?
> 
> -Manish
> -- 
> 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.
>  
>  
> 
> 
> 
> -- 
> 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.
>  
>  

-- 
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: Jenkins/Slave connection via TelNet

2013-02-02 Thread Sami Tikka
Which Jenkins version are you using? Recent Jenkins versions allowed 
unauthenticated access to the slave-agent.jnlp URL, which makes starting JNLP 
slaves a bit more difficult.

I'm pretty sure the slave startup does not use -auth option to provide a 
username and password. Where did you pick that up?

You can use a browser to authenticate and download the slave-agent.jnlp and 
save file on the slave local disk. Then start the slave and profile a 
file://localhost/path/to/slave-agent.jnlp as URL on the slave command line.

-- Sami

Mehdi Hayani Soujaa  kirjoitti 1.2.2013 kello 11.38:

> Hii,
> 
> From the "Jenkins-The Definitive Guide" book we've tried to add the slave 
> based on the command line strategy. So, as mentioned in the book, we used the 
> following command: 
> 
> java -jar slave.jar -jnlpUrl 
> _http://**.**.**.**:/cip/computer/NewNode/slave-agent.jnlp -auth 
> user:password
> 
> But, the problem is that each time we execute this command, we get this error:
> 
> Failing to obtain 
> http://**.**.**.***:/cip/computer/NewNode/slave-agent.jnlp
> java.io.IOException: Failed to load 
> _http://**.**.**.***:/cip/computer/NewNode/slave-agent.jnlp: 404 Not Found
> at hudson.remoting.Launcher.parseJnlpArguments(Launcher.java:238)
> at hudson.remoting.Launcher.run(Launcher.java:200)
> at hudson.remoting.Launcher.main(Launcher.java:173)
> Waiting 10 seconds before retry
> 
> It seems that it can't find the slave agent file, But if we copy the URL in a 
> browser manually, the file is downloaded.
> 
> 
> Any idea about this issue ?? 
> 
> 
> Regards 
> Mehdi 
> 
> 
> -- 
> 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.
>  
>  

-- 
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: Why are my build slaves being used to sync files when all executor threads are busy

2013-02-02 Thread Sami Tikka

Chris Withers  kirjoitti 1.2.2013 kello 13.39:

> On 01/02/2013 11:30, Thomas Fields wrote:
>> Slave1
>> 1. Building project1, #345
>> 2. Building project2, #125
>> 3. Building project3, #455
>> 4. Building project4, #34
>> Building project5, #12
>> Building project6, #122
>> Building project7, #142
>> Building project8, #27
>> Building project9, #29
>> 
>> Because the extra jobs are syncing I'm running out of disk on my slaves
>> all the time. Is there any way to disable these extra builds/syncs on
>> the slaves?
> 
> I think you're experiencing the same problem that I did:
> 
> https://groups.google.com/forum/?fromgroups=#!topic/jenkinsci-users/JAE9lxU4jZ8
> 
> The hack that is the Matrix Tie Parent plugin will help you, but you still 
> need a sacrificial machine to tie to where all that syncing will happen...
> 
> This feels like a bug/bad design in the way marix jobs works (when/how is 
> that source control management on the parent job ever going to be used?) but 
> I don't know where/how to raise it to get it fixed...

https://issues.jenkins-ci.org/ is the Jenkins bug database.

If this is really a big problem for you and you are willing to pay to get it 
fixed, I'm sure there are people who can help you. There's also 
http://www.cloudbees.com/jenkins-enterprise-by-cloudbees-overview.cb

There are some things you can do to cope with the problem:

* Add more disk space to the slaves or

* Limit the number of executors on the slaves (and maybe add more slaves) or

* Make sure the jobs clean up after the build is done (maybe use PostBuildStep 
plugin to execute a clean up script as the last operation or use Delete 
workspace plugin) or

* Turn off flyweight tasks. This makes the matrix parent build consume a real 
executor which limits the number of parent builds a single slave is forced to 
deal with. See 
https://wiki.jenkins-ci.org/display/JENKINS/Features+controlled+by+system+properties
 or

* Use https://wiki.jenkins-ci.org/display/JENKINS/Exclude+flyweight+tasks 
plugin to exclude flyweight tasks (= matrix parent builds) from slaves that 
cannot take the hit.

Or maybe use a combination of some of the above.

-- Sami

-- 
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: All my added build descriptions and "keep build forever" annotations gone!

2013-02-02 Thread Sami Tikka
Did you upgrade or downgrade Jenkins? Has it restarted? What is in the log 
file? Did you have job config history plugin installed? And if not, why? Is 
your Jenkins configured to require login allowing changes?

-- Sami

Steve K  kirjoitti 2.2.2013 kello 0.13:

> Has anyone else encountered this?
> 
> I actually spent a fair amount of time adding my own build descriptions and, 
> for a long time, they were visible in my project's build history.
> I also designated several of the builds as "Keep Forever".
> 
> Now, they are all gone.  I know I didn't delete them and no one with the 
> required privileges admits to removing them.  There were LOTS of them, so it 
> is unlikely that they were removed by mistake.
> 
> Could this be a bug or do I have a determined and diabolical saboteur in the 
> ranks?
> 
> I'm running Jenkins version  1.480.1
> 
> I'd appreciate any clues you may be able to provide.
> 
> Thank you.
> -- 
> 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.
>  
>  

-- 
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: a lot of jobs

2012-11-20 Thread Sami Tikka
I type some Groovy commands into the Script Console you can find under the 
Manage Jenkins link in the sidebar.

-- Sami

Marcin Biegan  kirjoitti 15.11.2012 kello 2.39:

> Hi,
> 
> I wanted to ask how do you handle configuring multiple jobs. We have
> about 10 maven projects to build in at least 2 versions (trunk/
> branch), which makes 20 jobs, some more for additional tests,
> releases, maybe deployment, verification, etc. Manually adding
> permissions and adjusting configuration of jobs is cumbersome. Is
> there a working plugin which would allow to set some 'parent' job
> which would define default configuration? (Template Project Plugin is
> not enough, because it 'works' only at job creation). I know also
> about Configuration Slicing Plugin, but this will not work in my case
> as it requires admin permissions.
> 
> Thanks
> Marcin Biegan



Re: Execute shell failure

2012-11-07 Thread Sami Tikka
The usual way to use Jenkins is for the developer to commit his changes to a 
version control repository, which Jenkins will monitor and when it sees a new 
commit, Jenkins will check out a copy of the sources under the Jenkins work dir 
and then execute some commands, typically to build and test the software. 

I'm not entirely sure what you would hope to accomplish by having Jenkins mess 
about in the same directory you are working in. 

Anyway, if you wish to avoid the permission issue when Jenkins is running as 
another user, may I suggest you try https://github.com/stisti/jenkins-app 
instead. Jenkins-app will run Jenkins under your account. 

-- Sami

Josselin Pierre  kirjoitti 7.11.2012 kello 18.05:

> Giving the admin right to a user depends on your system, not on Jenkins.
> I've never used a Mac, so I can't help you there.
> 
> However, good practice is often to NOT give admin right to a Jenkins user, 
> but just the rights it actually needs, and not be allowed to do no anything 
> everywhere.
> Jenkins should work on specific folders he owns.
> To change the owner of a folder, the linux command is "chown -R <> 
> <>"
> 
> 
> 
> On Wednesday, November 7, 2012 3:49:51 PM UTC+1, rakesh wrote:
>> 
>> I see user info in: /Library/LaunchDaemons/org.jenkins-ci.plist
>> content of this .plist:
>> rpatel$ cat org.jenkins-ci.plist 
>> 
>> > "http://www.apple.com/DTDs/PropertyList-1.0.dtd";>
>> 
>> 
>> StandardOutPath
>> /var/log/jenkins/jenkins.log
>> StandardErrorPath
>> /var/log/jenkins/jenkins.log
>> EnvironmentVariables
>> 
>> JENKINS_HOME
>> /Users/Shared/Jenkins/Home
>> 
>> GroupName
>> daemon
>> KeepAlive
>> 
>> Label
>> org.jenkins-ci
>> ProgramArguments
>> 
>> /bin/bash
>> /Library/Application 
>> Support/Jenkins/jenkins-runner.sh
>> 
>> RunAtLoad
>> 
>> UserName
>> jenkins
>> SessionCreate
>> 
>> 
>> 
>> 
>> 
>> 
>> Now how do I have this user admin access ?
>> 
>> Thanks,
>> Rakesh
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> 
>> On Tuesday, November 6, 2012 3:33:34 PM UTC-5, mgimza wrote:
>>> 
>>> 
>>> I am not sure about MAC, but on linux there is a config file that can be 
>>> modified to specify the user and group to which Jenkins should.
>>> 
>>> On Linux this file is  /etc/sysconfig/jenkins
>>> 
>>> 
>>> The variables to add/modify:
>>> # Unix user account that runs the Jenkins daemon
>>> # Be careful when you change this, as you need to update
>>> # permissions of $JENKINS_HOME and /var/log/jenkins.
>>> #
>>> JENKINS_USER=""
>>> JENKINS_GROUP=""
>>> 
>>> 
>>> 
>>> On Tue, Nov 6, 2012 at 2:54 PM, rakesh  wrote:
 Hi Josselin,
 How do I check this?
 
 -Rakesh
 
 On Tuesday, November 6, 2012 2:43:39 PM UTC-5, Josselin Pierre wrote:
> 
> Hi,
> 
> Another point to check is user rights : does jenkins' user have access to 
> this folder ?
> 
> 
> cheers, 
> Josselin
> 
> 
> 2012/11/6 Marek Gimza 
>> Rakesh,
>> 
>> Does this directory acutally exist?
>> 
>> /Users/rpatel/Documents/MobSources/XX_iOS
>> 
>> Can use cd to this dir manually?
>> 
>> Kind Regards,
>> Mgimza
>> 
>> 
>> 
>> On Tue, Nov 6, 2012 at 2:13 PM, rakesh  wrote:
>>> I am fairly new user of Jenkins, just installed it on my local mac 
>>> machine. 
>>> I created a job to run few commands which run successfully from xterm, 
>>> though coming across following error on jenkins.
>>> Not sure what I am doing wrong here? 
>>> 
>>> Job is running:
>>> --
>>> Execute shell:
>>> -
>>> pwd
>>> cd /Users/rpatel/Documents/MobSources/XX_iOS
>>> cucumber --format json --out result.json
>>> 
>>> 
>>> -
>>> Console output:
>>> -
>>> Building in workspace 
>>> /Users/Shared/Jenkins/Home/workspace/XX-Calabash-iOS
>>> [XX-Calabash-iOS] $ /bin/sh -xe 
>>> /var/folders/c0/rzt3wbtj3j11yp13rfmhxyww7c/T/hudson4166321227994340301.sh
>>> + pwd
>>> /Users/Shared/Jenkins/Home/workspace/XX-Calabash-iOS
>>> + cd /Users/rpatel/Documents/MobSources/XX_iOS
>>> /var/folders/c0/rzt3wbtj3j11yp13rfmhxyww7c/T/hudson4166321227994340301.sh:
>>>  line 3: cd: /Users/rpatel/Documents/MobSources/XX_iOS: Not a directory
>>> Build step 'Execute shell' marked build as failure
>>> Finished: FAILURE
>>> 
>>> 
>>> Thanks,
>>> Rakesh
>>> 


Re: Github Webhook

2012-10-06 Thread Sami Tikka
You could install the Github plugin. It provides an entry point that Github web 
hook can trigger without authentication. 

-- Sami

William Soula  kirjoitti 5.10.2012 kello 15.53:

> Our Jenkins currently builds both github enterprise projects and svn 
> projects.  I would really like to implement the strategy of having every push 
> to the github repo trigger a build instead of polling.  The problem is our 
> Jenkins has been secured with Role Based security.  I tried just putting in 
> the url https://[username]:[password]@jenkins.mycompany.com into the webhook 
> url part of the github repo but our Jenkins is not on ssl.  So I tried 
> http://[username]:[password]@jenkins.mycompany.com and that didn’t work.  To 
> test I am clicking the test webhook button in github.  I then thought about 
> trying the gihub oauth plugin, but from what I can tell this will only work 
> if you only use the github committer strategy for authentication, but I also 
> have svn projects so I need to keep my role-based strategy for security.  Is 
> there any way to get the webhook to work with github enterprise?  Is there 
> any way to use the github committer strategy for authentication for just one 
> build?  Is there any way to get hooks to work with a Jenkins locked down with 
> role-based security?
>  
> Thanks,
> Will


Re: Will reducing the Max # of builds to keep automatically delete old builds?

2012-09-24 Thread Sami Tikka
Disk usage plugin recalculates disk space usage based on a very, very lazy 
schedule. It is actually somewhat disk-intensive, so it is nice it doesn't run 
continuously.

Another way to save on disk space is to find the spot in job configuration 
where you configure the archived artifacts. Under it is a button titled 
Advanced. Click on that. More options will appear. Among them is an option to 
always delete old artifacts and only keep the latest. The job will still keep 
all the test results and other statistical history, only the artifacts are 
nuked (except the last).

I use this option on one of my jobs that produces 1 GB of artifacts for every 
build.

Of course it won't help if you need to keep more artifacts.. You can write 
a script that deletes the artifacts you do not need from the disk. Jenkins 
won't mind if they disappear.

-- Sami

Ed Young  kirjoitti 14.9.2012 kello 16.39:

> the disk usage plugin is installed and is what I've been using to
> determine which projects (mine) are the biggest disk hogs.
> 
> One of my builds uses 18 GB of space. The next largest one is 1GB. The
> reason it uses so much space is because I want keep 50 old builds
> behind so that if I notice that test coverage has dropped, for
> example, I can go back and see where that happened. I'm not sure of
> any other way to track this kind of thing without keeping a large
> number of builds.
> 
> 
> On Fri, Sep 14, 2012 at 6:11 AM, Lars Nordin  wrote:
>> -Original Message-
>> From: Ed Young
>> 
>> Scott, kicking off the build seems to have  deleted the old builds, although 
>> I'm not seeing the diskspace usage go down the way I'm hoping. I have a lot 
>> of builds to reconfigure and kick off though so this make some time.
>> -Original Message-
>> 
>> You might want to install the disk usage plug-in and it help you find what 
>> jobs and builds are consuming the most disk space.
>> https://wiki.jenkins-ci.org/display/JENKINS/Disk+Usage+Plugin
>> 
> 
> 
> 
> -- 
> - Ed



Re: retry build upon failure?

2012-09-16 Thread Sami Tikka
Could you post exactly what you see in the console log of the failed build? 
Also, it might help if you could post your job config.xml or put in 
pastebin/gist so we could take a look.

-- Sami

Ed Young  kirjoitti 14.9.2012 kello 22.38:

> I installed the Naginator Plugin (v1.8) because the retry failed build
> plugin indicated that it was deprecated in favor of the Naginatore
> plugin.
> 
> It doesn't seem to be working the way I expect it to however. I
> configured it to simply
> 
> Retry build after failure up to 3 times, with all other defaults, but
> after a failure there is no retry. I configured it for a  fixed delay
> and it still did not retry.
> 
> It seems like a very simple configuration and the build is a hard
> failure (test failures) so I can't tell where I'm going wrong.
> Using Jenkins 1.436.
> 
>
>
>
>
>
>
>
>
> 
> 
> On Fri, Sep 14, 2012 at 5:59 AM, William Soula
>  wrote:
>> Or https://wiki.jenkins-ci.org/display/JENKINS/Retry+Failed+Builds+Plugin
>> 
>> 
>> 
>> 
>> 
>> From: jenkinsci-users@googlegroups.com
>> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of nicolas de loof
>> Sent: Friday, September 14, 2012 6:16 AM
>> To: jenkinsci-users@googlegroups.com
>> Subject: Re: retry build upon failure?
>> 
>> 
>> 
>> see http://wiki.jenkins-ci.org/display/JENKINS/Naginator+Plugin
>> 
>> 2012/9/14 Ed Young 
>> 
>> Is it possible to retry a build upon a failure? Maybe with a retry count?
>> 
>> 
> 
> 
> 
> -- 
> - Ed


Re: How to build a project for multiple mobile devices in a single job

2012-09-01 Thread Sami Tikka
You can also use ant or python or perl build step because they are 
cross-platform too. 

I use ant myself because it is easy because jenkins can auto install ant. 

-- Sami


Les Mikesell  kirjoitti 29.8.2012 kello 20.44:

> On Wed, Aug 29, 2012 at 11:38 AM, bearrito
>  wrote:
>> Why the insistence on single job?
>> 
>> Jobs are cheap in Jenkins and it doesn't make sense to couple building
>> binaries that don't have anything to do with one another except the source.
>> 
>> I would have a job per binary. I would run them all in parallel using either
>> the Join Trigger Plugin or the BuildFlow Plugin.
> 
> A matrix build should work too, if you can come up with a wrapper
> script that you can run with the xhell or groovy plugins so you can
> execute the same command on all platforms to do the build.   But I'm
> not sure there is that much advantage over separate jobs polling for
> scm changes.
> 
> -- 
>   Les Mikesell
>lesmikes...@gmail.com


Re: jenkins Unable to find build script at C:/

2012-08-27 Thread Sami Tikka
Jenkins has a built-in limitation: It must check out your source tree to local 
disk before it is able to access files in version control server.

Go to job configuration. Then, under "Source Code Management", choose 
Subversion.

In the Repository URL type 
https://svn.qsu-dev.com/svn/moveon4-javabrowsertests/trunk/moveon4tests1

Provide a way to authenticate Jenkins to your Subversion server, if Jenkins 
prompts you to do it.

Did you know that usually URLs have two slashes in the beginning? 
"https://SERVERNAME"; vs. "https:/SERVERNAME". Some software might be picky and 
not work correctly if you omit the 2nd slash.

-- Sami

praneeth  kirjoitti 27.8.2012 kello 12.39:

> Hi Mark ,
> 
> I have placed the selenium tests in the subversion..but still I am getting 
> this error. My buid.xml file is at 
> https:/svn.qsu-dev.com/svn/moveon4-javabrowsertests/trunk/moveon4tests1  but 
> you can see in the error that it is automatically pointing to 
> /var/lib/jenkins/jobs/moveon4/workspace..it is the default home drirectory 
> ..how can i change it?
> 
> Building in workspace /var/lib/jenkins/jobs/moveon4/workspace
> Updating https://svn.qsu-dev.com/svn/moveon4-javatests/trunk
> At revision 71
> no change for https://svn.qsu-dev.com/svn/moveon4-javatests/trunk since the 
> previous build
> FATAL: Unable to find build script at 
> /var/lib/jenkins/jobs/moveon4/workspace/https:/svn.qsu-dev.com/svn/moveon4-javatests/trunk/moveon4tests1/build.xml
> Build step 'Invoke Ant' marked build as failure
> Finished: FAILURE
> 
> On Sunday, 26 August 2012 14:16:47 UTC+1, praneeth wrote:
> 
> I am using Jenkins and Ant to run my selenium tests. It works fine when I run 
> them on my local machine. Now I have a Jenkins server which is on a different 
> location and I have to run my tests on that server. when I tried to run the 
> tests on that server Its is failing because it  couldn't find the build.xml 
> file. can you please let me know how can I change the home directory path? 
> The home directory path in the server was set to /var/lib/jenkin   and my 
> build.xml is in c:/ drive of my machine
> 
> the error it is showing is
> 
> Started by user : Building in workspace /var/lib/jenkins/jobs/moveon4 
> java tests/workspace FATAL: Unable to find build script at C:\selenium tests 
> for move\movetests1\build.xml Build step 'Invoke Ant' marked build as failure 
> Finished: FAILURE
> 
> 
> 
> 
> 
> Regards
> 
> praneeth
> 



Re: Mac OSX slave timeouts

2012-08-27 Thread Sami Tikka
The 3.5 sec clock drift is not yet alarming but it does cause me to raise an 
eyebrow. You are not synchronizing clocks between your Jenkins master, slave 
and SCM server?

Try to get the clocks in sync. Install ntp daemon where it is missing and 
configure them to sync to your organization's ntp server or pool.ntp.org.

If that does not help, go to http://YOURJENKINS/threadDump, save it to 
pastebin/gits and ask someone on the list to take a look.

-- Sami

Chuck Doucette  kirjoitti 27.8.2012 kello 18.36:

> I rebooted the machine and reran every job destined to be run on that Mac 
> slave node.
> The all completed quickly and successfully.
> Now, as I monitor the slave node, here's what I see for it:
> 
> Clock Difference:
> 3.5 sec ahead
> 
> Response Time
> 3410 ms
> 
> When I login to the machine (as myself, not the Jenkins user), and I start 
> Activity Monitor, and I review All Processes, I see:
> a) highest CPU usage is <10% - averaging around 2% for ScreenSharingAgent and 
> 1% for Activity Monitor
> b) free memory: 1.8GB
> c) used memory: 1.2GB
> d) swap used: 0 bytes
> 
> So, I believe I have definitively answered your question about plenty of free 
> memory and not swapping.
> 
> When I run jconsole to review the Jenkins slave process, I see:
> a) 6MB of heap memory usage
> b) 15 live threads
> c) 2834 classes loaded
> d) 0.1% CPU usage
> 
> As I continue to review memory usage of the Jenkins slave process, I see 
> after an initial drop from ~20MB to ~4MB, I see a steady climb. It's already 
> back up to 15MB.
> 
> Chuck
> 
> On Aug 27, 2012, at 10:22 AM, Chuck Doucette  wrote:
> 
>> Here is more information, I just saw this message on the Manage Jenkins 
>> screen (from the master node, about the mac slave with problems):
>> 
>> There are more SCM polling activities scheduled than handled, so the threads 
>> are not keeping up with the demands. Check if your polling is hanging, 
>> and/or increase the number of threads if 
>> necessary<http://cruisecontrol.office.everyscape.com:8080/descriptor/hudson.triggers.SCMTrigger/>.
>> 
>> when I clicked on the link, I saw this:
>> 
>> Current SCM Polling Activities
>> There are more SCM polling activities scheduled than handled, so the threads 
>> are not keeping up with the demands. Check if your polling is hanging, 
>> and/or increase the number of threads if necessary.
>> 
>> The following polling activities are currently in progress:
>> 
>> Project  
>> ↓<http://cruisecontrol.office.everyscape.com:8080/descriptor/hudson.triggers.SCMTrigger/#>
>>  Running for   
>> <http://cruisecontrol.office.everyscape.com:8080/descriptor/hudson.triggers.SCMTrigger/#>
>> ESSDK<http://cruisecontrol.office.everyscape.com:8080/job/ESSDK/scmPollLog/> 
>>2 days 21 hr
>> Uscapeit-Android<http://cruisecontrol.office.everyscape.com:8080/job/Uscapeit-Android/scmPollLog/>
>>   2 days 21 hr
>> ScapeFolio<http://cruisecontrol.office.everyscape.com:8080/job/ScapeFolio/scmPollLog/>
>>   2 days 21 hr
>> 
>> This are all projects that only run on the Mac slave node.
>> 
>> I'm not sure how to kill these SCM polling jobs.
>> I do know how to kill regular build jobs.
>> Perhaps I can try SCM notification instead (notify jenkins to rebuild upon 
>> checkin).
>> 
>> Chuck
>> 
>> On Aug 27, 2012, at 10:11 AM, Chuck Doucette 
>> mailto:cdouce...@everyscape.com>> wrote:
>> 
>> Yes, I believe the Mac hardware is in good general health.
>> The machine has 3GB of physical memory, so I believe it has plenty of free 
>> memory.
>> I don't believe it is swapping - but I'm not sure how to tell.
>> I have tried running Activity Monitor and JConsole.
>> As far as I can tell, there is no other software running.
>> There is no Time Machine backup setup nor has any anti virus software been 
>> installed.
>> 
>> As I said below, I had to wipe the disk and reinstall everything from 
>> scratch.
>> So, it has: Mountain Lion, Java, Xcode.
>> That's about it.
>> Nobody else is logged on except the jenkins user over ssh.
>> 
>> Now builds that should take a few minutes are taking multiple hours, and I 
>> see that time synchronization is off by a few minutes. I will try to fix the 
>> latter right now.
>> 
>> Chuck
>> 
>> On Aug 24, 2012, at 4:54 PM, Sami Tikka 
>> mailto:sjti...@gmail.com>> wrote:
>> 
>> Just to rule out the obvious culprits:
>> 
>> - The Mac hardware is in good general health?
>>

Re: Multi-project pushes to Bitbucket not triggering all relevant Jenkins jobs

2012-08-25 Thread Sami Tikka
Neither Jenkins or Git really support having multiple projects in one Git 
repository (at least not yet). The difficulties you are experiencing are a 
result of that. 

I always thought you have to specify polling schedule if you check the polling 
box... but you can make the polling cycle very long, e.g. once a week.

-- Sami

Paul Hoadley  kirjoitti 25.8.2012 kello 14.37:

> Hello,
> 
> I'm using Jenkins 1.464.  I have a Bitbucket repository that contains several 
> top-level directories, each of which represent a single Jenkins job.  I'm 
> using the Git plugin and its "Included Regions" attribute to detect just 
> those changes that are relevant to each job. [1]  The Bitbucket repo has a 
> Service to hit the /git/notifyCommit?url=... on the Jenkins server.  Polling 
> is checked for each project, but there's no schedule set. [2]  Hitting that 
> URL from the shell gets a response listing all the expected jobs, so this 
> certainly seems to be set up correctly.
> 
> The problem is that when I push changes that span multiple projects in the 
> repo, only one of the projects is being built.  If it's the wrong project 
> with respect to dependency order, the build breaks.  This seems to happen 
> regularly, but I don't know whether it's deterministic.  It's certainly 
> breaking the build often enough to be very annoying.
> 
> Has anyone seen this before?  I suppose a solution might be to set up 
> separate Bitbucket "Jenkins Services", one for each project, but that's more 
> typing than just hitting the one notifyCommit URL.
> 
> 
> [1] As an aside, this seems like an impedance mismatch to me (special 
> attributes, cloning the same repo multiple times for the separate jobs), and 
> I am considering breaking the repo up into multiple single-project repos. 
> This would have the advantage of solving the problem I describe above.
> 
> [2] All as described here: 
> http://kohsuke.org/2011/12/01/polling-must-die-triggering-jenkins-builds-from-a-git-hook/
> 
> -- 
> Paul.
> 



Re: Build help!

2012-08-24 Thread Sami Tikka
Have you read 
https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+as+a+Windows+service
 ?

I assume you used the native windows package to install Jenkins. I think you 
can follow the advice at the end of the page or if that is too difficult, then 
use the method described at the beginning of the page.

-- Sami

Dennis Planting  kirjoitti 24.8.2012 kello 12.31:

> 
> 
> Den fredagen den 24:e augusti 2012 kl. 09:58:40 UTC+2 skrev Richard Bywater:
> Looks like the user that is being used to run Jenkins doesn't have 
> permission to that directory (looks like lack of write permissions) 
> 
> Assuming that this is a Windows 7/2008/similar machine then I think 
> you'd be best off not having Jenkins in the Program Files directory as 
> I've had nothing but problems running things when they are located in 
> there (due to the UAC permissions etc. that Windows uses now) 
> 
> This blog entry might be of some use to relocate the workspace 
> directory if you don't want to relocate the Jenkins binaries -> 
> http://ingorichter.blogspot.co.nz/2012/02/jenkins-change-workspaces-and-build.html
>  
> 
> Richard. 
> 
> 
> k thanks, i tryed to follow how to change workspace but could'nt get it 
> working, mind telling me how i can relocate jenkins?
>  


Re: Mac OSX slave timeouts

2012-08-24 Thread Sami Tikka
Just to rule out the obvious culprits:

- The Mac hardware is in good general health?

- There is plenty of free memory? The system is not swapping?

- There isn't some process running and taking a lot of cpu? Spotlight indexing, 
Time Machine backup, some anti-virus real-time scanner?

Even though Macs are great machines, even they can get messed up and become 
slow.

-- Sami

Chuck Doucette  kirjoitti 24.8.2012 kello 20.19:

> We are running Jenkins 1.478.
> The master node is running on Windows 2003 (xp).
> It has 3 slaves - 2 other Windos machines and 1 Mac.
> The mac machine was working fine - then when I attempted to upgrade the O/S 
> (from Snow Leopard to Lion) it failed due to disk errors.
> I've since reconstituted the machine from scratch - so all of the hardware is 
> the same but all of the software (and configurations) are brand new (Mountain 
> Lion).
> 
> Something appears to be causing one of our slave nodes (on Mac OSX) to take 
> longer and longer to respond.
> It's currently at ~1000ms response time.
> It has gotten up to 3000ms response time.
> 
> I have added two things to slave's launch JVM options to help in diagnosing 
> and resolving the problem:
> 1) -Dcom.sun.management.jmxremote (so I can monitor the performance of the 
> slave process via jconsole)
> 2) -Xmx2048m (to use 2GB of the 3GB of physical memory available on the 
> machine)
> 
> The timeouts have apparently caused jobs to fail with errors about channel 
> closing:
> Started by upstream project "ScapeFolio" build number 83
> 
> [EnvInject] - Loading node environment variables.
> [EnvInject] - [ERROR] - SEVERE ERROR occurs: 
> hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected 
> termination of the channel
> Archiving artifacts
> ERROR: Publisher hudson.tasks.Mailer aborted due to exception
> 
> hudson.remoting.ChannelClosedException
> : channel is already closed
>   at 
> hudson.remoting.Channel.send(Channel.java:492)
> Started by upstream project "ScapeFolio" build number 83
> 
> [EnvInject] - Loading node environment variables.
> [EnvInject] - [ERROR] - SEVERE ERROR occurs: 
> hudson.remoting.RequestAbortedException: java.io.IOException: Unexpected 
> termination of the channel
> Archiving artifacts
> ERROR: Publisher hudson.tasks.Mailer aborted due to exception
> 
> hudson.remoting.ChannelClosedException
> : channel is already closed
>   at 
> hudson.remoting.Channel.send(Channel.java:492)
> 
> Does anyone have any recommendations on how to diagnose and resolve these 
> problems?
> 
> Thanks,
> Chuck
> 
> 



Re: kill all jobs/empty the queue?

2012-08-23 Thread Sami Tikka
See http://scriptlerweb.appspot.com/script/show/59001

-- Sami

phil swenson  kirjoitti 23.8.2012 kello 20.02:

> works great.  can't find anything for killing all the current jobs though.
> 
> But this helps, thanks!
> 
> On Wed, Aug 22, 2012 at 5:26 PM, Jesse Farinacci  wrote:
> Greetings,
> 
> On Wed, Aug 22, 2012 at 7:21 PM, phil swenson  wrote:
> > When you have a bunch of jobs that are queued up and destined to fail (won't
> > compile for example)…. there should be a way to kill all the jobs and empty
> > the queue.
> > Is there a plugin for this?
> 
> https://wiki.jenkins-ci.org/display/JENKINS/Purge+Build+Queue+Plugin
> 
> -Jesse
> 
> --
> There are 10 types of people in this world, those
> that can read binary and those that can not.
> 



Re: Combining coverage reports

2012-08-22 Thread Sami Tikka
In the matrix job, archive the reports as build artifacts.

Then make another, simple freestyle job that gets triggered when the matrix job 
completes. This job will use Copy Artifact build step to download the 
artifacts. Click on the help buttons (the question marks) of the Copy Artifacts 
step. I'm pretty sure the help includes instructions how to pick up all 
artifacts from a matrix job.

-- Sami

Andrew Melo  kirjoitti 22.8.2012 kello 0.21:

> Hello all,
> 
> We have a large unittesting suite split into a matrix job. I'd like to
> combine the coverage reports from the different matrix configurations
> into one coverage report. I can handle the actual munging of the
> coverage reports, but before I go off trying to make glue things
> together, I was curious about what would be the best way to make a
> job, then ship all the coverage reports from the submatrix jobs to it.
> I feel like I can figure out making a dependent job, but I don't know
> how to get the files moved around.
> 
> Thanks,
> Andrew
> 
> -- 
> --
> Andrew Melo



Re: auto install of ANT on slave nodes fails

2012-08-22 Thread Sami Tikka
In the "Invoke Ant" build step, choose something else than Default for the "Ant 
Version" field.

-- Sami

Thomas Diligent  kirjoitti 22.8.2012 kello 12.21:

> Hello,
> 
> I have a jenkins install with two slave nodes (windows and macos).
> I try to use the same ant script on both within a multiple configuration job.
> 
> So I configured jenkins to automatically install ANT.
> Unfortunately, I get the error on windows: ant.bat is not recognized as 
> internal or external command ...
> The ant script works on mac because a default install is found (different 
> version from the one that should be installed by jenkins).
> Finally it seems that ANT is not installed by the jenkins server on none of 
> these slave nodes.
> 
> I found help on the web on tool auto-install, on distributed build but not on 
> that particular case.
> How to install ANT on slave nodes of a jenkins server ?
> 
> Thanks ahead,
> Thomas
> 
> 
> 
> 
> 



Could not initialize class com.sun.jna.Native

2012-08-22 Thread Sami Tikka
I have a Jenkins that doesn't work. It runs on Debian 6 using the Sun6
JDK. I have tried several versions of Jenkins and they all have this
same problem, including the latest 1.478:

Failed to load native POSIX impl; falling back on Java impl. Stacktrace follows.
java.lang.NoClassDefFoundError: Could not initialize class com.sun.jna.Native
at org.jruby.ext.posix.POSIXFactory.loadLibC(POSIXFactory.java:96)
at org.jruby.ext.posix.POSIXFactory.loadLinuxPOSIX(POSIXFactory.java:65)
at org.jruby.ext.posix.POSIXFactory.getPOSIX(POSIXFactory.java:24)
at hudson.os.PosixAPI.(PosixAPI.java:41)
at hudson.Util.createSymlink(Util.java:1011)
at hudson.model.Run.execute(Run.java:1500)
at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
at hudson.model.ResourceController.execute(ResourceController.java:88)
at hudson.model.Executor.run(Executor.java:236)

This problem occurs only on builds that execute on slaves. Builds that
run on the master locally have no problem. The build on the slave does
run but hangs forever when it starts archiving artifacts.

Anyone have any ideas?

-- Sami


Re: Archiving artifacts takes 9 hours

2012-08-20 Thread Sami Tikka
My Jenkins was archiving very slowly when I was using OpenJDK 1.6. When I 
changed to Sun JDK 1.6, the archiving sped up a lot. 

-- Sami

David Hreczany  kirjoitti 20.8.2012 kello 16.57:

> Hi Jenkins users,
> I am experiencing a problem with my Jenkins in that the archiving artifacts 
> portion of the build is taking way too long; 9 hours to be exact.
>  
> I am running Jenkins 1.412. All my slaves are on a virtual machine as well as 
> my master Jenkins.
>  
> I have 113 jobs and the artifacts being archived are only 250MB.
>  
> My Jenkins threadDump for the machine experiencing the problem is showing a 
> lot of threads being blocked on java.io.PrintStream, 
> java.util.logging.ConsoleHandler, and 
> hudson.plugins.logparser.LogParserReader.
>  
> I have one thread that is waiting on 
> java.util.concurrent.locks.AbstractQueuedSynchronizer.
>  
> Does anyone have any thoughts on how to speed up the “Archiving artifacts” 
> portion of my build.
>  
> Thanks very much.
>  
>  
> Dave
> David Hreczany
> Lead Quality Assurance Engineer
> 
>  
>  
> Office 312 948 5400
>  
> 
>  
> NOTICE: This electronic mail transmission may contain confidential 
> information and is intended only for the person(s) named. Any use, copying or 
> disclosure by or to any other person is strictly prohibited. If you have 
> received this transmission in error, please notify the sender via e-mail and 
> destroy this email retaining no electronic or printed copies.
>  


Re: Git plugin trigger of downstream is not building same branch

2012-08-20 Thread Sami Tikka
I think the git plugin sets GIT_BRANCH environment variable, so you could e.g. 
write it to a .properties file and use parameterized trigger to pass it to 
another build. 

-- Sami

Allen Bierbaum  kirjoitti 20.8.2012 kello 18.16:

> On Sun, Aug 19, 2012 at 1:11 PM, Sami Tikka  wrote:
>> I think it depends on how you have configured the two jobs. Jenkins does not 
>> carry any sort of hidden message about git branch from build to another 
>> build.
>> 
> 
> That was the key piece of information I needed.  I think I need to use
> the parameterized trigger plugin so I can pass the git commit to use
> from one build to the other.  This causes a bit of an issue because it
> means the GIT_BRANCH won't be passed from build A to build B; meaning
> the build name and some of the build scripts won't have the correct
> branch information.  I will try to find a way to work around this
> though.
> 
>> Maybe you could share the job configurations with the list? Could you put 
>> them up on pastebin or gist for us to see? You can get the job configuration 
>> by downloading $JENKINS_URL/job/JOBNAME/config.xml
>> 
> 
> I think I have the information I need for now.  I will keep it in mind
> for future questions though and post this information.
> 
> Thanks for your help with my questions.  It has been very helpful.
> 
> -Allen
> 
> 
>> -- Sami
>> 
>> Allen Bierbaum  kirjoitti 19.8.2012 kello 15.36:
>> 
>>> I had the same thought but was hoping for something more concrete to
>>> track down or fix.
>>> 
>>> Just to be clear then, if a build using git triggers a downstream
>>> build using "Build other projects" as a post build action then the
>>> downstream build should build the same branch as the upstream?
>>> 
>>> -Allen
>>> 
>>> 
>>> On Sat, Aug 18, 2012 at 2:58 PM, Sami Tikka  wrote:
>>>> Maybe something has changed? Someone upgraded some Jenkins plugin or 
>>>> installed a new one or changed something in the job configuration.
>>>> 
>>>> I happen to know if you install the Workspace Cleanup plugin and configure 
>>>> a job to use it, it deletes the workspace and that somehow causes git 
>>>> plugin to get confused about which changes it has already seen and often 
>>>> it starts building the wrong branch.
>>>> 
>>>> -- Sami
>>>> 
>>>> Allen Bierbaum  kirjoitti 18.8.2012 kello 14.42:
>>>> 
>>>>> Our jenkins build process has been stable and working with no problems
>>>>> for the last 6 months or so.  We have a build monitor job that polls
>>>>> our git repository looking for changes and then triggers downstream
>>>>> jobs to build the given branch (using "Build other projects" post
>>>>> build action).  This allows us to queue up multiple build jobs run
>>>>> against the same git branch at the same time.  We do it this way to
>>>>> work around this known issue
>>>>> (https://issues.jenkins-ci.org/browse/JENKINS-7423) and to make sure
>>>>> we get all the builds we need.
>>>>> 
>>>>> This has been working well, but sometime in the last 2 weeks it
>>>>> stopped working.  What we are seeing now is that the monitoring job
>>>>> sees a change on a branch (ex: dev/new_featureA) but when it triggers
>>>>> the downstream job, that job normally picks up a different branch to
>>>>> build (ex: dev/new_featureB).
>>>>> 
>>>>> Has anyone else seen this behavior?  Is it expected?
>>>>> 
>>>>> Note we have also tried using the parameterized trigger plugin to pass
>>>>> the exact SHA hash to the downstream build.  This does force the
>>>>> correct commit to build, but it uses a detached HEAD, so we don't end
>>>>> up with a valid GIT_BRANCH environment variable during the build.  We
>>>>> use the branch name as part of our build process (and as part of our
>>>>> build name) so this doesn't work well for us either.  If there was a
>>>>> way to have the parameterized trigger pass along the correct
>>>>> GIT_BRANCH environment variable then this option would probably work
>>>>> great.
>>>>> 
>>>>> -Allen
>>>> 
>> 


Re: Selenium crashes Chrome when running from Jenkins

2012-08-20 Thread Sami Tikka
I think the story goes there is a bug in OS X that allows some access to 
windowserver but not to all the services that would make a fully functional 
application. 

-- Sami

Liron Yahdav  kirjoitti 20.8.2012 kello 21.30:

> Thanks Sami, that fixed the issue! We configured Jenkins to run as a launch 
> agent. It was just strange that when running as a launch daemon it would 
> start up Chrome and I would see the window for Chrome, but it would go to the 
> "aw, snap" error page in Chrome. I would think that if there were no access 
> to the window server it wouldn't even display the window. I just don't know 
> much about daemons and window servers on OS X. Anyway, thanks again.
> 
> Liron
> 
> On Thursday, August 9, 2012 9:56:49 PM UTC-7, sti wrote:
> Unless you have changed the configuration by hand, the native OS X package 
> sets up Jenkins as a launch daemon. Launch daemons have no access to window 
> server, thus they are unable to display windows, like chrome. 
> 
> You must run Jenkins as a launch agent or use 
> https://github.com/stisti/jenkins-app
> 
> -- Sami
> 
> Liron Yahdav  kirjoitti 8.8.2012 kello 3.15:
> 
>> I installed it using the Mac OS X native package link from the 
>> http://jenkins-ci.org/ homepage.
>> 
>> On Tuesday, August 7, 2012 2:01:02 PM UTC-7, sti wrote:
>> And how did you install Jenkins? 
>> 
>> -- Sami 
>> 
>> Liron Yahdav  kirjoitti 6.8.2012 kello 20.31: 
>> 
>> > TLDR: Running ruby scripts from Jenkins on OS X that use the 
>> > selenium-webdriver gem with chromedriver causes the "Aw snap" page to come 
>> > up in Chrome. Running those same scripts from outside of Jenkins works 
>> > fine. Any ideas as to what's wrong? 
>> > 
>> > -- 
>> > 
>> > Long version: 
>> > We have a CI machine that's a MacBook Pro running OS X Mountain Lion with 
>> > Jenkins installed. The Jenkins server runs as a user who can login to the 
>> > system. We configured Jasmine to use Chrome for the `rake jasmine:ci` 
>> > command by setting ENV['JASMINE_BROWSER'] = 'chrome'. This all works fine 
>> > when running `rake jasmine:ci` from the command line on that machine, but 
>> > when Jenkins is configured to run the same exact command, Chrome will 
>> > start up and when it tries to hit the url to run the tests, the tab 
>> > crashes with the "Aw Snap" error page. I looked at the chromedriver.log 
>> > file that's generated and there are no errors, it basically just stops all 
>> > of a sudden. The Jenkins build eventually gets a Selenium timeout error. 
>> > I've tried setting up the same config on a MacBook Air running OS X Lion 
>> > and the same problem occurs. 
>> > We also have integration tests written with RSpec and Capybara and when we 
>> > configure it to use Selenium with chromedriver, the same problem occurs 
>> > when running through Jenkins, though the "Aw Snap" page comes up a few 
>> > steps into the first test. 
>> > 
>> > Has anyone gotten a similar setup working or have any idea what the issue 
>> > could be? Thanks! 
>> > 
>> 


Re: Git plugin trigger of downstream is not building same branch

2012-08-19 Thread Sami Tikka
I think it depends on how you have configured the two jobs. Jenkins does not 
carry any sort of hidden message about git branch from build to another build.

Maybe you could share the job configurations with the list? Could you put them 
up on pastebin or gist for us to see? You can get the job configuration by 
downloading $JENKINS_URL/job/JOBNAME/config.xml

-- Sami

Allen Bierbaum  kirjoitti 19.8.2012 kello 15.36:

> I had the same thought but was hoping for something more concrete to
> track down or fix.
> 
> Just to be clear then, if a build using git triggers a downstream
> build using "Build other projects" as a post build action then the
> downstream build should build the same branch as the upstream?
> 
> -Allen
> 
> 
> On Sat, Aug 18, 2012 at 2:58 PM, Sami Tikka  wrote:
>> Maybe something has changed? Someone upgraded some Jenkins plugin or 
>> installed a new one or changed something in the job configuration.
>> 
>> I happen to know if you install the Workspace Cleanup plugin and configure a 
>> job to use it, it deletes the workspace and that somehow causes git plugin 
>> to get confused about which changes it has already seen and often it starts 
>> building the wrong branch.
>> 
>> -- Sami
>> 
>> Allen Bierbaum  kirjoitti 18.8.2012 kello 14.42:
>> 
>>> Our jenkins build process has been stable and working with no problems
>>> for the last 6 months or so.  We have a build monitor job that polls
>>> our git repository looking for changes and then triggers downstream
>>> jobs to build the given branch (using "Build other projects" post
>>> build action).  This allows us to queue up multiple build jobs run
>>> against the same git branch at the same time.  We do it this way to
>>> work around this known issue
>>> (https://issues.jenkins-ci.org/browse/JENKINS-7423) and to make sure
>>> we get all the builds we need.
>>> 
>>> This has been working well, but sometime in the last 2 weeks it
>>> stopped working.  What we are seeing now is that the monitoring job
>>> sees a change on a branch (ex: dev/new_featureA) but when it triggers
>>> the downstream job, that job normally picks up a different branch to
>>> build (ex: dev/new_featureB).
>>> 
>>> Has anyone else seen this behavior?  Is it expected?
>>> 
>>> Note we have also tried using the parameterized trigger plugin to pass
>>> the exact SHA hash to the downstream build.  This does force the
>>> correct commit to build, but it uses a detached HEAD, so we don't end
>>> up with a valid GIT_BRANCH environment variable during the build.  We
>>> use the branch name as part of our build process (and as part of our
>>> build name) so this doesn't work well for us either.  If there was a
>>> way to have the parameterized trigger pass along the correct
>>> GIT_BRANCH environment variable then this option would probably work
>>> great.
>>> 
>>> -Allen
>> 



Re: Git plugin trigger of downstream is not building same branch

2012-08-18 Thread Sami Tikka
Maybe something has changed? Someone upgraded some Jenkins plugin or installed 
a new one or changed something in the job configuration.

I happen to know if you install the Workspace Cleanup plugin and configure a 
job to use it, it deletes the workspace and that somehow causes git plugin to 
get confused about which changes it has already seen and often it starts 
building the wrong branch.

-- Sami

Allen Bierbaum  kirjoitti 18.8.2012 kello 14.42:

> Our jenkins build process has been stable and working with no problems
> for the last 6 months or so.  We have a build monitor job that polls
> our git repository looking for changes and then triggers downstream
> jobs to build the given branch (using "Build other projects" post
> build action).  This allows us to queue up multiple build jobs run
> against the same git branch at the same time.  We do it this way to
> work around this known issue
> (https://issues.jenkins-ci.org/browse/JENKINS-7423) and to make sure
> we get all the builds we need.
> 
> This has been working well, but sometime in the last 2 weeks it
> stopped working.  What we are seeing now is that the monitoring job
> sees a change on a branch (ex: dev/new_featureA) but when it triggers
> the downstream job, that job normally picks up a different branch to
> build (ex: dev/new_featureB).
> 
> Has anyone else seen this behavior?  Is it expected?
> 
> Note we have also tried using the parameterized trigger plugin to pass
> the exact SHA hash to the downstream build.  This does force the
> correct commit to build, but it uses a detached HEAD, so we don't end
> up with a valid GIT_BRANCH environment variable during the build.  We
> use the branch name as part of our build process (and as part of our
> build name) so this doesn't work well for us either.  If there was a
> way to have the parameterized trigger pass along the correct
> GIT_BRANCH environment variable then this option would probably work
> great.
> 
> -Allen



Re: Exception shown at windows slave console during restart of tomcat

2012-08-17 Thread Sami Tikka
What does your ant task do? Did you read the wiki page mentioned in the error? 
Did the you follow the advice over there? 

-- Sami

Varghese Renny  kirjoitti 16.8.2012 kello 13.43:

> 
> Hi,
>i am getting an exception at slave console while stoping and starting 
> tomcat using ant task..
>How to resolve this error? Any other method i can use for starting and 
> stoping tomcat ?
> 
>  Aug 15, 2012 2:46:53 AM hudson.Proc$LocalProc join
>WARNING: Process leaked file descriptors. See 
> http://wiki.jenkins-ci.org/display
>/JENKINS/Spawning+processes+from+build for more information
>java.lang.Exception
> at hudson.Proc$LocalProc.join(Proc.java:329)
> at hudson.Launcher$RemoteLaunchCallable$1.join(Launcher.java:937)
> at sun.reflect.GeneratedMethodAccessor216.invoke(Unknown Source)
> at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>   sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:597)
> at 
> hudson.remoting.RemoteInvocationHandler$RPCRequest.perform(RemoteInvo
>   cationHandler.java:274)
> at 
> hudson.remoting.RemoteInvocationHandler$RPCRequest.call(RemoteInvocat
>   ionHandler.java:255)
> at 
> hudson.remoting.RemoteInvocationHandler$RPCRequest.call(RemoteInvocat
>   ionHandler.java:215)
> at hudson.remoting.UserRequest.perform(UserRequest.java:118)
> at hudson.remoting.UserRequest.perform(UserRequest.java:48)
> at hudson.remoting.Request$2.run(Request.java:287)
> at 
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:44
>1)
> 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(ThreadPoolExec
>   utor.java:886)
> at 
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor
>.java:908)
> at hudson.remoting.Engine$1$1.run(Engine.java:60)
> at java.lang.Thread.run(Thread.java:619)
> 
> 
> Thanks in Advance,
> varghese



Re: Need help getting a sample scriptler groovy script to run on a slave.

2012-08-17 Thread Sami Tikka
You're not being too forthcoming with what you want to accomplish, so this may 
not help you much:

Like it says in the System Groovy Script build step, system Groovy script 
always executes on the master. The "system Groovy" actually executes inside of 
Jenkins, in the same vm, so system Groovy can do many of the same things as a 
plugin can.

If you want to run a Groovy script on the slave, you need to use the "Execute 
Groovy Script" build step and then, if the job is set to execute on a slave, 
Jenkins will really spawn the Groovy process in the slave.

-- Sami

Damon G  kirjoitti 16.8.2012 kello 15.22:

> Hi There,
>I've been playing with the groovy plugin and I'm able to run a few sample 
> groovy scripts on the master using the system groovy script option in the 
> job. However I can't seem to get the same code to execute on the slave by 
> executing a groovy script or by using the scriptler plugin. Even a simple 
> "println" statement doesn't work. For instance:
> 
> import hudson.model.*
> prinln("hello!!!")
> 
> results in:
> 
> Execution of script [test.groovy] failed - Unable to serialize 
> org.jenkinsci.plugins.scriptler.util.GroovyScript@75f0ab39Build step 
> 'Scriptler script' marked build as failure
> 
> I get the same thing if I just do prinln("hello!!!") and leave out the import 
> statement.
> 
> I have groovy installed on the slave but I must be missing something. When I 
> execute on the slave do I need something additional in my classpath? I didn't 
> seem to need anything explicit in my classspath to run this as a system 
> groovy script on the master.
> 
> Does anyone have simple example config to share? I think I must be missing 
> something fairly basic here.
> 
> Thanks!
> 
> 
> 



Re: Build Promotion and Copy Artifact: current build is overwritten

2012-08-17 Thread Sami Tikka
Some things you need to understand about the promoted builds:

The promotions are kind of like 2nd class citizens in the Jenkins job 
population: They are subservient to their parent job and they do not have their 
own workspace.

This means that you should not do anything in the promotion actions that uses 
the workspace. Or if you do, you have the responsibility of synchronizing the 
workspace access with the promotion and the parent job.

If your promotion actions need to use a workspace, it is often easier to just 
trigger a build of another job. This other job would be a normal job, which 
means it would have its own workspace and it would be safe to use it.

-- Sami

Martin d'Anjou  kirjoitti 16.8.2012 kello 17.45:

> Hi,
> 
> When I promote an archived build while a build is running, the Copy
> Artifact plugin overwrites the running build artifacts with the
> archived ones. How should I configure the Build Promotion and the Copy
> Artifact to avoid this problem?
> 
> Thanks,
> Martin



Re: Confusion over build triggers

2012-08-17 Thread Sami Tikka
As far as I understand, the standard triggering of other projects from 
post-build actions does what you want. 

Go into A's configuration: Add post-build action -> Build other projects. Enter 
project name B, choose "Trigger only if build succeeds".

If it doesn't, maybe you could be even more specific with your description?

-- Sami

mwpowellhtx  kirjoitti 17.8.2012 kello 13.00:

> Hello,
> 
> In test and measurement verbiage, I think of a trigger as just that: see an 
> event, respond to that event.
> 
> Say we have two jobs: A and B.
> 
> A runs when it sees SCM change and builds that environment.
> 
> I'd like to schedule B when A has successfully completed a build and build 
> the same environment but in a different configuration, possibly run some 
> tests, etc.
> 
> I don't want to look for the most recent build as it could be stale: hours, 
> even days or weeks old. Only when A is actually running, and runs to 
> completion.
> 
> How to explain exactly? Hard to do so unless you're familiar with the 
> pattern: trigger, particularly as I am accustomed to talking about it, i.e. 
> T&M.
> 
> Is there anything in the Jenkins plugin world that can do this? Or are we 
> stuck with a chained build setup in A?
> 
> Thanks in advance.



Re: How to install slave to a machine which doesn't have a JVM?

2012-08-15 Thread Sami Tikka
Then you cannot run the slave on that machine. You just have to run the tests 
using some other method and copy the results back to a Jenkins job workspace. 

-- Sami

Renlong Zhang  kirjoitti 15.8.2012 kello 6.36:

> Hi all,
> 
> I have to run test cases in a machine and this machine can not install a JRE, 
> Is it possible to install the jenkins slave to this machine?
> 
> If it is not possible, should I have to design an TCP/IP application to 
> communicate with the Jenkins server and the machine to run the job in the 
> machine?
> 
> Is there any easy and simply way to deal with this issue?
> 
> 
> BR,
> 
> Simon


Re: Build with for loop like finesse

2012-08-15 Thread Sami Tikka
So assign the jobs to run on a slave with only 1 executor. I guarantee only one 
at a time will run.

-- Sami

rusty  kirjoitti 14.8.2012 kello 19.54:

> The problem is that I can have no concurrency in between the two top projects 
> nor any child projects that they have.  I have looked at throttle builds  
> plugin, but it doesn't provide what I need which is full atomicity on the top 
> level builds and all recursive underlying builds.  
> 
> On Tuesday, August 14, 2012 10:37:05 AM UTC-6, sti wrote:
> All the builds will enter the queue at the same time, but how many will 
> actually run in parallel depends on how many executors you have or if you 
> have used other means of concurrency control like Throttle Concurrent Builds 
> plugin. 
> 
> -- Sami
> 
> rusty  kirjoitti 14.8.2012 kello 
> 19.26:
> 
>> 
>> I am already using a multi-configuration project, I think that the 
>> disconnect is stemming from how do I use multiple axis to accompolish this.
>> 
>> Won't adding another axis start the two projects in parallel?  I can't have 
>> two projects in paralelll...
>> 
>> On Tuesday, August 14, 2012 3:06:38 AM UTC-6, sti wrote:
>> Use a multi-configuration project with one, two or more axes. 
>> 
>> -- Sami 
>> 
>> rusty  kirjoitti 14.8.2012 kello 
>> 5.39: 
>> 


Re: Windows installation - cannot be configured - jobs page loading shown

2012-08-14 Thread Sami Tikka
Which version of Jenkins you are running?

-- Sami

Kenneth  kirjoitti 14.8.2012 kello 15.36:

> Hi Guru's
> I'v jeg trying to konfigure my jenkins to have a job monitoring three of 
> several projects checked into subversion.
> and build it with ms build. (using .net 2.0 & c#)
> after that I would like to run NUnit test on a project.
>  
> But when I try to configure the job, the top of the page is grayed out, and 
> states that it is loading.
>  
> anybody have a clue?
>  
> thanks
> Kennetb
>  


Re: Return value of a command in shell script != 0 stops build

2012-08-14 Thread Sami Tikka
If you begin the build step with a line that starts with #!, Jenkins will 
assume you want to specify the interpreter instead of using /bin/sh -xe, which 
is the default. It is the -e switch of the shell which is responsible for 
aborting the script when a command exits with error. 

You could place "#!/bin/sh -x" on the first line (without the quotes). But 
remember to watch for errors yourself, then. 

-- Sami

natalie_pub...@gmx.net kirjoitti 14.8.2012 kello 18.49:

> Hi there,
> 
> I'm using Jenkins to build a C++ project on Solaris 10.
> 
> To set up the environment I'm calling various shell scripts, of which one 
> contains the following code:
> --
> for P in /usr/contrib/bin /usr/local/bin
> do
>cd $P > /dev/null 2>&1
>if [ $? -eq 0 ] 
>then
>// XYZ
>echo $P
>fi
> done
> -- 
> 
> The directory "/usr/contrib/bin" does not exist. This makes the return value 
> in line 3 (cd $P > /dev/null 2>&1) negative and Jenkins stops the build 
> because it appears to be "failed".
> 
> In the job configuration, section "Build shell" it already says that the 
> build is considered failed if one of the commands returns <> 0.
> 
> This script has been used for compilation by many other projects for long 
> time, so I don't really want to change it.
> 
> Is there any workaround or solution to this behaviour (except to create this 
> directory)?
> 
> Regards,
> Natalie


Re: Build with for loop like finesse

2012-08-14 Thread Sami Tikka
All the builds will enter the queue at the same time, but how many will 
actually run in parallel depends on how many executors you have or if you have 
used other means of concurrency control like Throttle Concurrent Builds plugin. 

-- Sami

rusty  kirjoitti 14.8.2012 kello 19.26:

> 
> I am already using a multi-configuration project, I think that the disconnect 
> is stemming from how do I use multiple axis to accompolish this.
> 
> Won't adding another axis start the two projects in parallel?  I can't have 
> two projects in paralelll...
> 
> On Tuesday, August 14, 2012 3:06:38 AM UTC-6, sti wrote:
> Use a multi-configuration project with one, two or more axes. 
> 
> -- Sami 
> 
> rusty  kirjoitti 14.8.2012 kello 
> 5.39: 
> 


Re: Build with for loop like finesse

2012-08-14 Thread Sami Tikka
Use a multi-configuration project with one, two or more axes.

-- Sami

rusty  kirjoitti 14.8.2012 kello 5.39:

> PROBLEM:   I need to build a project with certain parameters which then kicks 
> of various other projects.  I then need to build the same first project with 
> a different set of parameters as  soon as the full build pipeline finishes 
> from the original build. 
> 
> eg: 
> 
> project1 with first set of parameters: 
> project2: 
> project3: 
> project4: 
> project5: 
> project6: 
> project7: 
> project1 with second set of parameters: 
> project2: 
> project3: 
> project4: 
> project5: 
> project6: 
> project7: 
> 
> Note that all children projects depend on parameters passed down from 
> project1 and that due to lack of hardware, I cannot build the two different 
> project1's in parallel. 
> 
> QUESTION:  How do I accomplish top level builds that spawn of a plethora of 
> children projects and then be able to spawn another top level build when the 
> current top level build, and all children builds including project6 from my 
> example, has finished?
> 


Re: While running UI tests on Jenkins slave, session gets disconnected.

2012-08-13 Thread Sami Tikka
With the limited details you provide all I can advice is: try not to close the 
slave agent or kill its network connection. 

If you want better advice, you need to provide more details. In general, the 
slave agent does not lose connection in the middle of builds. 

-- Sami

Manoj Attal  kirjoitti 13.8.2012 kello 12.43:

> I have set up Jenkins slave and masters on windows machines. I have set up 
> Jenkins slave using JNLP(Java  web smart) mode. On jenkins slave I am 
> performing set up of application and then it perform some UI tests. The issue 
> is that Jenkins slave automatically gets disconnected after few minutes. So 
> tests that we are running get failed. Even execution of set up haults where 
> it was while session was disconnected. How can I make sure that slave works 
> correctly without interruption in session?


Re: Mail Watcher Plugin not showing in "available plugins" (was: email notification when node falls offline?)

2012-08-13 Thread Sami Tikka
The plugin requires a newer Jenkins than you are running?

-- Sami

Chris Withers  kirjoitti 13.8.2012 kello 12.34:

> On 13/08/2012 09:24, oliver gondža wrote:
>>> How can I get Jenkins to email me when any node falls offline?
>>> (as it blocks a whole load of builds, but I don't get any notification
>>> of those...)
>>> 
>> Hi, This plugin might be doing what you need (watching Node online status).
>> 
>> https://wiki.jenkins-ci.org/display/JENKINS/Mail+Watcher+Plugin
> 
> Yep, looks ideal, but it doesn't show in my "Available Plugins" section (on 
> either of the Jenkins installs I have access to).
> 
> Why might that be?
> 
> cheers,
> 
> Chris
> 
> -- 
> Simplistix - Content Management, Batch Processing & Python Consulting
>- http://www.simplistix.co.uk


Re: Issue getting RVM working

2012-08-13 Thread Sami Tikka
Is this a Jenkins issue at all? Does it work when you try it as Jenkins user 
with the same environment? Note, Jenkins might not have the same environment 
vars as a logged in user, depending on your platform and where the vars are 
set. 

-- Sami

de Herdt Arne  kirjoitti 13.8.2012 kello 
9.56:

> Ok,
> 
> I managed to get a bit further now. The RVM issue is gone, but I still 
> receive errors when trying to run my configuration.
> This is the output from console:
> 
> Building in workspace /var/lib/jenkins/workspace/Ruby_Example
> Checkout:Ruby_Example / /var/lib/jenkins/workspace/Ruby_Example - 
> hudson.remoting.LocalChannel@73ae0c9d
> Using strategy: Default
> Last Built Revision: Revision 2d34e939cd57cc5c27d1762d3b93560be95e2033 
> (origin/HEAD, origin/master)
> Fetching changes from 1 remote Git repository
> Fetching upstream changes from 
> Seen branch in repository origin/HEAD
> Seen branch in repository origin/master
> Commencing build of Revision 2d34e939cd57cc5c27d1762d3b93560be95e2033 
> (origin/HEAD, origin/master)
> Checking out Revision 2d34e939cd57cc5c27d1762d3b93560be95e2033 (origin/HEAD, 
> origin/master)
> Warning : There are multiple branch changesets here
> Capturing environment variables produced by 'rvm use 1.9.3'
> $ bash -c export
> $ bash -c "test ! -f ~/.rvm/scripts/rvm"
> [Ruby_Example] $ bash -c "source ~/.rvm/scripts/rvm && 
> rvm_install_on_use_flag=1 && rvm use --create 1.9.3 && export > rvm.env"
> Using /usr/local/rvm/gems/ruby-1.9.3-p194
> Running /usr/local/rvm/hooks/after_use
> [Ruby_Example] $ ruby -v /tmp/hudson3490064438898025857.rb
> ruby 1.9.3p194 (2012-04-20 revision 35410) [x86_64-linux]
> /tmp/hudson3490064438898025857.rb:1:in `': undefined local variable or 
> method `install' for main:Object (NameError)
> Build step 'Execute Ruby script' marked build as failure
> Finished: FAILURE
> 
> He seems to be doing something with after_hooks, but I don't know where this 
> comes from.
> 
> --
> Arne
> 
> -Original Message-
> From: jenkinsci-users@googlegroups.com 
> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of de Herdt Arne
> Sent: Montag, 13. August 2012 08:22
> To: jenkinsci-users@googlegroups.com
> Subject: RE: Issue getting RVM working
> 
> Tyler,
> 
> Thanks for the reply. I will give this a spin and see if I can get it working 
> then.
> 
> Arne De Herdt
> 
> -Original Message-
> From: jenkinsci-users@googlegroups.com 
> [mailto:jenkinsci-users@googlegroups.com] On Behalf Of R. Tyler Croy
> Sent: Freitag, 10. August 2012 19:05
> To: jenkinsci-users@googlegroups.com
> Subject: Re: Issue getting RVM working
> 
> 
> On Thu, 09 Aug 2012, de Herdt Arne wrote:
> 
>> Hello,
>> 
>> I'm currently in the process of setting up a Jenkins instance on Debian to 
>> have our team play around and see how we can work with Jenkins.
>> I have configured a Ruby plan that is able to checkout the source from our 
>> git, the problem is getting the ruby tests running. It keeps getting stuck 
>> on RVM, and I have no idea what is going wrong.
>> 
>> When I log in manually on the box, RVM etc is all working, but this is what 
>> I get in the log output of the Jenkins project:
> 
> 
> It sounds like you've not up RVM for the Jenkins user specifically. The 
> script is failing to find "/var/lib/jenkins/.rvm/scripts/rvm", where 
> "/var/lib/jenkins" is the Jenkins user's home directory.
> 
> 
> You might try sudo'ing to the `jenkins` user and installing RVM there
> 
> 
> - R. Tyler Croy
> --
>Code: http://github.com/rtyler
> Chatter: http://twitter.com/agentdero
>  rty...@jabber.org


Re: Selenium crashes Chrome when running from Jenkins

2012-08-09 Thread Sami Tikka
Unless you have changed the configuration by hand, the native OS X package sets 
up Jenkins as a launch daemon. Launch daemons have no access to window server, 
thus they are unable to display windows, like chrome. 

You must run Jenkins as a launch agent or use 
https://github.com/stisti/jenkins-app

-- Sami

Liron Yahdav  kirjoitti 8.8.2012 kello 3.15:

> I installed it using the Mac OS X native package link from the 
> http://jenkins-ci.org/ homepage.
> 
> On Tuesday, August 7, 2012 2:01:02 PM UTC-7, sti wrote:
> And how did you install Jenkins? 
> 
> -- Sami 
> 
> Liron Yahdav  kirjoitti 6.8.2012 kello 20.31: 
> 
> > TLDR: Running ruby scripts from Jenkins on OS X that use the 
> > selenium-webdriver gem with chromedriver causes the "Aw snap" page to come 
> > up in Chrome. Running those same scripts from outside of Jenkins works 
> > fine. Any ideas as to what's wrong? 
> > 
> > -- 
> > 
> > Long version: 
> > We have a CI machine that's a MacBook Pro running OS X Mountain Lion with 
> > Jenkins installed. The Jenkins server runs as a user who can login to the 
> > system. We configured Jasmine to use Chrome for the `rake jasmine:ci` 
> > command by setting ENV['JASMINE_BROWSER'] = 'chrome'. This all works fine 
> > when running `rake jasmine:ci` from the command line on that machine, but 
> > when Jenkins is configured to run the same exact command, Chrome will start 
> > up and when it tries to hit the url to run the tests, the tab crashes with 
> > the "Aw Snap" error page. I looked at the chromedriver.log file that's 
> > generated and there are no errors, it basically just stops all of a sudden. 
> > The Jenkins build eventually gets a Selenium timeout error. 
> > I've tried setting up the same config on a MacBook Air running OS X Lion 
> > and the same problem occurs. 
> > We also have integration tests written with RSpec and Capybara and when we 
> > configure it to use Selenium with chromedriver, the same problem occurs 
> > when running through Jenkins, though the "Aw Snap" page comes up a few 
> > steps into the first test. 
> > 
> > Has anyone gotten a similar setup working or have any idea what the issue 
> > could be? Thanks! 
> > 
> 


  1   2   3   4   >