Error after restoring TFS database to new hardware - visual-studio

I am using TFS 2012. I wanted to test how i can recover from server failure or any hardware failure, So i wanted to shift TFS to new PC.
I followed some articles to restore it. what i did is
1)I had full backup of TFS_configuration and all other collection database.(backup taken using TFSbackup.exe)
2)In new PC i installed all the softwares(such as TFS 2012, sql server etc).
3)created all the windows user account as in old server.
4)When I checked the New PC it had default collection created which was mapped to sql server which i installed.
5)Now i deleted that default collection and restored all databases of my old TFS server(TFS_configuration and all other collection database.)(backup restored using TFSrestore.exe)
6)Now when i checked TFS administrative console it had all the collections as my old server.
7) But when i click on Administrative security, group membership etc I get error like
TF30046: The instance information does not match. Team Foundation expected 368f7830-1c67-4c4c-8bc4-ba3d5b5a5543 which was not found. Please contact your Team Foundation Server administrator.
In this link it was mentioned to change service host id in table. But it didn't work for me.
So please help

You mistakenly configured TFS (in fact it created a default collection). If read carefully Move Team Foundation Server from one hardware configuration to another, you have to run the AT-only Configuration Wizard after restoring the databases.

Related

(ORA-12154) Unable to connect to data source in tnsnames.ora from migrated SSIS project in VS 2017

I have a directive to pull code off of an old server and move it to my workstation, and also to update all TFS connections to our new TFS 2017 setup. I found a very important SSIS project that was only maintained by the person I replaced; it was still in VS BIDS 2008, and therefore can't connect to TFS 2017. This means I need to migrate the solution. For the most part, I've done so, but it has an Oracle connection that is giving me trouble, since the original provider is no longer supported. I'm not able to resolve the name when attempting to update the connection. The error is ORA-12154: TNS:could not resolve the connect identifier specified.
What I've done so far:
Install Oracle Client 12c with Administrative tools
Install the ODAC and ODP.Net
Install the SSIS Connectors v5.0 for Oracle
Added all server entries to tnsnames.ora and confirmed the syntax of the file
Successfully used tnsping to touch the server (20ms ping)
Rebooted the machine to satisfy "The I.T. Crowd" checklist
Pinged again just to make sure nothing involving network policy modified the files on reboot
Opened the old data connection in the connection manager pane of the .dtsx editor in VS 2017 and changed to the Oracle Provider for OLE DB
Confirmed the login is correct and the Data Source Name matches the name in tnsnames.ora
Confirmed TNSNAMES is in the NAMES.DIRECTORY_PATH variable for sqlnet.ora
Looked for a solution online (including here) and found that none quite apply to using the SSIS editor.
I was going to try bypassing the alias via the Data Link Properties and just pasting in the location, but there's a problem there, as well:
Also, all of the "advanced" tab is inactive. I can edit values in the "All" tab but the Location property isn't there.
I've hit that "where do I go from here" wall. How can I successfully connect to this datasource?
I found the culprit. Thank you to everyone for your assistance.
The cause was a stumbling block created in the installation and troubleshooting process. When the ODAC installed, it used a different user due to site permissions; the other location was in the system %PATH% above the correct one. By reordering the list so that the correct path to the tnsnames.ora file was on top and rebooting the system, the problem was resolved.

Advice on creating a local instance of Azure Website

I have, I admit, done things the wrong way round and created an Umbraco installation on Azure, developed multiple websites on that installation and only just decided I want a local instance for further development purposes.
Given that that's where I am, does anyone have any advice for how to go about achieving this? I have tried installing Visual Studio Community 2017 and MS SQL Server 2017 Developer and while I can connect to Azure with Visual Studio I don't seem to be able to work out how to view the installation, much less copy it down to my PC (something which I my searches seem to suggest isn't possible with Visual Studio).
I think you will need to copy down the site via FTP and the database using SQL Server Management Tools (assuming you are using SQL Server and not SQL CE).
You can get the FTP connection information from the Azure portal. The web root is in /site/wwwroot. Copy it down locally and you will be able to open it in Visual Studio as a Web Site. For the database, you can connect to the Azure SQL database with SQL Server Management Tools (you should have the connection info from when you created the database) and then right click on the database, select "Tasks" > "Export Data-tier application..." which will allow you to save a 'bacpac' file your local machine. You can then connect to your local SQL Server instance, and then right click on the "Databases" node in the Object Explorer and select "Import Data-tier application..." Once the database is imported, you may need to create/update a SQL Server user and grant it access to the database you just imported. For local development I just set the user to be owner of the the db. Back in Visual Studio, you should update the "umbracoDbDSN" connection string to use the new local database. At this point you should be able to run the website locally.

Setup a local TFS/TFVC repository in VS2015

I want to create a new project in VS2015 and set it up to use TFVC instead of Git.
I changed the source control plugin to Visual Studio Team Foundation Server from Tools->Options->Source Control->Plug-in Selection, and I created a new project with "Add to Source Control" checked, but the project is still created with a Git repo.
I also tried adding a server connection from Team Explorer->Manage Connections->Servers...->Add..., but there was no server at http://localhost:8080/tfs (I assume it's not install by default).
My question is how can I work on a TFS repository that is local to my computer (it's OK to use a server so long as it's on localhost).
You have to install Team Foundation Server on your local computer.
This is a separate download and not a part of Visual Studio.
According to the system requirements, TFS (starting with 2013) can only be installed on a 64-bit OS. You don't need to install SharePoint or any other part of TFS that you won't use (like for example Build Services).
You also need an instance of SQL Server running on your local computer. TFS will create a bunch of databases on this instance where it stores its internal data. If you don't have a license for SQL Server, you can use the Express Editions of TFS and SQL Server both for free. These Express Editions are recommended by Microsoft (see previous links) if you plan to use TFS only on you local computer, but of course you can use a paid edition as well if you need some special feature.
After installing TFS you have to create a Team Project Collection in the TFS Administration Console which can be found in the Start menu. Then add a new connection in the Team Explorer as shown in your screenshot and create a new Workspace (Source Control Explorer --> Workspace --> Add) with a Working Folder that matches the local directory containing your source files.
The URL of the TFS is the one that was set in the Application Tier of the TFS Administration Console. (http://localhost:8080/tfs is the default URL.)
As far as I know it's not possible to use a TFS/TFVC without installing and configuring a full Team Foundation Server reachable by a URL, but of course anything can be limited to be usable only on your local computer.

Corrupted Collection Database after an unsuccessful TFS 2015 "update 2" to "update 3" upgrade process

I've upgraded an On-Premise TFS instance from 2015 update 2 to update 3. the process failed for some reason (I think it was related to user permission to alter db schema - ddl).
Now the DB is corrupted, the TFS admin console "thinks" the DB is ready for TFS 2015 update 3 but i get an error trying to query for work items in the web portal.
Invalid column name 'IsDeleted'.
Is there a way do downgrade the schema?
Is there a way to 'trick' the DB to be in "update 2" state so the upgrade process will run again?
Any way to recover my work items? I don't mind copying them to a new collection or team project.
Thanks.
The DB's extended properties are:
TFS_DATABASE_TYPE Collection
TFS_PRODUCT_VERSION 14.0.23128.0
TFS_SCHEMA_VERSION Microsoft Team Foundation Server 2015
TFS_SERVICE_LEVEL Dev14.M102
and the Configuration DB's extended properties are:
TFS_DATABASE_TYPE Configuration
TFS_DEPLOYMENT_TYPE OnPremises
TFS_PRODUCT_VERSION 14.102.25423.0
TFS_SCHEMA_VERSION Microsoft Team Foundation Server 2015 Update 3
TFS_SERVICE_LEVEL Dev14.M102
EDIT
After using SQL Profiler I was ending up changing one of TFS's Views:
vw_denorm_WorkItemCoreLatest.sql
If anyone have figured it out please share.
Try recreating TFS Data Warehouse and Analysis Services by following this article: Rebuild TFS Warehouse and Analysis Databases From Scratch.

I changed the TFS 2010 server computer name

I Changed the TFS server computer name:
after i changed it i connected to the TFS server from Visual Studio using the new name after changing the connection string for the database (i am using the same server For TFS and TFS database). the connection succeeded, and i retrieved the projects from the Project collection, but when i expand a project i get a RED X on "DOCUMENTS" and "REPORTS" folder.
What do i need to do exactly to make it work. I know i should run a command to change the computer name in the workspaces, but i am not quite sure what is it and how to execute it.
What a bad idea!
Any moderate to complex system has many configuration items, not just one connection string.
To give an idea TFS is composed by: some Web site/services, a Window Service, a SQL instance (DB and Analysis), one or more SQL Server Reporting services, not counting other Windows Services for Build and Test that can be added to the architecture. And both TFS and Sharepoint have a Configuration database.
In this page you can get some hints of the steps you should have followed.
Specifically, the "Documents" folder error is about accessing Sharepoint and the "Reports" folder error is a failure of Reporting Services.
Frankly, if it was a simple computer rename, the best course of action is to restore the previous name, and use DNS alias for the new name. This is described in this post.
Another cheap way to fix things is to rebuild a new machine and move the databases from the old server, following this instructions.

Resources