Understanding Console Output

171 views
Skip to first unread message

Steve Berg

unread,
Jun 5, 2012, 2:21:09 PM6/5/12
to jenkins...@googlegroups.com
Where can I find how to understand the Console Output from a Jenkins build?  I have this:
 
Started by timer
Building in workspace /var/lib/jenkins/jobs/TestingJenkins/workspace
Updating https://lstf.vzbi.com/svn/repos/mis/TeamForge/JenkinsTest
At revision 2029
no change for https://lstf.vzbi.com/svn/repos/mis/TeamForge/JenkinsTest since the previous build
[workspace] $ cmd /c call /tmp/hudson32454.bat
FATAL: command execution failed
java.io.IOException: java.io.IOException: cmd: not found
	at java.lang.UNIXProcess.<init>(UNIXProcess.java:148)
	at java.lang.ProcessImpl.start(ProcessImpl.java:65)
	at java.lang.ProcessBuilder.start(ProcessBuilder.java:451)
	at hudson.Proc$LocalProc.<init>(Proc.java:244)
	at hudson.Proc$LocalProc.<init>(Proc.java:216)
	at hudson.Launcher$LocalLauncher.launch(Launcher.java:709)
	at hudson.Launcher$ProcStarter.start(Launcher.java:338)
	at hudson.Launcher$ProcStarter.join(Launcher.java:345)
	at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:82)
	at hudson.tasks.CommandInterpreter.perform(CommandInterpreter.java:58)
	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
	at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:710)
	at hudson.model.Build$RunnerImpl.build(Build.java:178)
	at hudson.model.Build$RunnerImpl.doRun(Build.java:139)
	at hudson.model.AbstractBuild$AbstractRunner.run(AbstractBuild.java:480)
	at hudson.model.Run.run(Run.java:1438)
	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
	at hudson.model.ResourceController.execute(ResourceController.java:88)
	at hudson.model.Executor.run(Executor.java:239)
Build step 'Execute Windows batch command' marked build as failure
Sending e-mails to: ...
ERROR: Could not connect to SMTP host: localhost, port: 25
javax.mail.MessagingException: Could not connect to SMTP host: localhost, port: 25;
  nested exception is:
	java.net.SocketTimeoutException: connect timed out
	at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1934)
	at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:638)
	at javax.mail.Service.connect(Service.java:295)
	at javax.mail.Service.connect(Service.java:176)
	at javax.mail.Service.connect(Service.java:125)
	at javax.mail.Transport.send0(Transport.java:194)
	at javax.mail.Transport.send(Transport.java:124)
	at hudson.tasks.MailSender.execute(MailSender.java:114)
	at hudson.tasks.Mailer.perform(Mailer.java:111)
	at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:19)
	at hudson.model.AbstractBuild$AbstractRunner.perform(AbstractBuild.java:710)
	at hudson.model.AbstractBuild$AbstractRunner.performAllBuildSteps(AbstractBuild.java:685)
	at hudson.model.Build$RunnerImpl.post2(Build.java:162)
	at hudson.model.AbstractBuild$AbstractRunner.post(AbstractBuild.java:632)
	at hudson.model.Run.run(Run.java:1463)
	at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46)
	at hudson.model.ResourceController.execute(ResourceController.java:88)
	at hudson.model.Executor.run(Executor.java:239)
Caused by: java.net.SocketTimeoutException: connect timed out
	at java.net.PlainSocketImpl.socketConnect(Native Method)
	at java.net.PlainSocketImpl.doConnect(PlainSocketImpl.java:333)
	at java.net.PlainSocketImpl.connectToAddress(PlainSocketImpl.java:195)
	at java.net.PlainSocketImpl.connect(PlainSocketImpl.java:182)
	at java.net.SocksSocketImpl.connect(SocksSocketImpl.java:366)
	at java.net.Socket.connect(Socket.java:519)
	at com.sun.mail.util.SocketFetcher.createSocket(SocketFetcher.java:286)
	at com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:231)
	at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1900)
	... 17 more
Finished: FAILURE

Les Mikesell

unread,
Jun 5, 2012, 2:29:49 PM6/5/12
to jenkins...@googlegroups.com
On Tue, Jun 5, 2012 at 1:21 PM, Steve Berg <steve...@verizon.com> wrote:
> Where can I find how to understand the Console Output from a Jenkins build?
> I have this:
>
> Building in workspace /var/lib/jenkins/jobs/TestingJenkins/workspace

That looks like a linux system.

> [workspace] $ cmd /c call /tmp/hudson32454.bat
> FATAL: command execution failed
> java.io.IOException: java.io.IOException: cmd: not found

But you are trying to execute a windows batch file.

> Build step 'Execute Windows batch command' marked build as failure
> Sending e-mails to: ...
> ERROR: Could not connect to SMTP host: localhost, port: 25
> javax.mail.MessagingException: Could not connect to SMTP host: localhost,

And you don't have a working mail service to deliver the email about it.

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

Steve Berg

unread,
Jun 5, 2012, 2:39:44 PM6/5/12
to jenkins...@googlegroups.com
Thank you, Les.  I'm new to Jenkins but beginning to make some progress.  Yes, this is a linux system (CentOS).  Where can I learn about commands to execute builds on linux?  (I'll talk to our network guy about the mail service.)

Les Mikesell

unread,
Jun 5, 2012, 2:48:23 PM6/5/12
to jenkins...@googlegroups.com
On Tue, Jun 5, 2012 at 1:39 PM, Steve Berg <steve...@verizon.com> wrote:
> Thank you, Les.  I'm new to Jenkins but beginning to make some progress.
> Yes, this is a linux system (CentOS).  Where can I learn about commands to
> execute builds on linux?  (I'll talk to our network guy about the mail
> service.)

The command to execute would depend on the language and type of build
job. For the general case you can supply a shell script with whatever
commands you need in the same way batch files might be used in
windows. For a C program 'make' might be all you need, or java might
have an ant build.

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

Steve Berg

unread,
Jun 5, 2012, 2:52:02 PM6/5/12
to jenkins...@googlegroups.com
It's a C# program.  The only experience I have building C# programs is in Visual Studio.  Jenkins is pulling the source from Subversion.

Les Mikesell

unread,
Jun 5, 2012, 3:01:35 PM6/5/12
to jenkins...@googlegroups.com
On Tue, Jun 5, 2012 at 1:52 PM, Steve Berg <steve...@verizon.com> wrote:
> It's a C# program.  The only experience I have building C# programs is in
> Visual Studio.  Jenkins is pulling the source from Subversion.

Can't help much with that: http://mono-project.com/MoMA.

Unless maybe you want to add a windows slave to jenkins to automate
your windows builds instead of making a linux port.

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

Alex Earl

unread,
Jun 5, 2012, 3:03:04 PM6/5/12
to Steve Berg, jenkins...@googlegroups.com
You may want to look at the msbuild plugin, it should work with dbuikd which is the mono implementation of msbuild. You'd need to install mono and build for sure.

Sent from my Windows Phone

From: Steve Berg
Sent: 6/5/2012 11:52 AM
To: jenkins...@googlegroups.com
Subject: Re: Understanding Console Output

It's a C# program.  The only experience I have building C# programs is in Visual Studio.  Jenkins is pulling the source from Subversion.
On Tuesday, June 5, 2012 1:48:23 PM UTC-5, LesMikesell wrote:

Steve Berg

unread,
Jun 5, 2012, 3:22:44 PM6/5/12
to jenkins...@googlegroups.com, Steve Berg
OK--where can I find how to use msbuild in Jenkins in a linux environment (for a C# program stored in Subversion)?

On Tuesday, June 5, 2012 2:03:04 PM UTC-5, slide wrote:
You may want to look at the msbuild plugin, it should work with dbuikd which is the mono implementation of msbuild. You'd need to install mono and build for sure.

Sent from my Windows Phone

From: Steve Berg
Sent: 6/5/2012 11:52 AM

Subject: Re: Understanding Console Output

Slide

unread,
Jun 5, 2012, 3:28:52 PM6/5/12
to jenkins...@googlegroups.com, Steve Berg
The SCM stuff is completely separate in a way, you can manage that
differently. For building a .NET application on Linux, you need to
install mono and possibly a package which contains xbuild (this will
vary depending on your distro). To use xbuild instead of msbuild, you
just need to setup the path to xbuild in the global config area for
the msbuild plugin and then select that msbuild install when you setup
the job. The msbuild plugin asks for various pieces of information for
building. I recommend trying to build your application on the command
line on Windows using msbuild to figure out what command line
parameters you need in order for it to build the application how you
want. Be warned that xbuild may not implement all of the features of
msbuild (if you find any that it doesn't, you can file an issue at
bugzilla.xamarin.com PLEASE!). For information on using xbuild see [1]
and [2]. It's been a while since I used xbuild on Linux to do this,
but it should be doable if your app doesn't have any unmanaged
components. Feel free to ask more questions as well, and if you do it
is always helpful to post build logs, and screen shots of your global
and project configs.

slide

[1] http://www.mono-project.com/Microsoft.Build
[2] http://www.mono-project.com/Porting_MSBuild_Projects_To_XBuild

On Tue, Jun 5, 2012 at 12:22 PM, Steve Berg <steve...@verizon.com> wrote:
> OK--where can I find how to use msbuild in Jenkins in a linux environment
> (for a C# program stored in Subversion)?
>
> On Tuesday, June 5, 2012 2:03:04 PM UTC-5, slide wrote:
>>
>> You may want to look at the msbuild plugin, it should work with dbuikd
>> which is the mono implementation of msbuild. You'd need to install mono and
>> build for sure.
>>
>> Sent from my Windows Phone
>> ________________________________
>> From: Steve Berg
>> Sent: 6/5/2012 11:52 AM
>> To: jenkins...@googlegroups.com
>> Subject: Re: Understanding Console Output
>>
>> It's a C# program.  The only experience I have building C# programs is in
>> Visual Studio.  Jenkins is pulling the source from Subversion.
>>
>> On Tuesday, June 5, 2012 1:48:23 PM UTC-5, LesMikesell wrote:
>>>
>>> On Tue, Jun 5, 2012 at 1:39 PM, Steve Berg <steve...@verizon.com>
>>> wrote:
>>> > Thank you, Les.  I'm new to Jenkins but beginning to make some
>>> > progress.
>>> > Yes, this is a linux system (CentOS).  Where can I learn about commands
>>> > to
>>> > execute builds on linux?  (I'll talk to our network guy about the mail
>>> > service.)
>>>
>>> The command to execute would depend on the language and type of build
>>> job.  For the general case you can supply a shell script with whatever
>>> commands you need in the same way batch files might be used in
>>> windows.   For a C program 'make' might be all you need, or java might
>>> have an ant build.
>>>
>>> --
>>>   Les Mikesell
>>>     lesmi...@gmail.com



--
Website: http://earl-of-code.com

Steve Berg

unread,
Jun 5, 2012, 3:35:04 PM6/5/12
to jenkins...@googlegroups.com, Steve Berg
Thank you, Slide.  I will need to get together with our Linux server person to work this out.
Steve
>> To: jenkinsci-users@googlegroups.com

Sami Tikka

unread,
Jun 10, 2012, 2:54:07 PM6/10/12
to jenkins...@googlegroups.com
The part of the stack trace that mentions unix process leads me to think you might be running Jenkins on a unix computer. If that is the case, you cannot execute a windows batch script.

If you really want to build on windows, you need to set up a slave on a windows computer and in the job configuration restrict the job to run only on the windows slave.

-- Sami
Reply all
Reply to author
Forward
0 new messages