{"id":46,"date":"2017-06-02T15:49:03","date_gmt":"2017-06-02T15:49:03","guid":{"rendered":"http:\/\/pfool.com\/blog\/?p=46"},"modified":"2017-06-02T15:49:03","modified_gmt":"2017-06-02T15:49:03","slug":"failed-to-retrieve-data-for-this-request-with-sql-server-after-using-pcmover","status":"publish","type":"post","link":"https:\/\/pfool.com\/blog\/2017\/06\/02\/failed-to-retrieve-data-for-this-request-with-sql-server-after-using-pcmover\/","title":{"rendered":"&#8216;Failed to retrieve data for this request&#8217; with SQL Server after using PCMover"},"content":{"rendered":"<p>After using Laplink&#8217;s PCMover software to move all my software and computer setup to a new machine, I could not run SQL Server Express or SQL Server Management Studio on the new machine. I decided to do a reinstall but I would get the error &#8216;Failed to retrieve data for this request&#8217; whenever I tried to do the install. My original version of SQL Server Express was 2012 so that&#8217;s what I tried to reinstall. When that didn&#8217;t work I tried SQL Server Express 2014 with the same results.<\/p>\n<p>I did a lot of online searching to try and solve this and I found a lot of different suggestions on how to fix it but none seemed to work. I finally found where the install log for SQL Server was being created.<\/p>\n<p>C:\\Program Files\\Microsoft SQL Server\\110\\Setup Bootstrap\\Log\\20170531_163043\\<\/p>\n<p>The <b>110<\/b> directory is for SQL Server 2012. For SQL Server 2014 this will be <b>120<\/b>. The last subdirectory in the path will change as it is a time stamp of when the install was done. The log filename has the machine name as well as the time stamp as part of the name. It is in the format:<\/p>\n<p>Summary_<strong>MachineName<\/strong>_<strong>Datestamp<\/strong>_<strong>Timestamp<\/strong>_GlobalRules.txt<\/p>\n<p>Here is some of what was in the error log (I have highlighted important information):<\/p>\n<pre>Exception type: Microsoft.SqlServer.Management.Sdk.Sfc.EnumeratorException\r\n\u00a0\u00a0\u00a0 Message:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Failed to retrieve data for this request.\r\n\u00a0\u00a0\u00a0 HResult : 0x80131500\r\n\u00a0\u00a0\u00a0 Data:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0 HelpLink.ProdName = Microsoft SQL Server\r\n\u00a0\u00a0\u00a0\u00a0\u00a0 HelpLink.BaseHelpUrl = http:\/\/go.microsoft.com\/fwlink\u00a0\u00a0\u00a0\u00a0\u00a0 HelpLink.LinkId = 20476\r\n\u00a0\u00a0\u00a0\u00a0\u00a0 HelpLink.EvtType = 0x48BB60BC@0xBB814387\r\n\u00a0\u00a0\u00a0\u00a0\u00a0 DisableWatson = true\r\n\u00a0\u00a0\u00a0 Stack:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.ProcessDTbl(DataTable dt, Int32 level)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.ProcessDTbl(DataTable dt, Int32 level)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.CollectSqlDiscoveryData(String machineName)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.CollectDiscoveryData(String machineName)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.SqlDiscoveryDatastoreInterface.LoadData(IEnumerable`1 machineNames, String discoveryDocRootPath, String clusterDiscoveryDocRootPath)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Configuration.SetupExtension.RunDiscoveryAction.ExecuteAction(String actionId)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Chainer.Infrastructure.Action.Execute(String actionId, TextWriter errorStream)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Setup.Chainer.Workflow.ActionInvocation.ExecuteActionHelper(TextWriter statusStream, ISequencedAction actionToRun, ServiceContainer context)\r\n\u00a0\u00a0\u00a0 Inner exception type: Microsoft.SqlServer.Configuration.Sco.ScoException\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Message:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 <strong>Attempted to perform an unauthorized operation<\/strong>.\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 HResult : 0x84bb0001\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 FacilityCode : 1211 (4bb)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 ErrorCode : 1 (0001)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Data:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 WatsonData = <strong>HKEY_LOCAL_MACHINE@SOFTWARE\\Microsoft\\Microsoft SQL Server\\MSSQL10.SQLEXPRESS\\Setup<\/strong>\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Stack:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at <strong>Microsoft.SqlServer.Configuration.Sco.InternalRegistryKey.OpenSubKey<\/strong>(String subkey, RegistryAccess requestedAccess)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Configuration.Sco.SqlRegistryKey.OpenSubKey(String subkey, RegistryAccess requestedAccess)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Discovery.DiscoveryUtils.GetLocalMachineSubKey(ServiceContainer ctx, String machineName, RegistryView regView, String regPath, RegistryAccess registryAccess)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapObject(String machineName, RegistryView registryView, String instanceId, String instanceName, String instanceType, String instanceSuffix, UpgradedInstanceStateEnum instanceState)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapCollectionInHive(String machineName, RegistryView regView, List`1 subKeys)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Discovery.DiscoveryEnumObject.GetInstanceMapCollection()\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Discovery.Instance.GetData(EnumResult erParent)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetData()\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Management.Sdk.Sfc.Environment.GetData(Request req, Object ci)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.GetData(Object connectionInfo, Request request)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Management.Sdk.Sfc.Enumerator.Process(Object connectionInfo, Request request)\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Inner exception type: System.UnauthorizedAccessException\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Message:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Attempted to perform an unauthorized operation.\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 HResult : 0x80070005\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 Stack:\r\n\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0\u00a0 at Microsoft.SqlServer.Configuration.Sco.InternalRegistryKey.OpenSubKey(String subkey, RegistryAccess requestedAccess)<\/pre>\n<p>Based on this log, it seemed that there was some problem with reading registry subkeys. I ran regedit.exe to check out this specific registry location and found that I could not access many of the subkeys under HKEY_LOCAL_MACHINE@SOFTWARE\\Microsoft\\Microsoft SQL Server\\MSSQL10.SQLEXPRESS.<\/p>\n<p>I had found a web page that suggested running the setup under the LOCAL SYSTEM account. Rather than do that, I decided to try and run the registry editor using the LOCAL SYSTEM account to update the permissions for the subkeys that I could not access during the install. To do this, I opened a command line prompt as admin and went to the Windows\\System32 directory. I started another command prompt by using the program psexec.exe with the following command:<\/p>\n<p>Psexec.exe -s -i cmd.exe<\/p>\n<p>In this new command prompt session you will be running as the LOCAL SYSTEM account. I then went to the Windows\\SysWOW64 directory and ran regedt32.exe. I navigated to the key HKEY_LOCAL_MACHINE@SOFTWARE\\Microsoft\\Microsoft SQL Server\\MSSQL10.SQLEXPRESS and right-clicked and selected Permissions. I added a group for which I was a member and gave it full permissions.<\/p>\n<p>Once I did this I was able to run the SQL Server install (SQL Server Express 2014) without getting the error.<\/p>\n<p>However, when I subsequently ran SQL Server Management Studio, I would get another error saying <b>Invalid license data. Reinstall is required.<\/b> I tried various re-installs and kept getting this error. Then I found a website with the solution:<\/p>\n<ol>\n<li>Uninstall Visual Studio 2010 Shell (Isolated) ENU (or equiv)<\/li>\n<li>Repair SQL Server 2014 (if repair doesn&#8217;t work from Add\/Remove Programs then rerun SETUP.EXE from the installation source and choose the repair option &#8211; you can redownload and unpack if you don&#8217;t have this)<\/li>\n<\/ol>\n<p>After this, I was able to run SSMS and connect to the local SQL Server on my machine.<\/p>\n<p>&nbsp;<\/p>\n","protected":false},"excerpt":{"rendered":"<p>After using Laplink&#8217;s PCMover software to move all my software and computer setup to a new machine, I could not run SQL Server Express or &#8230;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-46","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/posts\/46","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/comments?post=46"}],"version-history":[{"count":1,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/posts\/46\/revisions"}],"predecessor-version":[{"id":48,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/posts\/46\/revisions\/48"}],"wp:attachment":[{"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/media?parent=46"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/categories?post=46"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pfool.com\/blog\/wp-json\/wp\/v2\/tags?post=46"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}