Upgrading from 4.5 to 6

Hi,

We are using TeamCity Enterprise 4.5 on a server with 13 agents.  I am also using the Professionnal version, release 6 on my desktop for testing/evaluation purposes.

We are considering upgrading to release 6, and wonder if there is an automated config file updater as we have 310 build configurations in 15 projects so far.

While I was evaluating release 5, at some point I installed release 6 and had to convert manually the config files.  Specifically, the new <runner type="simpleRunner"> section that's there with release 6 and not before.  I had to parse and add this manually in each project's config xml files when I went from 5.1 to 6.  For a couple of config files that was ok, but for 310 modifs in 15 files that would require some time.

Maybe I did the update process wrong too.  I had manually backed up the config files, uninstall everything, install release 6, put back the config directory and restarted the service...

So what can we expect if we migrate from 4.5 to 6?  Should this be seamless or would I have to either manually modify the files or start from scratch?

Thanks

6 comments
Comment actions Permalink

Hi

Upgrade process should be automatic, and no manual editing of configuration files is required.
Without details I cannot say specifically, what went wrong with your upgrade, maybe the server didn't find it's data directory at first start, so configuration in files and SQL went out of sync.

Please review Upgrade Procedure and Notes, and try one more time. Text of errors would be helpful, if such issues happen again.

Michael

0
Comment actions Permalink

Hi,

Yesterday I tried to upgrade our main server (4.5.6) to 6.0.2 without success.

During installation, I get the message that a previous version have to be uninstall first. Ok.  I checked the boxes to remove the log files and the work directory, but not the configuration files.  Continue.  Then I had a Tomcat 6 error, saying it was unable to install, lacking permission or something, Abort, retry, continue.  Retries did nothing, I couldn't find a problem anywhere (no stuck exectuables in the background, ni hidden error dialog, ...) so I clicked on continue.  At the end, I was not able to access the server through the web.

I rebooted, same thing.  I then uninstalled it manually, then reinstalled it once again, this time unchecking the agent installation, as I didn't need it on that server.  It managed to get it installed, but on startup had a message that it required maintenance and requesting a maintenance ID or something, which I got from the log file.  At that point it seemed like it was going to work as it was asking if I wanted to proceed with the update of the previous version of the config files.  I said go but quickly got this error message.

TeamCity Server Startup Error

An error was encountered during TeamCity server startup

org.jdom.input.JDOMParseException: Error on line 2  of document file:/P:/TeamCityData/system/responsibles.xml: Invalid byte 2 of  3-byte UTF-8 sequence.
Copy to  clipboard
Stacktrace copied!
jetbrains.buildServer.serverSide.versioning.ConvertException:  org.jdom.input.JDOMParseException: Error on line 2 of document  file:/P:/TeamCityData/system/responsibles.xml: Invalid byte 2 of 3-byte UTF-8  sequence.
   at  jetbrains.buildServer.serverSide.versioning.converters.ResponsiblesXmlConverter.convert(ResponsiblesXmlConverter.java:69)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterStepJavaClass(ConvertPerformer.java:168)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterSteps(ConvertPerformer.java:138)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverter(ConvertPerformer.java:89)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverters(ConvertPerformer.java:78)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.upgradeIt(VersionManager.java:391)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.checkVersionsAndUpgradeSchemaIfNeeded(VersionManager.java:359)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager$2.run(VersionManager.java:415)
   at  jetbrains.buildServer.serverSide.db.TeamCityDatabaseManager.withDB(TeamCityDatabaseManager.java:568)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.ensureActualDatabase(VersionManager.java:411)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerInternal(TeamCityDispatcherServlet.java:394)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerSafe(TeamCityDispatcherServlet.java:24)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.access$400(TeamCityDispatcherServlet.java:232)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet$5.run(TeamCityDispatcherServlet.java:2)
   at  java.lang.Thread.run(Unknown Source)
caused by:  org.jdom.input.JDOMParseException: Error on line 2 of document  file:/P:/TeamCityData/system/responsibles.xml: Invalid byte 2 of 3-byte UTF-8  sequence.
   at org.jdom.input.SAXBuilder.build(SAXBuilder.java:501)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:847)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:826)
   at  jetbrains.buildServer.util.FileUtil.parseDocument(FileUtil.java:156)
   at  jetbrains.buildServer.serverSide.versioning.converters.ResponsiblesXmlConverter.convert(ResponsiblesXmlConverter.java:40)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterStepJavaClass(ConvertPerformer.java:168)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterSteps(ConvertPerformer.java:138)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverter(ConvertPerformer.java:89)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverters(ConvertPerformer.java:78)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.upgradeIt(VersionManager.java:391)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.checkVersionsAndUpgradeSchemaIfNeeded(VersionManager.java:359)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager$2.run(VersionManager.java:415)
   at  jetbrains.buildServer.serverSide.db.TeamCityDatabaseManager.withDB(TeamCityDatabaseManager.java:568)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.ensureActualDatabase(VersionManager.java:411)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerInternal(TeamCityDispatcherServlet.java:394)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerSafe(TeamCityDispatcherServlet.java:24)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.access$400(TeamCityDispatcherServlet.java:232)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet$5.run(TeamCityDispatcherServlet.java:2)
   at  java.lang.Thread.run(Unknown Source)
caused by:  org.apache.xerces.impl.io.MalformedByteSequenceException: Invalid byte 2 of  3-byte UTF-8 sequence.
   at  org.apache.xerces.util.ErrorHandlerWrapper.createSAXParseException(Unknown  Source)
   at org.apache.xerces.util.ErrorHandlerWrapper.fatalError(Unknown  Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown  Source)
   at org.apache.xerces.impl.XMLErrorReporter.reportError(Unknown  Source)
   at  org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown  Source)
   at  org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown  Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown  Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown  Source)
   at org.apache.xerces.parsers.XMLParser.parse(Unknown  Source)
   at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown  Source)
   at  org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown  Source)
   at org.jdom.input.SAXBuilder.build(SAXBuilder.java:489)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:847)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:826)
   at  jetbrains.buildServer.util.FileUtil.parseDocument(FileUtil.java:156)
   at  jetbrains.buildServer.serverSide.versioning.converters.ResponsiblesXmlConverter.convert(ResponsiblesXmlConverter.java:40)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterStepJavaClass(ConvertPerformer.java:168)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterSteps(ConvertPerformer.java:138)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverter(ConvertPerformer.java:89)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverters(ConvertPerformer.java:78)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.upgradeIt(VersionManager.java:391)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.checkVersionsAndUpgradeSchemaIfNeeded(VersionManager.java:359)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager$2.run(VersionManager.java:415)
   at  jetbrains.buildServer.serverSide.db.TeamCityDatabaseManager.withDB(TeamCityDatabaseManager.java:568)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.ensureActualDatabase(VersionManager.java:411)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerInternal(TeamCityDispatcherServlet.java:394)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerSafe(TeamCityDispatcherServlet.java:24)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.access$400(TeamCityDispatcherServlet.java:232)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet$5.run(TeamCityDispatcherServlet.java:2)
   at  java.lang.Thread.run(Unknown Source)
caused by:  org.apache.xerces.impl.io.MalformedByteSequenceException: Invalid byte 2 of  3-byte UTF-8 sequence.
   at  org.apache.xerces.impl.io.UTF8Reader.invalidByte(Unknown Source)
   at  org.apache.xerces.impl.io.UTF8Reader.read(Unknown Source)
   at  org.apache.xerces.impl.XMLEntityScanner.load(Unknown Source)
   at  org.apache.xerces.impl.XMLEntityScanner.scanContent(Unknown Source)
   at  org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanContent(Unknown  Source)
   at  org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown  Source)
   at  org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown  Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown  Source)
   at org.apache.xerces.parsers.XML11Configuration.parse(Unknown  Source)
   at org.apache.xerces.parsers.XMLParser.parse(Unknown  Source)
   at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown  Source)
   at  org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown  Source)
   at org.jdom.input.SAXBuilder.build(SAXBuilder.java:489)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:847)
   at  org.jdom.input.SAXBuilder.build(SAXBuilder.java:826)
   at  jetbrains.buildServer.util.FileUtil.parseDocument(FileUtil.java:156)
   at  jetbrains.buildServer.serverSide.versioning.converters.ResponsiblesXmlConverter.convert(ResponsiblesXmlConverter.java:40)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterStepJavaClass(ConvertPerformer.java:168)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverterSteps(ConvertPerformer.java:138)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverter(ConvertPerformer.java:89)
   at  jetbrains.buildServer.serverSide.versioning.ConvertPerformer.runConverters(ConvertPerformer.java:78)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.upgradeIt(VersionManager.java:391)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.checkVersionsAndUpgradeSchemaIfNeeded(VersionManager.java:359)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager$2.run(VersionManager.java:415)
   at  jetbrains.buildServer.serverSide.db.TeamCityDatabaseManager.withDB(TeamCityDatabaseManager.java:568)
   at  jetbrains.buildServer.serverSide.versioning.VersionManager.ensureActualDatabase(VersionManager.java:411)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerInternal(TeamCityDispatcherServlet.java:394)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.processStartupServerSafe(TeamCityDispatcherServlet.java:24)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet.access$400(TeamCityDispatcherServlet.java:232)
   at  jetbrains.buildServer.rootDispatcher.TeamCityDispatcherServlet$5.run(TeamCityDispatcherServlet.java:2)
   at  java.lang.Thread.run(Unknown Source)



By the way, the Copy to clipboard button didn't seem to work.


I had to uninstall everything, reinstall 4.5.6 and put back the backup I had made.


What is the correct procedure to upgrade?


I'm at your disposal to try anything.


Thanks.
0
Comment actions Permalink

Hi

Could you please send that problem file P:/TeamCityData/system/responsibles.xml to us to teamcity-feedback[at]jetbrains.com.

Thanks

0
Comment actions Permalink

Hi Pascal

Version 4 had problems with character encodings, and comments within the file become corrupted.
You can edit it by notepad and fix lines 120 and 245.

Michael

0
Comment actions Permalink

By the way, the Copy to clipboard button didn't seem to work.

What Browser/version/OS do you use?

0
Comment actions Permalink

Firefox 3.6.13 on Windows XP 32

0

Please sign in to leave a comment.