none
Incoming PSTN call to external user fails to connect.

    Question

  • When trying to make a call which origin from PSTN, goes thru Media Gateway (DMG2000) to Lync and then is routed to external user,  i receive an error.

    On Lync on external user i see prompt for picking up call, and after i pick it up, call window appears, and connecting a call msg is written down.

    After 10 seconds it drops.

    Error description from Edge server:

    ms-diagnostics: 23;source="lync1.xxxx.com.pl";reason="Call failed to establish due to a media connectivity failure when one endpoint is internal and the other is remote";component="MediationServer";Exception="Proxy side ICE connectivity check failed.";ICEWarningFlags="ICEWarn=0x80120,LocalSite=10.xxx.xxx.xxx:54254,RemoteSite=87.205.xxx.xxx:60658,RemoteMR=193.xxx.xxx.xxx:56717,PortRange=49152:57500,RemoteMRTCPPort=56717,LocalLocation=2,RemoteLocation=0,FederationType=0"
    
    ms-diagnostics-public: 23;reason="Call failed to establish due to a media connectivity failure when one endpoint is internal and the other is remote";component="MediationServer";Exception="Proxy side ICE connectivity check failed."
    
    ms-endpoint-location-data: NetworkScope;ms-media-location-type=intranet

    Setup is very simple

    PBX <-> LyncFrontEnd <-> LyncEdge <-> remote user

    In this setup i have only 1 front end with mediation server on it , 1 edge with 1 public ip and 1 name for sip/webconf/av

    It look like lync server is trying to connect directly to remote user, not using the edge.

     

    Any ideas how to solve it?

    Wednesday, February 16, 2011 10:36 AM

Answers

  • Hello,

     

    We found a solution to our issue today!

     

     

    We noticed that the EdgeServer setting of the mediation server were "Not Set"

     

    (Lync Control Panel / Topology / Standard Edition / Mediation Server / Edge Server - Not Set)

     

    With PS:

     

    Get-CsService -MediationServer

     

    Identity             : MediationServer:standard.kressmark.com

    Registrar            : Registrar:standard.kressmark.com

    EdgeServer           :

    SipServerPort        : 5070

    SipClientTcpPort     : 5060

    SipClientTlsPort     : 5067

    AudioPortStart       : 49152

    AudioPortCount       : 8348

    DependentServiceList : {PstnGateway:10.10.10.40}

    ServiceId            : 1-MediationServer-4

    SiteId               : Site:Stockholm

    PoolFqdn             : standard.kressmark.com

    Version              : 5

    Role                 : MediationServer

     

    Also in the "Dependent Service" of the Edge server, we could only find “Registrar:…” and “ConferencingServer:…”.

    (Lync Control Panel / Topology / edge.kressmark.com / Edge Server / Dependents)

     

    We then used the following command:

     

    Set-CsMediationServer -Identity "MediationServer:standard.kressmark.com" -EdgeServer edge.kressmark.com

     

    And after restarting the Lync control panel it displayed correct data, and calls from external edge client via collocated mediation server to PSTN worked (and the other way around as well!)

     

     

    Strangely enough, the settings for "Audio/Video Edge service external FQDN" and "Internal interface FQDN" (as illustrated above) are still "Not set".

     

    /mk

    • Marked as answer by Paulus.Zaqu Tuesday, April 19, 2011 6:32 PM
    Tuesday, April 19, 2011 12:43 PM
  • After Some testing with Drago we found that collocated with front end mediation server tries to communicate with EXTERNAL edge server interface.

    This seems to be some kind of bug in Lync.

    After it we for testing purposes install standalone mediation server and everything started to work seamlessly.

     

    PS. Thanks a lot Drago for help.

    • Marked as answer by Paulus.Zaqu Friday, March 25, 2011 9:51 AM
    Friday, March 25, 2011 9:51 AM

All replies

  • If you are using NATing, please check in your topology if under “Edge pools” -> Your Edge you specified the Public IP Address of the AV Interface (4th line form top). Also, have you specified your Edge in “Edge pool (for media)” in the FE -> your front end -> Associations?

    Those are the two most common mistakes leading to the problem you describe.

     

    Drago


    http://ocsdude.blogspot.com
    Thursday, February 17, 2011 2:57 AM
  • Thanks for the reply.

    All things You mention are configured correctly

    The problem seems to be anywhere else.

    Funny thing is, that calls between local and remote users, and conferencing, audio and Video works fine.

    Issue I’m facing is that call which comes from media gateway could not be connected to external user. Call to internal user works ok.

     

    Other thing is that when I tested solution with https://www.testocsconnectivity.com/ I’ve got an error:

    Testing the Remote Connectivity of user username@domainname.com.pl to the Microsoft Lync Server. 
     Specified Remote Connectivity test(s) to Microsoft Lync Server failed. Please examine below details of specific reason for failure. 
      Tell me more about this issue and how to resolve it 
     
     Additional Details 
     Subscription for provisioning data did not return a valid MRAS URI.

     

     

     

    Now I’m trying to find out, if SDP candidates from both sides are correct.

     

     
    Thursday, February 17, 2011 10:44 AM
  • On the external client – Sing in to Lync Client. Press and hold CTRL, then click Lync icon in the task bar. Select “Configuration Information”. Look for the line “MRAS Server” – is there a value?

     

    Drago


    http://ocsdude.blogspot.com
    Thursday, February 17, 2011 2:00 PM
  • There is present value:

    Serwer MRAS;sip:lync2.domainx.com.pl@domainx.com.pl;gruu;opaque=srvr:MRAS:snEKtQr3G1y9MHLBt88QPgAA;Enabled;

    where lync2 is internal name of edge sever - is it correct?

    In time (10 sec) when call is in state of "connecting call..." wich appears on Lync call window, i can talk beetwen endpoints.

     update: connection is one way, i can hear in pbx phone , but silence on Lync client

     

     

    • Edited by Paulus.Zaqu Thursday, February 17, 2011 8:40 PM
    Thursday, February 17, 2011 3:01 PM
  • Hi guys,

    Having the same problem. My MRAS sip url is also showing the internal edge name for the external connecting users. Paulus by any chance are you having direct access deployed also?

     

    Regards,

    Alex.


    Alexandru Zamfir Probitas International Bucharest, ROMANIA.
    Thursday, February 17, 2011 5:13 PM
  • Alex,

    when you say "same issue", do you mean audio for 10 seconds only?

    We can work it out together - after all, we are neighbors (Bulgaria)

     

    Drago


    http://ocsdude.blogspot.com
    Thursday, February 17, 2011 7:41 PM
  • Paulus, what is your sip domain?

     

    Drago


    http://ocsdude.blogspot.com
    Thursday, February 17, 2011 7:42 PM
  • My MRAS SIP URI from an externally connected client too shows internal FQDN - that should be ok; I don't think that MRAS authentication is done from external clients. At least I do not have the problems described here.
    Johann Deutinger | MCTS Exchange 2007/2010 / OCS 2007 | ucblog.deutinger.de
    Thursday, February 17, 2011 9:00 PM
  • Drago,

    Thanks a lot for your help. My problem is almost the same. Our internal users are able to use Lync for PSTN calls (via a Cisco CUCM) and everything works fine. The problem is when a remote user that is connecting via the edge server is trying to call to a PSTN number. The PSTN phone rings but the parties cannot hear one another and after 4-5 second Lync is displaying an error message stating that "Call failed due to network issues". It seems that the Lync client is trying to connect for the RTP traffic to the internal address of the mediation server (collocated with our FE) but of course this address is not reachable from the internet. We don't have media bypass enabled. I saw the traffic problem using a sniffer (Wireshark). The question is why the Lync client is not using the edge server in order to get to the mediation one and then to the Cisco CUCM? Why it is trying to use STUN directly to the internal IP address of the mediation server? By the way Lync to Lync calls work fine even from internet via the edge. The problem is only with PSTN calls.

    Thanks a lot for your help and it's nice to know that you are a neighbor! :)

    Alex.

     


    Alexandru Zamfir Probitas International Bucharest, ROMANIA.
    Thursday, February 17, 2011 10:29 PM
  • Thanks for the info Johann. Then maybe it is something else.
    Alexandru Zamfir Probitas International Bucharest, ROMANIA.
    Thursday, February 17, 2011 10:30 PM
  • All right, few more questions.

    Di you have only Lync in your environment or mixed (OCS/Lync)? If later, are you still using OCS R2 mediation?

    The only thing that comes to my mind is that your Mediation (which negotiates the media path between the client and the gateway) is not aware of the presence of Edge (AV availability in particular).

    Will you please give us more information about your environment?

    Drago


    http://ocsdude.blogspot.com
    Thursday, February 17, 2011 10:43 PM
  • Drago,

    It is 100% Lync. The eviroment is a upgrade from OCS 2007 (no R2) but after the users where moved from the OCS pool to the new Lync pool the old OCS servers and settings where removed.

    Thanks  a lot,

    Alex.


    Alexandru Zamfir Probitas International Bucharest, ROMANIA.
    Friday, February 18, 2011 6:43 AM
  • No OCS in enviroment.

    Standard Frontend server with mediation colocated. One Edge server in DMZ, not in domain, with one public Ip and name.

    After some logging on Lync on client side and on edge server, i'm starting to suspect, that there is something wron with communication between mediation server and edge.

    How can I exchange logs with you privatly? They contain sensible data.

    You can contact me by my web http://velconnect.pl/

    Friday, February 18, 2011 2:15 PM
  • Paulus,

    Sent you my contact info via the web site. Is velconnect.pl your sip domain?

     

    Drago


    http://ocsdude.blogspot.com
    Saturday, February 19, 2011 12:42 AM
  • Alex,

    If your federation (IM at least) works, get with me: dragomir at gmc.cc.ga.us to get this going.

     

    Drago


    http://ocsdude.blogspot.com
    Saturday, February 19, 2011 12:45 AM
  • Guys and gals,

    While the concern regarding publishing private information on a public forum is legitimate, there is some info you elected to make public by deploying Edge role – your SIP domain, the A and SRV records of the edge interface, all published in your Public DNS.

    When it comes to troubleshooting Edge, (almost) everything starts from verifying if those are set correctly. Do tell your SIP domain when requesting help here, please.

     

    Drago


    http://ocsdude.blogspot.com
    Saturday, February 19, 2011 4:57 PM
  • Guys,

    After Drago spent a couple of hours with me on my Lync deployment finally I know what was wrong. It seems that the collocated mediation server is not supporting direct sip trunking for remote users connected via the edge. If you check the topo builder you will see that there isn't even such an option for the collocated mediation server role. If however you deploy a separate mediation server you will see an option named "edge pool for media". After deploying a separate mediation server everything is working fine in my deployment. I'm really grateful for the help Drago gave me.

    Thanks again Drago.

    Regards,

    Alex.

     


    Alexandru Zamfir Probitas International Bucharest, ROMANIA.
    Monday, February 21, 2011 8:33 PM
  • As a Drago offered me an online help (great thanks to him), and i couldn't utilize it yet due to lack of time, Alexandru could you briefly and shortly write down changes in your deployment, which you and Drago done?

    Do you have media bypass now enabled or disabled?

    I have media bypass enabled right now.

    Do you consider this issue as a bug or by design behavior? I did,t foud anything about this in documentation, anyway it's one to one sip trunk with no load balancing etc.

     

    • Edited by Paulus.Zaqu Tuesday, February 22, 2011 2:43 PM
    Tuesday, February 22, 2011 2:20 PM
  • Paulus,

    Alex omitted (perhaps due excitement) few very important errors we found in his environment.

    We found DNS misconfiguration. _sipinternaltls SRV record was missing and his internal clients were signing against the Assess Edge interface. Now, calls (media path) is treated differently when client is Internal vs. External.

    I looks to me that there is a confusion as of how exactly split domain environment should be configured (especially DNS configuration).

    In your case, please turn off media bypass and refer support for now. Let’s get it going and then you will fiddle with it.

     

    Drago


    http://ocsdude.blogspot.com
    Tuesday, February 22, 2011 2:42 PM
  • After Some testing with Drago we found that collocated with front end mediation server tries to communicate with EXTERNAL edge server interface.

    This seems to be some kind of bug in Lync.

    After it we for testing purposes install standalone mediation server and everything started to work seamlessly.

     

    PS. Thanks a lot Drago for help.

    • Marked as answer by Paulus.Zaqu Friday, March 25, 2011 9:51 AM
    Friday, March 25, 2011 9:51 AM
  • Hello,

     

    PBX (CS1000) --- Front-End & Mediation --- DMZ int --- Edge --- DMZ ext --- Remote Client

     

    We have a simple Lync edge installation with collocated Front-End and mediation server.

    We can call external client to internal client, internal client to PSTN, but not external client to PSTN.

    Well, the signalling goes through, we answer on the PSTN number, but media can not be connected so the client goes from "Connecting call" to "Call failed due to network issues"

     

    We are seeing the same error message when logging on the Edge server:

    "Call failed to establish due to a media connectivity failure when one endpoint is internal and the other is remote"

     

    We can also see in the logs that the mediation server tries to communicate with the EXTERNAL edge server interface!?

     

    Could it be that PSTN calls over Edge is not supported when using a collocated mediation server?

     

    Did anyone get this setup to work?

     

    (Media bypass is not on, fixes from Januray are implemented...) 

     

    /mk




    Wednesday, April 13, 2011 9:42 AM
  • IMHO this is bug in LYNC with colocated mediation server.

    It should be workaround to directly set external IP of Edge server somewhere in configuraion, but i didn't dig into it.

     

    Wednesday, April 13, 2011 10:02 AM
  • Does anyone know if this will be addressed by Microsoft?  Seems like a huge limitation.  I'd really like to be able to collocate my mediation server and have fully working Enterprise Voice with my edge users.
    Wednesday, April 13, 2011 5:34 PM
  • Hello,

     

    We found a solution to our issue today!

     

     

    We noticed that the EdgeServer setting of the mediation server were "Not Set"

     

    (Lync Control Panel / Topology / Standard Edition / Mediation Server / Edge Server - Not Set)

     

    With PS:

     

    Get-CsService -MediationServer

     

    Identity             : MediationServer:standard.kressmark.com

    Registrar            : Registrar:standard.kressmark.com

    EdgeServer           :

    SipServerPort        : 5070

    SipClientTcpPort     : 5060

    SipClientTlsPort     : 5067

    AudioPortStart       : 49152

    AudioPortCount       : 8348

    DependentServiceList : {PstnGateway:10.10.10.40}

    ServiceId            : 1-MediationServer-4

    SiteId               : Site:Stockholm

    PoolFqdn             : standard.kressmark.com

    Version              : 5

    Role                 : MediationServer

     

    Also in the "Dependent Service" of the Edge server, we could only find “Registrar:…” and “ConferencingServer:…”.

    (Lync Control Panel / Topology / edge.kressmark.com / Edge Server / Dependents)

     

    We then used the following command:

     

    Set-CsMediationServer -Identity "MediationServer:standard.kressmark.com" -EdgeServer edge.kressmark.com

     

    And after restarting the Lync control panel it displayed correct data, and calls from external edge client via collocated mediation server to PSTN worked (and the other way around as well!)

     

     

    Strangely enough, the settings for "Audio/Video Edge service external FQDN" and "Internal interface FQDN" (as illustrated above) are still "Not set".

     

    /mk

    • Marked as answer by Paulus.Zaqu Tuesday, April 19, 2011 6:32 PM
    Tuesday, April 19, 2011 12:43 PM
  • Hello all,

    basically I'm facing the same issue as Alexandru, PSTN calls from and to external Lync users fail most of the time regardless whether they're using edge or VPN. We are using an Audiocodes Mediant 1000, Media Bypass is off, Lync version is 4.0.7577.139

    Following the tips above I setup a dedicated Mediation last night, unfortunately calls are still failing, but less often for some reason.

    Here are some logs when connected with VPN:

    ms-diagnostics: 22;source="vasnely02.vasoft.de";reason="Call failed to establish due to a media connectivity failure when both endpoints are internal";component="MediationServer";Exception="Proxy side ICE connectivity check failed.";ICEWarningFlags="ICEWarn=0x280,LocalSite=172.16.1.80:51045,LocalMR=194.77.194.28:52740,RemoteSite=192.168.0.51:28796,PortRange=49152:57500,LocalMRTCPPort=52740,LocalLocation=2,RemoteLocation=0,FederationType=0"

    I guess I checked all recommendations, so I'm totally lost, can there anybody help with this?

    Regards

    Andreas

    Friday, October 07, 2011 12:29 PM
  • Dear All,

    I have the same problem with Andreas. I setup a dedicated Mediation but external Lync users call to PSTN fail.

    I have deployed Lync Server 2013.

    Please help me.

    Thanks.

    Monday, April 01, 2013 2:25 AM