Photon Master cannot be connected randomly.

Hi @JohnTube

The errors are as follows:

SocketTcpAsync.EndReceive SocketException. State: Connected. Server: 'master_ip_address' ErrorCode: 10054 SocketErrorCode: Connect
112 at System.Net.Sockets.Socket.EndReceive (System.IAsyncResult asyncResult) [0x00012] in <3845a180c26b4889bc2d47593a665814>:0
113 at ExitGames.Client.Photon.SocketTcpAsync.ReceiveAsync (System.IAsyncResult ar) [0x00023] in <e2387f9dc4784e52ba991612d3ef9d
114 v

Please help or give me some tips ,thanks very much.

Comments

  • Hi @JohnTube

    This issue is a essential problem for us, last week the master is OK, it suddenly happens today.
  • Hi @harlan,

    How to reproduce this?

    Does this happen on the Unity Editor only or also on builds? which target platform?
    Which region?

    PUN version?
    Unity version?
  • harlanharlan
    edited September 9
    Hi @JohnTube

    the platform is OSX, self hosted server.PUN version is 2.13 unity version is 2018.4.2f1

    we use builds on OSX to test. We run serval apps on one MAC computer, the first few ones can connect server successfully sometimes, and then error happens.

    We put PUN voice on a separate load balance cluster,is that OK?
  • I move this discussion to Photon Server category (self-hosted).

    Check server logs to see if the server does not shut down due to an unexpected issue.

    The server is hosted on Windows machine or Windows VM?

    We put PUN voice on a separate load balance cluster,is that OK?
    Yes.
  • We deploy it on VM,I saw the server was always running...
  • more detailed logs:


    111 SocketTcpAsync.EndReceive SocketException. State: Connected. Server: 'IP' ErrorCode: 10054 SocketErrorCode: Connect
    112 at System.Net.Sockets.Socket.EndReceive (System.IAsyncResult asyncResult) [0x00012] in <3845a180c26b4889bc2d47593a665814>:0
    113 at ExitGames.Client.Photon.SocketTcpAsync.ReceiveAsync (System.IAsyncResult ar) [0x00023] in <e2387f9dc4784e52ba991612d3ef9d
    114
    115 (Filename: ./Runtime/Export/Debug.bindings.h Line: 45)
    116
    117 [Voice.PhotonVoiceNetwork] OnPunStateChanged from ConnectingToMasterserver to Disconnected
    118
    119 (Filename: ./Runtime/Export/Debug.bindings.h Line: 45)
    120
    121 Disconnected from Photon.Exception
    122
    123 (Filename: ./Runtime/Export/Debug.bindings.h Line: 45)
    124
    125 Disconnected from Photon.Exception
  • Nothing helpful/useful on server logs?

    Maybe the serialization protocol is wrong?
    It should be set properly internally.
    Try doing so yourself before connecting:
            PhotonNetwork.NetworkingClient.LoadBalancingPeer.SerializationProtocolType = SerializationProtocol.GpBinaryV16;
            PhotonVoiceNetwork.Clien.LoadBalancingPeer.SerializationProtocolType = SerializationProtocol.GpBinaryV16;
    Which Photon Voice and PUN versions are you using?
  • PUN voice is v2.8 PUN2 is 2.13.I saw that the two SerializationProtocol types are already GpBinaryV16...
  • harlanharlan
    edited September 9
    Hi @JohnTube Can all the Photon servers use one 100 person license for test?
  • harlanharlan
    edited September 10


    see the wireshark package, as you see,15.13 is client side and 21.10 is server side.The upper picture is the correct one and below one throws the error.The first 8 network data are all the same, see the 9th data, the correct one is that client send PSH+ACK to server after 7 seconds, but the problematic one receives a RST after 10seconds...seems that photon server cannot wait for 10s...can we config this time for a longer one??
  • Hi @JohnTube

    After we optimize our codes ,the problem disappears, thank you.

    Harlan.
Sign In or Register to comment.