My team recently needed to update from TFS 2012 Update 1 to TFS 2012 Update 4, but ran into a problem during the upgrade:
Looking closer at the log file, it had this information:
XML parsing failed at line 1, column 0: A document must contain exactly one root element.
.
Errors in the metadata manager. An error occurred when instantiating a metadata object from the file, ‘\\?\d:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Data\Tfs_Analysis.0.db\Team System.8676.cub.xml’.[Info @22:20:14.393] Microsoft.AnalysisServices.OperationException: XML parsing failed at line 1, column 0: A document must contain exactly one root element.
.
Errors in the metadata manager. An error occurred when instantiating a metadata object from the file, ‘\\?\d:\Program Files\Microsoft SQL Server\MSAS11.MSSQLSERVER\OLAP\Data\Tfs_Analysis.0.db\Team System.8676.cub.xml’.
To get around this we:
- Restored the TFS_Configuration and TFS_[Collections] databases to their pre-upgrade state
- Re-ran the upgrade wizard, but this time unchecked the Reporting portion of the upgrade. This causes the installer to ignore the warehouse and analysis services part of the install
- After the install completed, we deleted the tfs_warehouse and tfs_analysis databases
- Following instructions from this TFS Setup Support blog post, rebuilt the warehouse and analysis databases
Upgrade complete!