设计直接路由呼叫流程

直接路由(Direct Routing)是一种向 Microsoft Teams 用户提供 PSTN(公共交换电话网络)连接的方法,以便他们可以在 Teams 上拨打和接听外部电话。

一般来说,对于组织而言,内部和外部电话呼叫是使用专用交换机 (PBX) 电话系统传递的,该系统通常位于组织的数据中心 微软Teams 可用作业务电话解决方案,取代现有的 PBX 电话系统和 与基于云的系统相关的设备和成本,以在您的组织内外提供完整的 PBX 语音呼叫功能。

语音路由可帮助您决定如何通过会话边界控制器 (SBC) 路由呼叫。

要确定是否需要直接路由,请回答以下问题,如果有,直接路由是适合您的解决方案:

  • 您想将 Teams 与电话系统一起使用。
  • 您需要保留当前的 PSTN 运营商。
  • 您想要混合路由,一些呼叫通过通话套餐(Calling Plan),一些通过您现有的运营商。
  • 您需要与第三方 PBX 和/或SIP设备进行t语音通信

使用此选项:

  • 您无需额外的本地软件即可将自己支持的会话边界控制器 (SBC) 连接到电话系统。
  • 您几乎可以使用任何带有电话系统的电话运营商。
  • 您可以选择配置和管理此选项,也可以由您的运营商或合作伙伴配置和管理(询问您的运营商或合作伙伴是否提供此选项)。
  • 您可以配置电话设备(例如第三方 PBX 和模拟设备)与电话系统之间的互操作性。

此选项需要以下内容:

  • 部署和维护受支持的 SBC
  • 与第三方承运人的合同
  • 除非作为选项部署为使用电话计划的电话系统用户提供与第三方 PBX、模拟设备或其他电话设备的连接

如果您要使用托管或本地 SBC,您将使用到 SBC 的直接路由。 这与由 SIP 中继提供商托管的 SBC 不同,您或服务提供商需要提前为您配置 SBC。

使用 SBC 存在以下技术原因:

  • SBC 允许集成到呼叫中心应用程序中。
  • SBC 提供了在受支持的地理区域之外使用 Microsoft 通话计划的能力。

有多种方法可以关联 SBC; 这可以通过图形用户界面 (GUI) 或 PowerShell 完成。 必须注意,配置 Survivable Branch Appliance 的唯一方法是通过 PowerShell。

提供直接路由有 4 个步骤。 请按照以下步骤进行部署:

  • 将 SBC 与 Microsoft 电话系统连接并验证连接
  • 为用户启用直接路由、语音和语音邮件
  • 配置语音路由
  • 号码转换

将 SBC 与 Microsoft Phone 系统连接并验证连接

要将 SBC 连接到 Microsoft Phone 系统,请执行以下步骤:

  • 导航到 https://admin.teams.microsoft.com 上的 Microsoft Teams 管理中心
  • 在左侧导航窗格中,选择语音和直接路由。
  • 选择 SBC 选项卡并选择添加以创建新条目。
  • 输入 SBC 的有效 FQDN。

注意:

确保 FQDN 的域名部分与在租户中注册的域匹配,并记住 SBC FQDN 域名不支持“*.onmicrosoft.com”域名。 例如,如果您有两个域名“contoso.com”和“contoso.onmicrosoft.com”,则使用“sbc.contoso.com”作为 SBC 名称。 如果使用子域,请确保该子域也在您的租户中注册。 例如,如果要使用“sbc.service.contoso.com”,则需要注册“service.contoso.com”。

  • 根据组织的需要为 SBC 配置以下设置:
SettingValueExplanation
EnabledOffUsed to enable this SBC for outbound calls. You can temporarily remove the SBC from service while it is being updated or during maintenance.
SIP signaling port5067 (can be changed during setup)This is the listening port that’s used to communicate with Direct Routing by using the Transport Layer (TLS) protocol.
Send SIP optionsOnThis setting defines if an SBC will or won’t send SIP Options messages. If this isn’t turned on, the SBC will be excluded from the monitoring and alerting system. We recommend that you enable SIP Options.
Forward call historyOffIndicates whether call history information is forwarded through the trunk. When you turn this on, the Microsoft 365 or Office 365 proxy sends a history-info and Referred-by header.
Forward P-Assisted-Identity (PIA) HeaderOffIndicates whether the P-Asserted-Identity (PAI) header will be forwarded along with the call. The PAI header provides a way to verify the identity of the caller.
Concurrent call capacity24When you set a value, the alerting system will notify you when the number of concurrent sessions is 90 percent or higher than this value. If you don’t set a value, alerts aren’t generated. However, the monitoring system will report the number of concurrent sessions every 24 hours.
Failover response Code408, 503,504If Direct Routing receives any 4xx or 6xx SIP error code in response to an outgoing Invite, the call is considered completed by default. Outgoing means a call from a Teams client to the PSTN with traffic flow: Team’s client -> Direct Routing -> SBC -> telephony network). When you specify a failover response code, this forces Direct Routing to try another SBC (if another SBC exists in the voice routing policy of the user) when it receives the specified codes if the SBC can’t make a call because of network or other issues.
Failover time (seconds)10When set to 10 (default value), outbound calls that aren’t answered by the gateway within 10 seconds are routed to the next available trunk. If there are no additional trunks, then the call is automatically dropped. In an organization with slow networks and slow gateway responses, calls may be unintentionally dropped.
Preferred country/region for media trafficNoneUse to manually set your preferred country or region for media traffic. We recommend that you set this only if the call logs indicate that the default assignment of the datacenter for the media path doesn’t use the path closest to the SBC datacenter. By default, Direct Routing assigns a datacenter based on the public IP address of the SBC, and always selects the path closest to the SBC datacenter. However, in some cases, the default path might not be the optimal path. This parameter allows you to manually set the preferred region for media traffic.
SBC Supports PIDF/LO for emergency callsOffSpecify whether the SBC supports Presence Information Data Format Location Object (PIDF/LO) for emergency calls.
Ring phone while trying to find the userOffHistorically Ring back Bot could be enabled to force a ring signal/audio to be heard by the caller while Teams routed the call to the correct end user.
Location-based routingOffAllows for network-based routing to nearest SBC
Bypass ModeNoneMedia bypass enables you to shorten the path of media traffic and reduce the number of hops in transit for better performance
  • 完成后,选择保存。

您已成功配置从 Microsoft 团队到SBC的直接路由。

SBC 的配置可以通过微软Teams管理员面 (GUI) 或通过 PowerShell 完成,资源部分包含如何在需要时通过 PowerShell 配置Direct Routing直接路由。

为用户启用直接路由、语音和语音邮件

当您准备好为用户启用直接路由时,请执行以下步骤:

  • 配置电话号码并启用Enterprise Voice选项和语音信箱。
  • 将Teams许可分配给用户。

创建用户并分配许可证

微软365 中创建新用户有两个选项。建议您的组织选择以下其中任意一个选项以避免路由问题:

  • 在本地 Active Directory 中创建用户
  • 直接在 Microsoft 365 管理中心创建用户。 请参阅将用户单独或批量添加到 Microsoft 365 或 Office 365

如果您的 Skype for Business Online 部署与本地 Skype for Business 2015 或 Lync 2010 或 2013 共存,则唯一受支持的选项是在本地 Active Directory 中创建用户并将用户同步到云。

确保用户在线

此步骤适用于迁移到 Teams Direct Routing 的启用 Skype for Business Server Enterprise Voice 的用户。

直接路由要求用户在线。您可以通过查看 RegistrarPool 参数进行检查,该参数需要在 infra.lync.com 域中具有值。在将用户迁移到 Teams 直接路由时,还建议(但不是必需)将 LineURI 的管理从本地更改为联机。

您分配语音路由策略的用户也需要分配一个电话号码。首先,必须将自定义语音路由策略分配给将为 Microsoft Phone 启用的最终用户。

此步骤适用于迁移到 Teams Direct Routing 的启用 Skype for Business Server Enterprise Voice 的用户。直接路由要求用户在线。您可以通过查看 RegistrarPool 参数进行检查,该参数需要在 infra.lync.com 域中具有值。在将用户迁移到 Teams 直接路由时,还建议(但不是必需)将 LineURI 的管理从本地更改为联机。

通过发出以下命令连接 Skype for Business Online PowerShell 会话:

Get-CsOnlineUser -Identity “<User name>” | fl RegistrarPool,OnPremLineUriManuallySet,OnPremLineUri,LineUri

有关通过 PowerShell 启用用户的更多信息,请参阅下面的资源部分 – 请参阅为直接路由启用用户 – Microsoft Teams | 微软文档。

创建自定义语音路由策略

按照以下步骤创建新的自定义语音路由策略:

  • 导航到 https://admin.teams.microsoft.com 上的 Microsoft Teams 管理中心
  • 在左侧导航窗格中,选择语音和语音路由策略。
  • 选择添加以创建新条目。
  • 为策略输入一个有意义的名称和描述。
  • 在 PSTN 使用记录下,选择添加 PSTN 使用…,然后选择要添加的记录。 如果您需要创建新的 PSTN 使用记录,请选择添加。
  • 如果您添加了多个 PSTN 使用记录,请按您想要的顺序排列它们。
  • 完成后,选择应用。
  • 选择保存。
  • 创建新的自定义语音路由策略后,您可以使用正确的语音路由策略将呼叫路由到正确的会话边界控制器。
  • 有关进一步考虑的示例,请参阅参考部分 – 为直接路由配置语音路由。

号码转换

有时,租户管理员可能希望根据他们创建的模式更改出站和/或入站呼叫的号码,以确保与会话边界控制器 (SBC) 的互操作性。本文介绍如何指定号码转换规则策略以将号码转换为备用格式。您可以使用号码转换规则策略来转换以下号码: 入站呼叫:从 PSTN 终结点(呼叫者)到 Teams 客户端(被呼叫者)的呼叫 出站呼叫:从 Teams 客户端(呼叫者)到 PSTN 终结点(被呼叫者)的呼叫) 该策略适用于 SBC 级别。您可以将多个翻译规则分配给 SBC,这些规则将按照您在 PowerShell 中列出它们时出现的顺序应用。您还可以更改策略中规则的顺序。若要创建、修改、查看和删除数字操作规则,请使用 New-CsTeamsTranslationRule、Set-CsTeamsTranslationRule、Get-CsTeamsTranslationRule 和 Remove-CsTeamsTranslationRule cmdlet。要在 SBC 上分配、配置和列出号码操作规则,请将 New-CSOnlinePSTNGateway 和 Set-CSOnlinePSTNGateway cmdlet 与 InboundTeamsNumberTranslationRules、InboundPSTNNumberTranslationRules、OutboundTeamsNumberTranslationRules、OutboundPSTNNumberTranslationRules、InboundTeamsNumberTranslationRules、InboundPSTNNumberTranslationRules、OutboundTeamsNumberTranslationRules 参数和 OutboundPSTNNumberTranslationRules 一起使用。

Scroll to Top
Scroll to Top