I installed TeamCity on Windows Server 2012. It has been working fine setting up a few builds. I then attempted to install some plugins by putting .zip files in the ~/.BuildServer/plugins folder. I restarted the server by cd'ing to c:\TeamCity\bin and running "runAll stop" followed by "runAll start".
Then when I go to the teamcity page for several minutes I get a "Enter the maintenance authentication token" page. It says on the page to find the maintenance token in the teamcity-server.log file (see screenshot below). I look in c:\TeamCity\logs\teamcity-server.log and it has several "super user token" and "agent authorizationtoken". I tried using these token but get an invalid maintenance token error.
So my question is where do I find the maintenance token?
Edit: This has resolved itself for me since upgrading to the latest TeamCity version. None of the suggested answers worked at the time I had this problem so that's why I am not marking anything as the accepted answer.
TeamCity uses log4j library for the logging and its settings can be customized. By default, log files are located under the < TeamCity Server home >/logs directory. Other files can also be created on changing Logging Configuration. Some of the files can have .N extensions — that are files with previous logging messages copied on main file rotation.
ssh to the server that the disconnected agent is on. go to the build agent’s bin directory (i.e. /opt/teamcity/buildagent/buildagent01/bin/) That will start the agent, and after a few seconds or so, the next time you go to TeamCity, it will be connected.
The default value is 8080, but you can just add the property and value you want like this: ## Defines which port the agent will use to receive messages from TeamCity. ## Defaults to 8080 if not present. ownPort=9091 I found the agent is connected this morning. Looks any fresh teamcity agent needs time to refresh itself.
Note: Reveal maintenance token will be disabled if bulk maintenance token is enabled. Optionally, input a Reason for Token Reveal and then click Reveal Token. Record the hostname Maintenance Token and then click Done. Note: The Maintenance Token will differ in your environment.
open cmd
goto TeamCity instalation folder
C:\TeamCity\bin
type
runAll.bat stop
wait until services stoped then type
runAll.bat start
u will see current authentication token in console,.
Please check out file teamcity-winservice.log in logs subfolder of your Teamcity. Auth token should be here.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With