Can't connect to Xamarin Mac Agent after installing Visual Studio for Mac

After installing Visual Studio on Mac (Sierra), Xamarin Mac Agent does not connect anymore from PC Visual Studio 2017 to the Mac. It is working if Visual Studio is not installed on the MAC. Xamarin is up to date on both PC and MAC: Xamarin.iOS 10.10.0.30

The process hangs at Starting Broker 4.5.0.443 in port... Error log:

Xamarin.Messaging.Ssh.BrokerCommands|Verbose|0|Initializing Broker /Users/adrian/Library/Caches/Xamarin/XMA/Broker/4.5.0.443/Broker.exe for session 0c499cb6|2017-05-19 11:07:07Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'ls "/tmp/com.xamarin.2017-05-19__12-59-51.1652.broker"'...|2017-05-19 11:07:07Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'cat /tmp/com.xamarin.2017-05-19__12-59-51.1652.broker/output.log'...|2017-05-19 11:07:07Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'ls "/tmp/com.xamarin.2017-05-19__12-59-51.1652.broker"'...|2017-05-19 11:07:08Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'cat /tmp/com.xamarin.2017-05-19__12-59-51.1652.broker/output.log'...|2017-05-19 11:07:08Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'ls "/tmp/com.xamarin.2017-05-19__12-59-51.1652.broker"'...|2017-05-19 11:07:09Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'cat /tmp/com.xamarin.2017-05-19__12-59-51.1652.broker/output.log'...|2017-05-19 11:07:09Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'ls "/tmp/com.xamarin.2017-05-19__12-59-51.1652.broker"'...|2017-05-19 11:07:09Z
Xamarin.Messaging.Ssh.SshCommandRunner|Verbose|0|Executing SSH command 'cat /tmp/com.xamarin.2017-05-19__12-59-51.1652.broker/output.log'...|2017-05-19 11:07:09Z

......................

Xamarin.VisualStudio.Remote.State.DisconnectedState|Error|0|The Broker initialization exceeded the timeout of 60000 millisecs without receiving confirmation from the Broker.
System.TimeoutException: The Broker initialization exceeded the timeout of 60000 millisecs without receiving confirmation from the Broker.
at Xamarin.Messaging.Ssh.BrokerCommands.d__9.MoveNext() in C:\d\lanes\4699\c8715752\source\xamarinvs\src\Messaging\Xamarin.Messaging.Ssh\BrokerCommands.cs:line 82

Posts

  • AshleyGazichAshleyGazich Ashley Gazich USXamarin Team Xamurai

    Have you by any chance worked through the Connection Troubleshooting guide? If that hasn't helped, could you attach the logs from Mac and Windows and the full version info for both?

  • EmmanuelIstaceEmmanuelIstace Emmanuel Istace USMember ✭✭

    Same issue here, I have installed Visual Studio for Mac on a fresh Sierra install, I can connect with SSH but I can't through Visual Studio 2017.

    Already followed the giude mentionned, didn't solve the problem.

  • EmmanuelIstaceEmmanuelIstace Emmanuel Istace USMember ✭✭

    Here are my logs

    Xamarin.VisualStudio.Remote.State.ServerStateContext|Information|0|Transition d'état du serveur de DisconnectedState à SshConnectingState sur EISs-iMac.local. (192.168.100.59)
    Xamarin.VisualStudio.Remote.State.DisconnectedState|Error|0|Une erreur inattendue s'est produite pendant la configuration de SSH pour l'utilisateur eis
    Xamarin.Messaging.Exceptions.MessagingException: Une erreur inattendue s'est produite pendant la configuration de SSH pour l'utilisateur eis ---> System.Net.NetworkInformation.NetworkInformationException: L’accès à cet emplacement de la mémoire n’est pas valide
    à System.Net.NetworkInformation.SystemIPGlobalProperties.GetAllTcpConnections()
    à System.Net.NetworkInformation.SystemIPGlobalProperties.GetActiveTcpConnections()
    à Xamarin.Messaging.Ssh.PortForwarder.IsPortAvailable(Int32 port) dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Messaging\Xamarin.Messaging.Ssh\PortForwarder.cs:ligne 139
    à Xamarin.Messaging.Ssh.PortForwarder.GetAvailablePort(ConnectionSettings settings) dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Messaging\Xamarin.Messaging.Ssh\PortForwarder.cs:ligne 40
    à Xamarin.Messaging.Ssh.MessagingService.d__62.MoveNext() dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Messaging\Xamarin.Messaging.Ssh\MessagingService.cs:ligne 116
    --- Fin de la trace de la pile d'exception interne ---
    à Xamarin.Messaging.Ssh.MessagingService.d__62.MoveNext() dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Messaging\Xamarin.Messaging.Ssh\MessagingService.cs:ligne 153
    --- Fin de la trace de la pile à partir de l'emplacement précédent au niveau duquel l'exception a été levée ---
    à System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
    à System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
    à Xamarin.VisualStudio.Remote.State.DisconnectedState.d__8.MoveNext() dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\Xamarin.VisualStudio.Remote\State\DisconnectedState.cs:ligne 103
    --- Fin de la trace de la pile à partir de l'emplacement précédent au niveau duquel l'exception a été levée ---
    à System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
    à System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
    à System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task)
    à Xamarin.VisualStudio.Remote.State.DisconnectedState.d__7.MoveNext() dans C:\d\lanes\4471\3f99c5a7\source\xamarinvs\src\Core\Xamarin.VisualStudio.Remote\State\DisconnectedState.cs:ligne 50
    Xamarin.VisualStudio.Remote.State.DisconnectedState|Error|0|Connexion impossible à EISs-iMac.local.. Réessayez.
    Xamarin.VisualStudio.Remote.State.ServerStateContext|Information|0|Transition d'état du serveur de SshConnectingState à DisconnectedState sur EISs-iMac.local. (192.168.100.59)
    Xamarin.VisualStudio.Remote.State.ServerStateContext|Information|0|Déconnecté du Mac EISs-iMac.local. (192.168.100.59)

    The exception in english is "Access to that memory location is not allowed"

  • HansOlavStjernholm.7093HansOlavStjernholm.7093 Hans Olav Stjernholm NOMember

    I'm having the exact same error. I haven't installed Visual Studio for Mac, I have the old Xamarin Studio :(

  • ShantimohanElchuriShantimohanElchuri Shantimohan Elchuri USMember ✭✭✭✭

    I had Mac connection issues from VS 2015 after updating Xamarin for VS to before latest version. I have installed VS for Mac also. But after updating to Xamarin for VS ver 4.5.0.476, I was able to connect to Mac.

    I also saw the suggestion in other threads to check if the Xamarin.iOS versions are same on Mac and VS. Fortunately or unfortunately I find this is not a factor at all. My Xamarin.iOS versions are: In VS 2015 10.10.0.35, In VS 2017 10.10.0.30 (VS 2017 has X4VS .443 only) and in Mac 10.10.0.36. In spite of these version differences I am able to connect to Mac from both VS 2015 and VS 2017.

  • AlanClarkAlanClark Alan Clark USForum Administrator, Xamarin Team Xamurai

    As Shantomohan suggested, I'd definitely check that the Xamarin.iOS versions are the same on both the PC and Mac:

    Visual Studio
    Help -> About Microsoft Visual Studio

    Xamarin Studio in OS X
    Xamarin Studio -> About Xamarin Studio -> Show Details

    @ShantimohanElchuri Very minor differences in version numbers aren't usually an issue. However, sometimes things do break after updating one system without the other. So, you're correct, but I wouldn't worry about version 10.10.0.3X where X is different on both systems. Ideally they would be the same but sometimes they do differ on these minor updates.

Sign In or Register to comment.