Bug 17613 - Unhandled Activation Error: Could not load machine data
Summary: Unhandled Activation Error: Could not load machine data
Status: RESOLVED NOT_REPRODUCIBLE
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: Activation ()
Version: 1.8.x
Hardware: PC Windows
: High major
Target Milestone: ---
Assignee: Bugzilla
URL:
Depends on:
Blocks:
 
Reported: 2014-02-05 10:02 UTC by Allie Miller
Modified: 2016-03-28 19:50 UTC (History)
27 users (show)

Tags:
Is this bug a regression?: ---
Last known good build:


Attachments
log1 (15.35 KB, application/octet-stream)
2015-07-30 14:29 UTC, m.wisniowski
Details
log2 (46.01 KB, application/octet-stream)
2015-07-30 14:30 UTC, m.wisniowski
Details
log3 (57 bytes, application/octet-stream)
2015-07-30 14:30 UTC, m.wisniowski
Details


Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.


Please create a new report on Developer Community with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:
Status:
RESOLVED NOT_REPRODUCIBLE

Description Allie Miller 2014-02-05 10:02:05 UTC
This bug seems similar to Bug #16780, but it's a different error message. 

The issue:
When a user is logged into their Xamarin Store Account in Visual Studio, they somehow lose the login state and are presented with the following dialog when the attempt to re-login:

Unhandled Activation Error
System.Exception: Could not load machine data:
at Xamarin.Components.Ide.Activation.ActivationService.GetErrorWorkflow
(LicenseSyncResult[] results, Boolean ignoreSyncErrors)
at
Xamarin.Components.Ide.Activation.ActivationService.<GenerateFullWorkflowStep
(ActivationWorkflowStep step)
at
Xamarin.Components.Ide.Activation.ActivationDialog.<>c_DisplayClass13, <StartSpiner
TaskAndScheduleContinuation>b_12(Task t)


The user is able to login to Xamarin Studio successfully. However, a when the user attempts to re-activate the workstation with a new license file from Xamarin Studio, the license file is not generated. If they attempt to re-activate in Visual Studio, they are presented with the above error message.


Logs are attached.

Versioning information:
Microsoft Visual Studio Premium 2012
Version 11.0.50727.1 RTMREL
Microsoft .NET Framework
Version 4.5.50709
Xamarin Studio 4.2.3
Xamarin.Android: 4.10.02014
Xamarin.iOS for VS: 1.10.39.0
Comment 3 Henning 2014-02-25 09:11:09 UTC
Hi!
I do get also this error and your support team sent me over here to post my version information to let you know that the error exists also in the latest version:

Please note that I´m running VS 2013.

Microsoft Visual Studio Premium 2013
Version 12.0.30110.00 Update 1
Microsoft .NET Framework
Version 4.5.50938

Xamarin.Android   4.12.00028 (98634deb)
Xamarin.iOS   1.10.39 (e0334707)

Thank you!
Comment 4 Mohit Kheterpal 2014-02-25 10:58:48 UTC
Today I have tried to reproduce this issue, but I am not able to reproduce it.

I have tried to reproduce it by changing our system's Region and Language to Swedish(Sweden) with trial, business and enterprise license. 

I am not sure about your environment details, So could you please let me know
in which version of VS(like Sweden) are you facing this issue? 

Thanks.
Comment 5 Henning 2014-02-25 11:04:01 UTC
- German Windows 7 Enterprise (I´m located in germany)
- English Visual Studio 2003

Please let me know if I can support you.
Comment 7 Henning 2014-02-27 04:40:13 UTC
I meant of course VS 2013 not 2003..
Comment 8 PJ 2014-02-28 14:27:45 UTC
This seems to be causing people to be unable to use the product at all, so I'm moving it to the next release milestone and increasing the priority.

The info was provided so I'm moving this back to NEW.
Comment 11 PJ 2014-03-04 12:11:06 UTC
Hrm - make sure they are running using the mtouch.exe in C:\Program Files\MSBuild\Xamarin\iOS perhaps?

Although if they just open the command prompt and type mtouch --datafile they would see 'mtouch is not a recognized command', so perhaps they did navigate to the .exe.

At this point, the issue is likely that the only output is on standard error, I should have been more clear here. They would then need to run this:

C:\Program Files\MSBuild\Xamarin\iOS\mtouch.exe > out.txt 2> err.txt

And then give us the contents of out.txt and err.txt (likely only err.txt will have something).
Comment 21 James 2014-07-17 16:00:45 UTC
Another individual with this issue:

Visual Studio error:
Unhandled Activiation Error
System.Exception: Could not load machine data:
at Xamarin.Components.Ide.Activation.ActivationService.GetErrorWorkflow(LicenseSyncResult[] results, Boolean ignoreSyncErrors)
at Xamarin.Components.Ide.Activation.ActivationService.<GenerateFullWorkflowSequence>d__89.MoveNext()
at Xamarin.Components.Ide.Activation.ActivationDialog.DisplayWorkflowStep(ActivationWorkflowStep step)
at Xamarin.Components.Ide.Activation.ActivationDialog.<>c__DisplayClass13.<StartSpinnerTaskAndScheduleContinuation>b__12(Task t)

Microsoft Visual Studio Professional 2013
Version 12.0.30501.00 Update 2
Microsoft .NET Framework
Version 4.5.50938
 
Installed Version: Professional

Xamarin   3.1.224.0 (a40add33a62d9070ae5b74fb6799cc0d43fb766c)
Visual Studio extension to enable development for Xamarin.iOS and Xamarin.Android
Comment 23 Thore Berntsen 2014-09-10 06:53:01 UTC
Do You have any idea when this will be fixed? It's preventing me from doing my jobb!
Comment 27 Marco Vivero 2014-09-19 10:00:17 UTC
I had the same issue, on VS 2012, when I tried to login, I got the "Could not load machine data: at Xamarin.Components.Ide.Activation.ActivationService.GetErrorWorkflow" error.

Then I opened VS as Administrator, then logged in to my account with no problem.

Hope this works for you guys.
Comment 28 ultimecia_20 2014-10-01 05:47:55 UTC
I restarted my computer the other day and then this bug reappeared! I have tried unistalling and reinstalling twice now with no luck. I have tried removing my computer manually from the manage computers page on the xamarin account page.

I just want to input my product key and start coding but no such option exists and instead I need to login and stuff.

I can't do my work and losing all the "Business" part of the Xamarin product.
Comment 31 niko.jalkanen 2014-10-01 16:28:27 UTC
Hi,
I hade same problem but I found workaround which worked for me:

1.	Open xamarin studio and help-> check updates and install those
2.	Tools -> account and sign in
3.	Close Xamarin
4.	Open visual studio
5.	open project
6.	it works
Comment 33 ultimecia_20 2014-10-03 03:55:56 UTC
Nope, it didn't help, same problem. It works if I remove the iOS project from the solution but that is not good enough. I need to work on the iOS version from Visual Studio too.
Comment 37 Brendan Zagaeski (Xamarin Team, assistant) 2014-10-13 17:04:31 UTC
Mostly for the Xamarin support team: the stack trace from the error dialog is not by itself enough to diagnose the underlying problem for these issues.

The stack trace only means that _something_ is causing the machine data to be unreadable (or causing the machine data to be misinterpreted incorrectly as unreadable).


Therefore it is _essential_ to collect the output from both of the following 2 commands (be sure to collect all 4 output files, 2 from each command):

> [1] "C:\Program Files (x86)\MSBuild\Xamarin\Android\mandroid.exe" --datafile > "%USERPROFILE%\Desktop\mandroid-data.out" 2> "%USERPROFILE%\Desktop\mandroid-data.err"

> [2] [1] "C:\Program Files (x86)\MSBuild\Xamarin\iOS\mtouch.exe" --datafile > "%USERPROFILE%\Desktop\mtouch-data.out" 2> "%USERPROFILE%\Desktop\mtouch-data.err"


It is _also essential_ to know:

- Whether the user logs in via Active Directory.

- Whether the user's workstation is connected to more than 1 network simultaneously, or is otherwise involved in a complicated routing scenario.

- Whether the problem occurs intermittently (or, for example, started suddenly one day, without any installation changes).

- Whether any "MONO" environment variables are set. For example, collect the output of:
> set > "%USERPROFILE%\Desktop\environment.txt"

- Whether the the %USERPROFILE% path contains non-ASCII characters.

- Whether the following steps help with the problem:
1. Open the "Region" Control Panel.
2. Open the "Administrative" tab.
3. Click the "Copy settings" button.
4. Check ON the "Copy your current settings to -> Welcome screen and system
accounts" checkbox.
5. Click "OK"

- Whether the problem is happening only on Windows. It sounds like all of these errors are being seen on Windows, but if not, we definitely want to know that too.


It would also be nice to know:

- Does the activation succeed on Xamarin Studio and only fail on Visual Studio?
Comment 38 ultimecia_20 2014-11-05 03:34:05 UTC
All the requested files are empty except mandroid-data.out which contains:

zc5Vpaumt3V1YgAtaVtONTjrTxJC5HJ8/TNEI8BdPNdxH2obS0H0WaR80Z52W2kehiigGqQWkH0CaLqdpVYVkBGJMKYhwoHfAtr/edCkpigktlga75bp2H7x6jxK+TWY59Z/XKLtysOxQIIlKO7Eukfwg3WtpgYpqgxP+AHf5wo3iB01sUM7l8qsFf4R9+r5Z6da/jxWdjsHaa+9dRygh4JmPMdWwTyMpghyhXabUivzimEG81wQZEMRM8yxgTEjdfZdolIvItwofEpUEoEXqRVJ5EnY11OL27sqsgvbH2849dA2v4FqjsnokLOJMREWx5LfWyk01nkNL3bDX14gZruwvmA9WddiPanQeVt7UOJd8fJWxZxeDZHy8POIlGZs4C5Gc3xSvJJhKTODHmkwGATGzZNDsmDW8t8sMAcWOMg76p5Mn2VGDgfH1qsrDJ4CSsLSja9MTbP9evCzvVL9nZk2v3UHsvjL8rDNu8eZjOehB5Rr0fFW8VY/7y4+/oQKgefa0J/wLRRncXrih7FeiGmx+ei1Y26N1gm9yxw1Id8t53L0qXsDDktXq2wiuyeSvSyeoKOnxRUCPl7GZeApk3dcMywysw/WBMLhN6DCW1Ji9Ma+h0gSy1rj+VfGHot16PKhe3gBLA2+wS/sEq4tqcebTfrMGSD8J8EgwArPtoK4FEuo2jK44iQLX/WOVyfThnGnoFxSoJI=

It only happens on Windows in Visual Studio. The activation works in Xamarin Studio. There are no MONO environment variables set, the computer is only connected to 1 network. The problem starts when the computer restarts (either manually or by some Windows Update stuff). I have tried uninstalling and reinstalling to no help.

Why isn't there a normal activation mechanism where users input there activation code and the software is then activated?
Comment 40 Jimmy [MSFT] 2015-02-03 12:33:00 UTC
A customer was able to resolve the issue by doing the "Copy your current settings to" steps in comment 37.
Comment 42 Jimmy [MSFT] 2015-02-05 14:41:56 UTC
I had another customer run into this issue. 

However, they said the error popped up after opening a cross platform project and trying to log in. They only have an iOS business license, so they created a new iOS only project instead and were able to activate successfully then.
Comment 44 Samir Suljkanovic 2015-03-09 13:00:40 UTC
I am running Xamarin in Visual Studio 2013 on Windows 7 Enterprise.

I had this error several times so far. 

Unhandled Activation Error:
There was an internal error in the activation system. Please contact Xamarin Support with the following error information.

System.Exception: Could not load machine data:
at Xamarin.Components.Ide.Activation.ActivationService.GetErrorWorkflow(LicenseSyncResult[] results, Boolean ignoreSyncErrors)
at Xamarin.Components.Ide.Activation.ActivationService.<GenerateFullWorkflowSequence>d__89.MoveNext()
at Xamarin.Components.Ide.Activation.ActivationDialog.DisplayWorkflowStep(ActivationWorkflowStep step)
at Xamarin.Components.Ide.Activation.ActivationDialog.<>c__DisplayClass13.<StartSpinnerTaskAndScheduleContinuation>b__12(Task t)"


Every time I receive this error is after opening cross-platform examples for the shared project or the portable library.

Today, I am having the same issue. I did ran few examples, but I did not notice the problem until I reset AndroidPlayer to factory settings for one of the VMs I am using for Android app testing in order to delete all app data on it.

Now, when I try to run AndroidPlayer I receive error "A Xamarin.Android subscription is required to use this beta. Please open Xamarin Studio, log into your Xamarin account to activate Xamarin.Android subscription, then relaunch this app."

When I open Visual Studio and enter Xamarin credentials I get the Unhandled Activation Error described at the top.
Comment 46 Ian Ceicys 2015-07-10 11:33:27 UTC
Hello Samir, I am following up on this bug and attempting to reproduce the issue with the latest stable build of our Xamarin Visual Studio product (3.11.666) and so far I have been unable to reproduce the issue.

http://developer.xamarin.com/releases/vs/xamarin.vs_3/xamarin.vs_3.11/ 

At this time the best we can determine is that the issue is related to your network setup/configuration and I am unable to reproduce the error in our environments.

Please try to upgrade to the latest stable XVS build and if you are still experiencing the same problem please reply and I'd be more than happy to setup a screen sharing session to debug the issue.

For other folks experiencing this issue please see if when you are running Visual Studio as an administrator.

More over, if you have dedicated off-line workstation, where you can install the product and you still run into the "could not load machine data" issue...then I'd like to run an additional test with you.
Comment 47 Ian Ceicys 2015-07-17 08:32:49 UTC
Samir At this time the best we can determine is that the issue is related to your
network setup/configuration and I am unable to reproduce the error in our
environments.

Please let us know if you are continuing to experience this issue and if so upgrade to the latest stable XVS build and if you are still
experiencing the same problem
Comment 48 m.wisniowski 2015-07-30 14:29:55 UTC
Created attachment 12302 [details]
log1
Comment 49 m.wisniowski 2015-07-30 14:30:16 UTC
Created attachment 12303 [details]
log2
Comment 50 m.wisniowski 2015-07-30 14:30:32 UTC
Created attachment 12304 [details]
log3
Comment 51 m.wisniowski 2015-07-30 14:30:57 UTC
I uninstalled VS 2015 Community and installed VS 2015 Enterprise. I activated my account on iMac in Xamarin Studio (successfully). After OS X activation I activated account in Xamarin Studio Windows (only Android was available - successfully). Then I wanted to activate account in Visual Studio (admin mode), and again it's impossible. I also copied my regional settings before (https://bugzilla.xamarin.com/show_bug.cgi?id=17613#c37). I'm sending logs... Please do something... It's really annoying... How would I want to buy license in fututre when there is so much trouble to make it run...
Comment 52 m.wisniowski 2015-07-30 14:34:38 UTC
I uninstalled VS 2015 Community and installed VS 2015 Enterprise. I activated my account on iMac in Xamarin Studio (successfully). After OS X activation I activated account in Xamarin Studio Windows (only Android was available - successfully). Then I wanted to activate account in Visual Studio (admin mode), and again it's impossible. I also copied my regional settings before (https://bugzilla.xamarin.com/show_bug.cgi?id=17613#c37). I'm sending logs... Please do something... It's really annoying... How would I want to buy license in fututre when there is so much trouble to make it run...
Comment 53 dawid,sibinski 2015-08-18 17:20:20 UTC
The same thing happened to me. I've just installed Visual Studio 2015 Enterprise Edition and wanted to make use of Xamarin for Android... It's impossible to activate Xamarin. It gave me an error:
System.Exception: Could not load machine data:
at Xamarin.Components.Ide.Activation.ActivationService.GetErrorWorkflow(LicenseSyncResult[] results, Boolean ignoreSyncErrors)
at Xamarin.Components.Ide.Activation.ActivationService.<GenerateFullWorkflowSequence>d__88.MoveNext()
at Xamarin.Components.Ide.Activation.ActivationDialog.DisplayWorkflowStep(ActivationWorkflowStep step)
at Xamarin.Components.Ide.Activation.ActivationDialog.<>c__DisplayClass13.<StartSpinnerTaskAndScheduleContinuation>b__12(Task t)

Please do something with that, it's impossible to use Xamarin at all.
Comment 56 dawid,sibinski 2015-09-01 05:30:00 UTC
What is the progress on the issue?
Comment 57 Brendan Zagaeski (Xamarin Team, assistant) 2015-09-02 12:04:22 UTC
@dawid (and any other customers who might find this bug report when attempting to solve this error message),


This issue has more than 1 cause. Due to that complication, I would recommend that any customer who hits the problem contact Xamarin Support via email for one-on-one troubleshooting. For users with Business and higher licenses, you can use the email addresses listed on your account page (see [1]). For other users, please use contact@xamarin.com. (This bug is an exception to the usual rule about Business-and-higher only email support because it affects activation.)

Ideally, you can collect all of the information mentioned in Comment 37, and include that in your email to the support team.



[1] https://kb.xamarin.com/customer/portal/articles/1632104-how-do-i-contact-xamarin-for-support-


Thanks in advance.

Brendan
Xamarin Customer Support
Comment 58 Enzo Heredia 2015-09-09 15:40:58 UTC
can't reproduce in 4.0.0.1232
Comment 59 Jon Goldberger [MSFT] 2016-03-07 20:36:04 UTC
At least one customer reported this issue as a result of using F-secure security software. Disabling F-Secure resolved the issue.
Comment 60 ultimecia_20 2016-03-07 21:45:23 UTC
Yeah, we had F-secure when I encountered this problem. It might be worth looking into. Since I no longer work at the company where I this problem I can't verify or test this theory though.
Comment 61 wessel.kroos 2016-03-07 22:54:08 UTC
Hi Jon, I had time to isolate the cause in F-secure a bit more and we found a safer way than disabling your virus software. It seems that the DeepGuard option "Advanced process monitoring" is the root of the problem, atleast for us. You can disable it in the settings.

But I haven't found a way yet to exclude a specific dll or exe from the "Advanced process monitoring".