Bug 57590 - Unable to connect to Mac Build host, after Windows 7 Critical Update
Summary: Unable to connect to Mac Build host, after Windows 7 Critical Update
Alias: None
Product: Visual Studio Extensions
Classification: Xamarin
Component: iOS ()
Version: 4.5.0 (15.2)
Hardware: PC Windows
: Normal normal
Target Milestone: 15.4
Assignee: Bugzilla
Depends on:
Reported: 2017-06-19 10:03 UTC by mofadevs
Modified: 2017-09-28 11:26 UTC (History)
7 users (show)

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

Xamarin Zip logs taken from Visual Studio (8.12 KB, application/zip)
2017-06-19 10:03 UTC, mofadevs
Log files from Mac located at "~/Library/Logs/Xamarin-4.5/" (75.76 KB, application/x-rar)
2017-06-22 07:45 UTC, mofadevs

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:

Description mofadevs 2017-06-19 10:03:41 UTC
Created attachment 22973 [details]
Xamarin Zip logs taken from Visual Studio

Good Day
I have been working on mobile apps using Xamarin forms for about 1.5 years using the same Mac Build host and Windows 7 pc. Yesterday, there was a Windows 7 critical update installed on my PC and since then I am unable to connect to my Mac Build Host. No other change at all on Mac or the way I have been accessing the Mac. I am using IP address of the Mac to connect to it. It finds the Mac, takes the username and password and after about 1 minute, errors out saying unable to connect, try again. 
Seeing the logs, reveals error Failed to execute 'grep "ssh-rsa....
Attached are the zip loges taken from Visual Studio. 

I have another dev machine(Windows PC on the same network) that connects successfully to the VERY SAME Mac without a problem. But not my machine which means something is wrong. 

We are a government body and a corporate client of Xamarin since last year. Please look into this and suggest.
Comment 1 Joaquin Jares 2017-06-20 16:24:23 UTC
Please try this: http://support.microsoft.com/kb/2588507. There was an incompatibility with .net's networking layer in windows 7 that may be related to your issue.
Comment 2 mofadevs 2017-06-21 09:46:17 UTC
@Joaquin Jares Thanks for replying back. I have tried the hotfix but the issue still persists. 

Additionally, when trying to connect to mac, the Visual Studio Output Window [Set to Xamarin] shows the following:

Starting connection to Mac
Starting Broker in port 55091...
Couldn't connect to Please try again.
Disconnected from the Mac (

If that would be of any help.
Comment 3 Jose Gallardo 2017-06-21 17:15:50 UTC
Given you cannot connect to the Mac, can you please zip and attach the content of the log files from the Mac located at "~/Library/Logs/Xamarin-4.5/"?.
Comment 4 mofadevs 2017-06-22 07:45:46 UTC
Created attachment 23050 [details]
Log files from Mac located at "~/Library/Logs/Xamarin-4.5/"
Comment 5 mag@xamarin.com 2017-06-23 18:20:03 UTC

I was taking a look at the provided logs and I can see that the Broker in the Mac appears to be starting successfully and without errors.

On the other hand, the VS log that you attached (Ide.log) appears to be truncated.

The "Failed to execute 'grep ssh-rsa...'" message that you see is not an Error but a Warning, and it happens when the local SSH key that you have in your Windows machine is not authorized on the Mac machine, in which case we proceed to add the authorization.

With the rest of the Ide.log we can see that the Broker is started, so that means the SSH authentication succeeded and the problem shouldn't be on the Mac.

Unfortunately, with the provided information I can't infer a particular problem.

Anyways, I would suggest to do the following things to enforce a check on the SSH authorization and also to look for more detailed logs (and hopefully not truncated):

- Remove the following files from %LOCALAPPDATA%\Xamarin\MonoTouch: id_rsa, id_rsa.pub and passphrase.key (doing this you will be forcing VS to ask for credentials again and to generate a new pair of SSH keys to then authorize in the connected Mac)

- Start VS in log mode (devenv.exe /log): This will allow to have verbose logging on both VS and Mac

- Try connect and wait for the error. Then verify in the %LOCALAPPDATA%\Xamarin\MonoTouch folder that the SSH keys have been re generated and please get the corresponding Ide.log file from %LOCALAPPDATA%\Xamarin\Logs\<VS-Version>

Thanks and I hope that the next log could tell us a little bit more about what is happening.
Comment 6 mag@xamarin.com 2017-07-05 02:51:48 UTC
Do you have any information or update about this problem?
Comment 7 mofadevs 2017-07-05 06:08:17 UTC
Hi there
My apologies for delayed reply. After examining Xamarin logs taken from Visual Studio, it turned out that Newtonsoft.Json version 8.0.3 was having some issues during Mac connectivity. Bare in mind that the very same version was working absolutely fine for several apps, and this happened suddenly. As I mentioned above, the only visible change was Windows 7 update after which things went wrong.

Anyways, I upgraded the Newtonsoft.Json to 9.x and the issue was resolved.