Jens Trier Rasmussen

The odd bit of information about Lync Server 2013, Lync 2010, Exchange 2013, SharePoint Server 2013, Exchange 2010 SP1, OCS 2007 R2, Exchange 2010 and OC 2007 R2

Media Bypass

Media Bypass

  • Comments 4
  • Likes

Media Bypass is a new feature in Lync 2010 enabling media to flow directly between clients and PSTN gateways. The basic concept is that the client and the Mediation Server exchanges BypassId’s and if the Id’s match each other media bypass is possible, but not guaranteed (as I’ll discuss later). The BypassId’s are assigned either globally, in which case all servers and clients use the same Id, or per network site, in which case the Id is assigned per subnet membership of the servers and clients. You can control if media bypass is used per PSTN Gateway using Set-CsTrunkConfiguration –EnableBypass.

As I wrote above it is the Mediation Server responsible for the PSTN gateway, which will decide if media bypass can be established. It happens during the signaling in the call setup phase. The PSTN gateway is not necessarily involved.

I’ve set it up in my lab and wanted to share some learning's:

  • When changing between enabling Media Bypass Globally and enabling it based on sites and regions make sure to sign out and in again on the client after you’ve made the change. The reason is that the client receives its BypassId via in-band provisioning in the mediaConfiguration provisioningGroup

    <provisionGroup name="mediaConfiguration" >
    <propertyEntryList >
    <property name="bypassEnabled" >true</property>
    <property name="internalBypassMode" >Any</property>
    <property name="externalBypassMode" >Off</property>
    <property name="bypassId" >c61755ed-402f-4b3b-86e2-2bd96252a23c</property>
    </propertyEntryList>
    </provisionGroup>

  • An easy way to determine, if a given call was using media bypass, is to look at the QoE report sent after the call. You can look at it via the Monitoring Server (User Activity Report –> <user you want to look for> –> Details –> Media Quality Report –> Call Information –> Mediation Server bypass call (true/false). You can also look at it in the uccapilog via Snooper. Find the SERVICE message being sent after the call was completed and look in the XML blob for the tag <v2:MediationServerBypassFlag>true</v2:MediationServerBypassFlag>
  • As I wrote above the BypassId’s needs to match, but that is not enough to get media bypass. The other requirement is that the two end-points are able to communicate media directly between them. This includes network connectivity, but also that the media encryption level being used by both end-points matches. Out of laziness my PSTN gateway was configured to use TCP and RTP to communicate with the Mediation Server. That worked perfect without media bypass, but it didn’t enable media bypass. The client was configured to RequireEncryption (Set-CsMediaConfiguration –EncryptionLevel) and as such wanted to use SRTP for media. Since the PSTN gateway didn’t accept or offer that media bypass was not working. I had to re-configure my PSTN gateway to use TLS and SRTP to get media bypass working.
Comments
  • Thanks for the great summary Jens.  In your research, have you found whether it's possible to enable media bypass on a conference endpoint?  My understanding was that once an MCU is involved, media bypass will not work-is this correct?

    Jens>Thanks & Yes :-)

  • Hi Jens

    I have a question about media bypass for connections to 3rd Party IP PBXs

    "When a user makes a call to the PSTN, the Mediation Server compares the bypass ID of the client subnet with the bypass ID of the gateway subnet. If the two bypass IDs match, media bypass is used for the call. If the bypass IDs do not match, media for the call must flow through the Mediation Server."

    My question is: Is the GW subnet defined by the IP address of the signaling peer or the "alternate media IP address" or can either of these addresses be used to find a subnet match to invoke media by pass ?

    Regards

    Tony

    Jens>Hi Tony, It will always use the alternate media IP address, if it is set.

  • What is externalBypassMode for and can I utilise (in the lab) already? Is this for Media Bypass via Edge? ;-)

    Jens>It's reserved for future use - http://technet.microsoft.com/en-us/library/gg425718(v=ocs.15).aspx

  • Thanks for the answer! Yes, I have read that already. In essence I am trying to figure out what scenario this is meant to support. Maybe to reach SIPTrunk-Provider directly via Media Bypass when connected via Edge :-)? In larger environments, I could envision oneself being the "provider" with PSTN-Gateways.

    BTW: Slightly disappointed about the Office365 Lync Hybrid news :-(

Your comment has been posted.   Close
Thank you, your comment requires moderation so it may take a while to appear.   Close
Leave a Comment