TeamCity build with ClearCase view

Hi, I'm new to TeamCity. I installed TeamCity 5.1.3 and run a Build Agent on windows server with ClearCase view.
The working directory is set to be the ClearCase view directory and it has the proper pom.xml in that folder. L:\chualin_ebilling_603_build\modules
But when I ran the build it gave me the error: Cannot execute mojo: resources. It requires a project with an existing pom.xml, but the build is not using one.
Why it cannot find the pom.xml in the working folder? Is there anything I configured wrong? Please help.
Here is the whole build log below.

Build 'E-Billing 6.0.3 project :: hourly 6.0.3' #7
Started 'Fri Oct 15 12:53:12 MDT 2010' on 'slc162069' by 'you'
Finished 'Fri Oct 15 12:53:14 MDT 2010' with status 'ERROR Failure'
TeamCity URL http://slc162068.corp.siebel.com:1080/viewLog.html?buildId=7&buildTypeId=bt27

[12:53:11]: bt2
[12:53:11]: Checking for changes
[12:53:12]: Clearing temporary directory: D:\BuildAgent\temp\buildTmp
[12:53:12]: Checkout directory: D:\BuildAgent\work\42121fce523648d0
[12:53:12]: Error reading Maven project: File doesn't exist: D:\BuildAgent\work\42121fce523648d0\pom.xml
[12:53:12]: Maven project couldn't be read. Build number won't be updated
[12:53:12]: MAVEN_OPTS =  -Xmx378m -server -XX:+UseParallelGC -XX:+UseAdaptiveSizePolicy -Djava.awt.headless=true -XX:ParallelGCThreads=2 -Dteamcity.buildType.id=bt2 -Dbuild.number=7 -Dteamcity.build.properties.file=D:\BuildAgent\temp\agentTmp\teamcity.build5313216767598926011.properties -DDotNetFramework3.5_Path=C:\WINDOWS\Microsoft.NET\Framework\v3.5 "-Dteamcity.buildConfName=hourly 6.0.3" -DDotNetFramework3.0= -Dagent.work.dir=D:\BuildAgent\work -Dno.cobertura=true -DDotNetFramework1.1= -DDotNetFramework3.0_x86_Path=C:\WINDOWS\Microsoft.NET\Framework\v3.0 -DDotNetFramework3.0_x86= -DDotNetFramework3.5= -Djava.io.tmpdir=D:\BuildAgent\temp\buildTmp -DDotNetFramework1.0= -Duser.home=C:\ -Dteamcity.build.checkoutDir=D:\BuildAgent\work\42121fce523648d0 -Dagent.flow=76565539374417 -DDotNetFramework2.0= -Dfile.encoding=Cp1252 "-Dteamcity.projectName=E-Billing 6.0.3 project" "-DDotNetFrameworkSDK1.1_x86_Path=C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1" "-DDotNetFrameworkSDK1.1_Path=C:\Program Files\Microsoft Visual Studio .NET 2003\SDK\v1.1" -Didea.build.agent.port=9090 -DDotNetFramework1.1_x86_Path=C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322 -Didea.build.server.build.id=7 -DDotNetFramework2.0_x86_Path=C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 -DVS2003=7.10.6030.0 -Dteamcity.agent.dotnet.agent_url=http://localhost:9090/RPC2 -DDotNetFramework3.5_x86_Path=C:\WINDOWS\Microsoft.NET\Framework\v3.5 -Dteamcity.build.tempDir=D:\BuildAgent\temp\buildTmp -Duser.variant= -DDotNetFramework3.0_Path=C:\WINDOWS\Microsoft.NET\Framework\v3.0 "-DVS2003_Path=C:\Program Files\Microsoft Visual Studio .NET 2003\Common7\IDE" -Dos.arch=x86 -Dteamcity.dotnet.coveragelauncher=D:\BuildAgent\plugins\dotnetPlugin\bin\TeamCityRunners\JetBrains.dotTrace.TeamCity.CoverageRunner.exe -Duser.name=SYSTEM -Duser.language=en -DDotNetFrameworkSDK1.1= -Dteamcity.dotnet.nunitlauncher2.0=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher2.0.exe -Dteamcity.dotnet.nunitlauncher2.0.vsts=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher2.0.VSTS.exe -DDotNetFramework1.0_Path=C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705 -Dteamcity.runner.properties.file=D:\BuildAgent\temp\agentTmp\teamcity.runner19826938082571004.properties -Dteamcity.dotnet.nunitlauncher1.1=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher1.1.exe -DDotNetFramework1.1_x86= -DDotNetFramework3.5_x86= -DDotNetFrameworkSDK1.1_x86= -Dagent.home.dir=D:\BuildAgent -Dteamcity.agent.dotnet.build_id=7 -Dagent.name=slc162069 -Dteamcity.dotnet.platform=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.TeamCity.PlatformProcessRunner.1.1.exe -DDotNetFramework2.0_Path=C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727 -DDotNetFramework2.0_x86= -Dteamcity.build.workingDir=L:\chualin_ebilling_603_build\modules -Dteamcity.dotnet.nunitaddin=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.TeamCity.NUnitAddin-NUnit -DDotNetFramework1.0_x86= "-Dteamcity.version=5.1.3 (build 13506)" -Dteamcity.dotnet.nunitlauncher=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.NUnitLauncher.exe -Dfile.separator=\ -Dteamcity.dotnet.nunitlauncher.msbuild.task=D:\BuildAgent\plugins\dotnetPlugin\bin\JetBrains.BuildServer.MSBuildLoggers.dll -Dteamcity.auth.userId=TeamCityBuildId=7 -Dteamcity.auth.password=oNgYPYCazRulRCCWz3YvBYJJXFuFMjC4 -Duser.timezone=America/Denver "-Dos.name=Windows 2003" -Dteamcity.agent.cpuBenchmark=299 -DDotNetFramework1.1_Path=C:\WINDOWS\Microsoft.NET\Framework\v1.1.4322 -Dpath.separator=; -Dos.version=5.2 -DDotNetFramework1.0_x86_Path=C:\WINDOWS\Microsoft.NET\Framework\v1.0.3705 -Duser.country=US
[12:53:12]: M2_HOME = D:\DevTools\maven-2.0.5
[12:53:12]: PATH = D:\DevTools\maven-2.0.5\bin;C:\Oracle11gR2\BIN;C:\Oracle11gR2\BIN;D:\Perl\bin\;D:\Perl\bin;C:\Program Files\IBM\ldap\V6.0\lib;C:\Program Files\IBM\ldap\V6.0\bin;c:\oracle10gR2\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;c:\PROGRA~1\IBM\SQLLIB\BIN;c:\PROGRA~1\IBM\SQLLIB\FUNCTION;C:\Program Files\Microsoft SQL Server\80\Tools\BINN;C:\Program Files\Rational\common;C:\Program Files\Rational\ClearCase\bin;C:\WINDOWS\system32\WindowsPowerShell\v1.0;D:\DevTools\maven-2.0.5\bin
[12:53:12]: JAVA_HOME = C:\Program Files\Java\jdk1.6.0_22
[12:53:12]: RUN ARGUMENTS = [-f, D:\BuildAgent\work\42121fce523648d0\pom.xml, -B, -s, L:\chualin_ebilling_603_build\modules\qcf\conf\settings.xml, install]
[12:53:13]: [INFO] Scanning for projects...
[12:53:13]: [INFO] ----------------------------------------------------------------------------
[12:53:13]: [INFO] Building Maven Default Project
[12:53:13]: [INFO]    task-segment: [install]
[12:53:13]: [INFO] ----------------------------------------------------------------------------
[12:53:14]: [INFO] ------------------------------------------------------------------------
[12:53:14]: [ERROR] BUILD ERROR
[12:53:14]: [INFO] ------------------------------------------------------------------------
[12:53:14]: [INFO] Cannot execute mojo: resources. It requires a project with an existing pom.xml, but the build is not using one.
[12:53:14]: [INFO] ------------------------------------------------------------------------
[12:53:14]: [INFO] For more information, run Maven with the -e switch
[12:53:14]: [INFO] ------------------------------------------------------------------------
[12:53:14]: [INFO] Total time: 1 second
[12:53:14]: [INFO] Finished at: Fri Oct 15 12:53:14 MDT 2010
[12:53:14]: [INFO] Final Memory: 3M/77M
[12:53:14]: [INFO] ------------------------------------------------------------------------
[12:53:14]: Number of processed tests: 0
[12:53:14]: Publishing artifacts
[12:53:14]:     [Publishing artifacts] Paths to publish: [teamcity-info.xml]
[12:53:14]:     [Publishing artifacts] Publishing files
[12:53:14]: Build finished

19 comments

There is an error msg in build log:
Error reading Maven project: File doesn't exist: D:\BuildAgent\work\42121fce523648d0\pom.xml
This folder 42121fce523648d0 was created by build agent while I clicked the run button. There is also a file directory.map created under d:\BuildAgent\work folder at the same time.

#Don't edit this file!
#Mon Oct 18 08:41:51 MDT 2010
bt2=E-Billing 6.0.3 project::hourly 6.0.3 -> 42121fce523648d0 |?| Oct 18, 2010 8:41:49 AM MDT |:| default


I think directory.map tells build agent to go to folder 42121fce523648d0  to do the build.
But I have set up the working directory as L:\chualin_ebilling_603_build\modules in Configuration Step 3: Runner Maven2
Why it doesn't work?
If I copy all the content under L:\chualin_ebilling_603_build\modules to folder 42121fce523648d0, it can start the build.
Could anyone help me with this?

0

Hi,

According to the hint under the "Path to a POM file" edit box on Maven2 runner settings page, specified path should be relative to the checkout directory, not working directory.

That is why TC looks for your "pom.xml" in "D:\BuildAgent\work\42121fce523648d0" folder.

Why do not you want to create a VCS root for your ClearCase view at "L:\chualin_ebilling_603_build\modules" and attach it to your build configuration? So all the files from your CC view will be checked out to "D:\BuildAgent\work\42121fce523648d0".

0

Thank you for your reply!
I tried setting the ClearCase View path as L:\chualin_ebilling_603_build or L:\chualin_ebilling_603_build\modules. But it gave me the error:
Directory L:\chualin_ebilling_603_build does not exist or TeamCity server is running as a service using a user account that do not have permissions to this directory

I did run the TeamCity server and build agent service as my ClearCase account. Why it canot find the directory? I'm using CC dynamic view.

Thanks,
Chuan

0

Can you please try to start TeamCity server using command "bin/teamcity-server start" in TeamCity home directory? Is the error message shown in this case?

0

Are you sure that the ClearCase view is started?  TeamCity server/agent won't automatically start the view.

I have a script that I use to startup all of the views needed by TeamCity on my server.  So when the server is started at system startup time, this script is called to start the dynamic views.

0

I just tried running TeamCity from command line as you suggested.
I need to create new account, project, and build configurations after it's started.
All the old configurations are gone.
I still enconter the same error message while creating the VCS root.

0

Thank you for your reply. We are using windows server to create clearcase view. I think the view is started because when I click enviorment tab, there is only "stop view" can be clicked. "Start View" is greyed out. Please see attached.



Attachment(s):
CC.JPG
0

I suggest logging onto the machine as the same user that TeamCity is running as.  Open a command prompt and do "dir L:\"  ? Do you see your view there?  Then try "dir L:\chualin_ebilling_603_build", etc.

0

Yes. I can see my view from command window.

D:\>dir L:
Volume in drive L is CCase
Volume Serial Number is 0234-5789
Directory of L:\
10/15/2010  08:43 AM    <DIR>          .
10/15/2010  08:43 AM    <DIR>          ..
10/20/2010  08:11 AM                 0 .specdev
10/15/2010  08:43 AM    <DIR>          chualin_ebilling_603_build
               1 File(s)              0 bytes
               3 Dir(s)  52,428,800,000 bytes free

D:\>dir L:\chualin_ebilling_603_build
Volume in drive L is CCase
Volume Serial Number is 0234-5789
Directory of L:\chualin_ebilling_603_build
10/20/2010  08:14 AM    <DIR>          .
10/20/2010  08:14 AM    <DIR>          ..
10/20/2010  08:14 AM    <DIR>          ebpp
10/20/2010  08:14 AM    <DIR>          modules
               0 File(s)              0 bytes
               4 Dir(s)  52,428,800,000 bytes free

0

Hi,

Sorry for the delay in replying.

Is it possible to use snapshot ClearCase view for TeamCity?

0

No. We use dynamic view to make sure the source code is up to date.

0

TeamCity performs "update" operation for the specified view, so the sources checked out by TeamCity will be up to date even if you specify snapshot view in the settings.

0

I tried the snapshot view but got the same error:
Directory D:\ssViews\chualin_ebilling61_SS_build does not exist or TeamCity server is running as a service using a user account that do not have permissions to this directory

0

Is it possible your view name "chualin_..." contains unicode symbols or extra spaces?

0

No. It doesn't contain unicode character or space.

0

Hi Chuan,

Sorry for delay. Could you please perform several steps which help us to detect the issue source:
- send us with your "vcs-roots.xml" file (see http://confluence.jetbrains.net/display/TCD6/TeamCity+Data+Directory for the file location)
- go into "D:\ssViews\" and perform "cmd /c dir>dir_parent.out" command and attach dir_parent.out
- go into "D:\ssViews\chualin_ebilling61_SS_build" and perform "cmd /c dir>dir_view.out" command and attach dir_parent.out
- go into "D:\ssViews\chualin_ebilling61_SS_build" and perform "cleartool lsview -long -cview>cl_lsview.out" command and attach cl_lsview.out

Thanks in advance,
Konstantin

0

Hi Konstantin,

Thank you for your reply. We are migrating clearcase to SVN now. I tested SVN on TeamCity. There is no problem connecting to SVN server.
Don't know why clearcase doesn't work. I have attached those files you required.

Thanks,
Chuan



Attachment(s):
cl_lsview.out.zip
dir_parent.out.zip
dir_view.out.zip
vcs-roots.xml
0

HI Chuan,

We have discovered your logs but could not find any hint that helps us to detect the issue source. We can deliver a debug version of clearcase plugin which report more filesystem's info.
Let us know if you are still intresting in ClearCase integration of TeamCity.

Thanks in advance,
Konstantin

0

Hi Konstantin,

Thanks for your help. Since it's working fine with SVN and we are migrating to SVN now, I think I won't spend time on clearcase any more.

Thanks,
Chuan

0

Please sign in to leave a comment.