0
votes

I have recently migrated servers and updated TeamCity to point to the new server/agent. The agent was setup on the new machine and the agent is connected, authorized and enabled within TeamCity. After running a deployment, I noticed from the Build Logs that it skips the 'Publishing internal artifacts' step along with all of the proceeding Build Steps and completes with "Build finished". All of the packages from GitHub are deployed successfully to the Checkout Directory but non of the build steps run. TeamCity is not Publishing internal artifacts (ArtifactsCachePublisher & WebPublisher).

Here is the Build Log from a failed run:

[17:53:31]  Starting the build on the agent [new_server]
[17:53:32]  Clearing temporary directory: C:\BuildAgent\temp\buildTmp
[17:58:37]  Build finished

Here is the Build Log from a successful run:

[16:10:06]  Starting the build on the agent [old_server]
[16:10:07]  Clearing temporary directory: C:\BuildAgent\temp\buildTmp
[16:10:07]  Publishing internal artifacts (4s)
[16:10:11]  [Publishing internal artifacts] Publishing 1 file using 
[ArtifactsCachePublisher]
[16:10:11]  [Publishing internal artifacts] Publishing 1 file using 
[WebPublisher]
[16:10:07]  Using vcs information from agent file: deployment.xml
[16:10:07]  Checkout directory: C:\BuildAgent\work\deployment
[----build steps start to run here----]
1

1 Answers

0
votes

A few weeks ago I successfully migrated/updated My TeamCity server.

When packing artifacts I have encountered some issues.

My build step was interrupted with result Canceled with comment: Build and agent have finished unexpectedly or were killed. Please check agent logs for details..

Build agent log file did have following

Failed to publish artifacts Failed to publish artifacts: Connection reset by peer: socket write error, will try again. Failed to perform remote command Publishing to for build 12, error: jetbrains.buildServer.agent.ArtifactPublishingFailedException: Connection reset by peer: socket write error

Build agents publish artifacts to the server from the server API, so message Connection reset by peer did gave me a clue that artefacts file size may exceed TeamCity server setting.

Poking around the settings I found in Administration => Server Administration => Global Settings field Maximum build artifact file size: 300000000 with well descriptive text below in bytes. KB, MB, GB or TB suffixes are allowed, -1 indicates no limit