Forum Visual Studio

Constant, consistent disconnects from Mac Agent (will not stay connected longer than 5 minutes)

PaulBrennerPaulBrenner USUniversity ✭✭
edited February 2016 in Visual Studio

Hello, I am getting constant disconnects from the mac agent. I can connect fine, but no matter what I'm doing, within 5 minutes it'll just randomly disconnect for no reason. It does it even if I'm currently running an app. It is doing it on multiple macs so I think it has something to do with the latest update (I'm running the latest stable Xamarin version)

I went through the Connection Troubleshooting guide (deleting caches and whatnot) but it is still doing it.

The logs don't seem to show anything helpful:

Xamarin.Messaging.VisualStudio.MessagingService Information: 0 : [2016-02-11 10:05:47.2766] Agent Designer 4.0.1.96 is running Xamarin.Messaging.VisualStudio.MessagingService Information: 0 : [2016-02-11 10:05:47.4046] MacServer State transition from AgentsStartingState to ConnectedState on 10.8.131.66 (10.8.131.66) Xamarin.Messaging.VisualStudio.MessagingService Information: 0 : [2016-02-11 10:05:47.5876] Connected to the Mac 10.8.131.66 (10.8.131.66) with Full support. Xamarin.VisualStudio.IOS.Messaging.State.ServerStateContext Information: 0 : [2016-02-11 10:08:03.8412] MacServer State transition from ConnectedState to DisconnectedState on 10.8.131.66 (10.8.131.66) System.Net.Mqtt.Client.Client Error: 0 : [2016-02-11 10:08:03.9623] System.ObjectDisposedException: Cannot access a disposed object. Object name: 'System.Net.Mqtt.TcpChannel'. at System.Net.Mqtt.TcpChannel.<SendAsync>d__0.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Net.Mqtt.PacketChannel.<SendAsync>d__a.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Net.Mqtt.Client.Client.<>c__DisplayClass30.<<SendPacketAsync>b__2f>d__32.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Net.Mqtt.Client.Client.<SendPacketAsync>d__35.MoveNext() --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Net.Mqtt.Client.Client.<DisconnectAsync>d__29.MoveNext() Xamarin.VisualStudio.IOS.Messaging.State.ServerStateContext Error: 0 : [2016-02-11 10:08:04.5193] An error occurred on the underlying client while executing an operation. Details: Cannot access a disposed object. Object name: 'System.Net.Mqtt.TcpChannel'. Xamarin.Messaging.VisualStudio.MessagingService Information: 0 : [2016-02-11 10:08:04.7193] Disconnected from Mac 10.8.131.66 (10.8.131.66) Xamarin.Messaging.VisualStudio.MessagingService Warning: 0 : [2016-02-11 10:08:04.8913] The underlying client has been disconnected by the remote host

This is extremely frustrating, does anyone have any suggestions?

Posts

  • rmahaffeyrmahaffey USUniversity ✭✭

    Having similar issues... random failures when building a solution with multiple iOS .csproj files from command line with msbuild in Jenkins. Sometimes it passes, sometimes it fails... I went through the connection troubleshooting guide as well. It's a good guide if you want to connect through the Visual Studio GUI but not too helpful when running CIG builds on the command line.

  • AlejandroRmzAlejandroRmz USUniversity ✭✭

    It's a year from then, and still experiencing the same issues. I wish I could curse here but then I would get kicked out of this community.

    So politely said: it has always sucked and it continues to suck.

  • AlejandroRmzAlejandroRmz USUniversity ✭✭

    The only workaround that works for me:
    1. Restart Visual Studio 2017.
    2. Run App
    3. When it stops working Go-To Step 1.

Sign In or Register to comment.