Skip to content

Commit 54eff65

Browse files
Merge pull request #240670 from boris-bazilevskiy/troubleshooting-sip
Troubleshooting sip
2 parents e240625 + 5bcd529 commit 54eff65

File tree

5 files changed

+310
-3
lines changed

5 files changed

+310
-3
lines changed
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
title: "Monitor Azure Communication Services direct routing"
3+
ms.author: bobazile
4+
ms.date: 06/22/2023
5+
author: boris-bazilevskiy
6+
manager: rcole
7+
audience: ITPro
8+
ms.topic: troubleshooting
9+
ms.service: azure-communication-services
10+
description: Learn how to monitor Azure Communication Services direct routing configuration, including Session Border Controllers, cloud components, and Telecom trunks.
11+
---
12+
13+
# Monitor direct routing
14+
15+
This article describes how to monitor your direct routing configuration.
16+
17+
The ability to make and receive calls by using direct routing involves the following components:
18+
19+
- Session Border Controllers (SBCs)
20+
- Direct routing components in the Microsoft Cloud
21+
- Telecom trunks
22+
23+
If you have difficulties troubleshooting issues, you can open a support case with your SBC vendor or Microsoft.
24+
25+
Microsoft is working on providing more tools for troubleshooting and monitoring. Check the documentation periodically for updates.
26+
27+
## Monitoring availability of Session Border Controllers using Session Initiation Protocol (SIP) OPTIONS messages
28+
29+
Azure Communication Services direct routing uses SIP OPTIONS sent by the Session Border Controller to monitor SBC health. There are no actions required from the Azure administrator to enable the SIP OPTIONS monitoring.
30+
31+
## Monitor with Azure portal and SBC logs
32+
33+
In some cases, especially during the initial pairing, there might be issues related to misconfiguration of the SBCs or the direct routing service.
34+
35+
You can use the following tools to monitor your configuration:
36+
37+
- Azure portal
38+
- SBC logs
39+
40+
In the direct routing section of Azure portal, you can check [SBC connection status](../direct-routing-provisioning.md#session-border-controller-connection-status).
41+
If calls can be made, you can also check [Azure monitors logs](../../analytics/logs/voice-and-video-logs.md) that provide descriptive SIP error codes
42+
43+
SBC logs also is a great source of data for troubleshooting. Reach out to your SBC vendor's documentation on how to configure and collect those logs.
44+
45+
## Next steps
46+
47+
[Troubleshoot direct routing connectivity](./troubleshoot-tls-certificate-sip-options.md)
48+
[Troubleshoot outbound calling](./troubleshoot-outbound-calls.md)
Lines changed: 112 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,112 @@
1+
---
2+
title: Troubleshoot Azure Communication Services direct routing outbound calls issues
3+
description: Learn how to troubleshoot Azure Communication Services direct routing potential issues that affect outbound calls.
4+
ms.date: 06/22/2023
5+
author: boris-bazilevskiy
6+
ms.author: bobazile
7+
manager: rcole
8+
audience: ITPro
9+
ms.topic: troubleshooting
10+
ms.service: azure-communication-services
11+
---
12+
13+
# Issues that affect outbound direct routing calls
14+
15+
You might experience various issues when you use direct routing to make outbound calls from an app built on Azure Communication Services (ACS) Software Development Kit (SDK) to a Session Border Controller (SBC). These issues include:
16+
17+
- An incorrect or anonymous caller ID is displayed to the call recipient.
18+
- A connection to the SBC isn't established.
19+
- Some users are unable to make calls.
20+
- No users in a tenant are able to make calls.
21+
22+
This article discusses potential causes of these issues, and provides resolutions that you can try.
23+
24+
## Incorrect caller ID displayed to the recipient
25+
26+
When you use direct routing, the caller ID information that is delivered to the call recipient is listed in the `From` and `P-Asserted-Identity` headers in the Session Initiation Protocol (SIP) options message.
27+
28+
The `From` header contains any of the following items:
29+
30+
- The phone number that's used as an `alternateCallerId` property of a `startCall` method in [Client Calling SDK](../../../quickstarts/telephony/pstn-call.md).
31+
If an `alternateCallerId` wasn't provided, it's replaced with "anonymous".
32+
- The phone number string that's passed when creating a `PhoneNumberIdentifier` object in [Call Automation SDK](../../../how-tos/call-automation/actions-for-call-control.md#make-an-outbound-call)
33+
- The phone number of the original caller if an Call Automation SDK [redirects the call](../../../how-tos/call-automation/actions-for-call-control.md#redirect-a-call).
34+
- The phone number selected as a Caller ID in Omnichannel Agent client application.
35+
36+
The `P-Asserted-Identity` header contains the phone number of the user who is billed for the call. The `Privacy:id` indicates that the information in the header has to be hidden from the call recipient.
37+
38+
### Cause
39+
40+
If the information in the `From` and `P-Asserted-Identity` headers doesn't match, and if the Public Switched Telephone Network (PSTN) prioritizes the `P-Asserted-Identity` header information over the `From` header information, then incorrect information is displayed.
41+
42+
### Resolution
43+
44+
To make sure that the correct caller ID is displayed to the call recipient, configure the SBC to either remove the `P-Asserted-Identity` header from the SIP INVITE message or modify its contents.
45+
46+
## Connection to the SBC not established
47+
48+
Sometimes, calls reach the SBC but no connection is established. In this situation, when the SBC receives a SIP OPTIONS message from Microsoft, it returns a failure message that includes error codes in the range of 400 to 699.
49+
50+
Any of the following causes might prevent a connection to the SBC.
51+
52+
### Cause 1
53+
54+
The SIP failure message is coming from another telephony device that is on the same network as the SBC.
55+
56+
### Resolution 1
57+
58+
Troubleshoot the other device to fix the error. If you need assistance, contact the device vendor.
59+
60+
### Cause 2
61+
62+
Your PSTN provider is experiencing some issue and is sending the SIP failure message. This is most likely the case if the failure error code is SIP 403 or SIP 404.
63+
64+
### Resolution 2
65+
66+
Contact your PSTN provider for support to fix the issue.
67+
68+
### Cause 3
69+
70+
The issue isn't coming from another device on the network or by your PSTN provider. However, the cause is otherwise unknown.
71+
72+
### Resolution 3
73+
74+
Contact the SBC vendor support to fix the issue.
75+
76+
## Some users are unable to make calls
77+
78+
If the connection between the Microsoft and the SBC is working correctly, but some users or applications can't make calls, the issue might be an incorrect scope of an Azure Communication Services access token
79+
80+
### Cause 1
81+
82+
Azure Communication Services access token was created with a chat scope.
83+
84+
### Resolution 1
85+
86+
Make sure that all the Azure Communication Services access tokens that are used for making calls are generated [with a `voip` scope](../../identity-model.md#access-tokens).
87+
88+
### Cause 2
89+
90+
None of the patterns in the Voice Routes match the dialed number.
91+
92+
### Resolution 2
93+
94+
Make sure that the following conditions are true:
95+
96+
- There's a pattern in the Voice Route that matches the dialed number.
97+
- The SBC that's specified for the Voice Route is **Online**. If it's **Inactive**, either set it up to become **Online** or select a different SBC that is **Online**
98+
99+
### Cause 3
100+
101+
The SBC isn't responding to SIP OPTIONS messages because some device on the network, such as a firewall, is blocking the messages.
102+
103+
### Resolution 3
104+
105+
Make sure that the SIP Signaling IPs and FQDNs are allowed on all network devices that connect the SBC to the internet. The IP addresses that must be allowed are listed at [SIP Signaling: FQDNs](../direct-routing-infrastructure.md#sip-signaling-fqdns).
106+
107+
## Related articles
108+
109+
- [Troubleshoot direct routing connectivity](./troubleshoot-tls-certificate-sip-options.md)
110+
- [Plan for Azure direct routing](../direct-routing-infrastructure.md)
111+
- [Pair the Session Border Controller and configure voice routing](../direct-routing-provisioning.md)
112+
- [Outbound call to a phone number](../../../quickstarts/telephony/pstn-call.md)
Lines changed: 139 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,139 @@
1+
---
2+
title: "Troubleshoot Azure Communication Services direct routing TLS certificate and SIP OPTIONS issues"
3+
ms.author: bobazile
4+
ms.date: 06/22/2023
5+
author: boris-bazilevskiy
6+
manager: rcole
7+
audience: ITPro
8+
ms.topic: troubleshooting
9+
ms.service: azure-communication-services
10+
description: Learn how to troubleshoot Azure Communication Services direct routing connectivity with Session Border Controllers - TLS certificate and SIP OPTIONS issues.
11+
---
12+
13+
# Session Border Controller (SBC) connectivity issues
14+
15+
When you set up a direct routing, you might experience the following Session Border Controller (SBC) connectivity issues:
16+
17+
- Session Initiation Protocol (SIP) OPTIONS aren't received.
18+
- Transport Layer Security (TLS) connections problems occur.
19+
- The SBC doesn't respond.
20+
- The SBC is marked as inactive in the Azure portal.
21+
22+
The following conditions are most likely to cause such issues:
23+
24+
- A TLS certificate experiences problems.
25+
- An SBC isn't configured correctly for direct routing.
26+
27+
This article lists some common issues that are related to SIP OPTIONS and TLS certificates, and provides resolutions that you can try.
28+
29+
## Overview of the SIP OPTIONS process
30+
31+
- The SBC sends a TLS connection request that includes a TLS certificate to the SIP proxy server Fully Qualified Domain Name (FQDN) (for example, **sip.pstnhub.microsoft.com**).
32+
33+
- The SIP proxy checks the connection request.
34+
35+
- If the request isn't valid, the TLS connection is closed and the SIP proxy doesn't receive SIP OPTIONS from the SBC.
36+
- If the request is valid, the TLS connection is established, and the SBC sends SIP OPTIONS to the SIP proxy.
37+
38+
- After SIP proxy receives SIP OPTIONS, it checks the Record-Route to determine whether the SBC FQDN belongs to a known Communication resource. If the FQDN information isn't detected there, the SIP proxy checks the Contact header.
39+
40+
- If the SBC FQDN is detected and recognized, the SIP proxy sends a **200 OK** message by using the same TLS connection.
41+
42+
- The SIP proxy sends SIP OPTIONS to the SBC FQDN that is listed in the Contact header of the SIP options received from the SBC.
43+
44+
- After receiving SIP OPTIONS from the SIP proxy, the SBC responds by sending a **200 OK** message. This step confirms that the SBC is healthy.
45+
46+
- As the final step, the SBC is marked as **Online** in the Azure portal.
47+
48+
## SIP OPTIONS issues
49+
50+
After the TLS connection is successfully established, and the SBC is able to send and receive messages to and from the SIP proxy, there might still be problems that affect the format or content of SIP OPTIONS.
51+
52+
### SBC doesn't receive a "200 OK" response from SIP proxy
53+
54+
This situation might occur if you’re using an older version of TLS. To enforce stricter security, enable TLS 1.2.
55+
56+
Make sure that your SBC certificate isn't self-signed and that you got it from a [trusted Certificate Authority (CA)](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
57+
58+
If you’re using TLS version 1.2 or higher, and your SBC certificate is valid, then the issue might occur because the FQDN is misconfigured in your SIP profile and not recognized as belonging to any Communication resource. Check for the following conditions, and fix any errors that you find:
59+
60+
- The FQDN provided by the SBC in the Record-Route or Contact header is different from what is configured in Azure Communication resource.
61+
- The Contact header contains an IP address instead of the FQDN.
62+
- The domain isn’t [fully validated](../../../how-tos/telephony/domain-validation.md). If you add an FQDN that wasn’t validated previously, you must validate it.
63+
64+
### SBC receives "200 OK" response but not SIP OPTIONS
65+
66+
The SBC receives the **200 OK** response from the SIP proxy but not the SIP OPTIONS that were sent from the SIP proxy. If this error occurs, make sure that the FQDN that's listed in the Record-Route or Contact header is correct and resolves to the correct IP address.
67+
68+
Another possible cause for this issue might be firewall rules that are preventing incoming traffic. Make sure that firewall rules are configured to allow incoming connections from all [SIP proxy signaling IP addresses](../direct-routing-infrastructure.md#sip-signaling-fqdns).
69+
70+
### SBC status is intermittently inactive
71+
72+
This issue might occur if:
73+
74+
- The SBC is configured to send SIP OPTIONS not to FQDNs but to the specific IP addresses that they resolve to. During maintenance or outages, these IP addresses might change to a different datacenter. Therefore, the SBC is sending SIP OPTIONS to an inactive or unresponsive datacenter. To resolve the issue:
75+
76+
- Make sure that the SBC is discoverable and configured to send SIP OPTIONS to only FQDNs.
77+
- Make sure that all devices in the route, such as SBCs and firewalls, are configured to allow communication to and from all Microsoft SIP signaling FQDNs.
78+
- To provide a failover option when the connection from an SBC is made to a datacenter that's experiencing an issue, the SBC must be configured to use all three SIP proxy FQDNs:
79+
80+
- sip.pstnhub.microsoft.com
81+
- sip2.pstnhub.microsoft.com
82+
- sip3.pstnhub.microsoft.com
83+
84+
> [!NOTE]
85+
> Devices that support DNS names can use sip-all.pstnhub.microsoft.com to resolve to all possible IP addresses.
86+
87+
For more information, see [SIP Signaling: FQDNs](../direct-routing-infrastructure.md#sip-signaling-fqdns).
88+
89+
- The installed root or intermediate certificate isn't part of the SBC certificate chain issuer. When the SBC starts the three-way handshake during the authentication process, the Azure service is unable to validate the certificate chain on the SBC and resets the connection. The SBC may be able to authenticate again as soon as the public root certificate is loaded again on the service cache or the certificate chain is fixed on the SBC. Make sure that the intermediate and root certificates installed on the SBC are correct.
90+
91+
For more information about certificates, see [SBC certificates and domain names](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
92+
93+
### FQDN doesn’t match the contents of CN or SAN in the provided certificate
94+
95+
This issue occurs if a wildcard doesn't match a lower-level subdomain. For example, the wildcard `\*\.contoso.com` would match `sbc1.contoso.com`, but not `sbc.acs.contoso.com`. You can't have multiple levels of subdomains under a wildcard. If the FQDN doesn’t match the Common Name (CN) or Subject Alternate Name (SAN) in the provided certificate, request a new certificate that matches your domain names.
96+
97+
For more information about certificates, see [SBC certificates and domain names](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
98+
99+
## TLS connection issues
100+
101+
If the TLS connection is closed right away and SIP OPTIONS aren't received from the SBC, or if **200 OK** isn't received from the SBC, then the problem might be with the TLS version. The TLS version configured on the SBC should be 1.2 or higher.
102+
103+
### SBC certificate is self-signed or not from a trusted CA
104+
105+
If the SBC certificate is self-signed, it isn't valid. Make sure that the SBC certificate is obtained from a trusted Certificate Authority (CA).
106+
107+
For a list of supported CAs, see [SBC certificates and domain names](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
108+
109+
### SBC doesn't trust SIP proxy certificate
110+
111+
If the SBC doesn't trust the SIP proxy certificate, download and install the Baltimore CyberTrust root certificate **and** he DigiCert Global Root G2 certificates on the SBC. To download those certificates, see [Microsoft 365 encryption chains](/microsoft-365/compliance/encryption-office-365-certificate-chains).
112+
113+
For a list of supported CAs, see [SBC certificates and domain names](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
114+
115+
### SBC certificate is invalid
116+
117+
If the SBC connection status in the Azure portal indicates that the SBC certificate is expired, request or renew the certificate from a trusted Certificate Authority (CA). Then, install it on the SBC. For a list of supported CAs, see [SBC certificates and domain names](../direct-routing-infrastructure.md#sbc-certificates-and-domain-names).
118+
119+
When you renew the SBC certificate, you must remove the TLS connections that were established from the SBC to Microsoft with the old certificate and re-establish them with the new certificate. Doing so ensures that certificate expiration warnings aren't triggered in Azure portal.
120+
To remove the old TLS connections, restart the SBC during a time frame that has low traffic such as a maintenance window. If you can't restart the SBC, contact the vendor for instructions to force the closure of all old TLS connections.
121+
122+
### SBC certificate or intermediary certificates are missing in the SBC TLS "Hello" message
123+
124+
Check that a valid SBC certificate and all required intermediate certificates are installed correctly, and that the TLS connection settings on the SBC are correct.
125+
126+
Sometimes, even if everything looks correct, a closer examination of the packet capture might reveal that the TLS certificate isn't provided to the Microsoft infrastructure.
127+
128+
### SBC connection is interrupted
129+
130+
The TLS connection is interrupted or not set up even though the certificates and SBC settings experience no issues.
131+
132+
One of the intermediary devices (such as a firewall or a router) on the path between the SBC and the Microsoft network might close the TLS connection. Check for any connection issues within your managed network, and fix them.
133+
134+
## Related articles
135+
136+
- [Monitor direct routing](./monitor-direct-routing.md)
137+
- [Plan for Azure direct routing](../direct-routing-infrastructure.md)
138+
- [Pair the Session Border Controller and configure voice routing](../direct-routing-provisioning.md)
139+
- [Outbound call to a phone number](../../../quickstarts/telephony/pstn-call.md)

articles/communication-services/quickstarts/telephony/pstn-call.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,4 @@ If you want to clean up and remove a Communication Services subscription, you ca
3737
For more information, see the following articles:
3838

3939
- Learn about [Calling SDK capabilities](../voice-video-calling/getting-started-with-calling.md)
40-
- Learn more about [how calling works](../../concepts/voice-video-calling/about-call-types.md)
40+
- Learn more about [how calling works](../../concepts/voice-video-calling/about-call-types.md)

articles/communication-services/toc.yml

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -707,8 +707,16 @@ items:
707707
href: concepts/telephony/outbound-calling.md
708708
- name: Known limitations
709709
href: concepts/telephony/known-limitations-acs-telephony.md
710-
- name: SIP protocol details for direct routing
711-
href: concepts/telephony/direct-routing-sip-specification.md
710+
- name: Troubleshooting
711+
items:
712+
- name: Monitor direct routing
713+
href: concepts/telephony/monitoring-troubleshooting-telephony/monitor-direct-routing.md
714+
- name: Troubleshoot TLS connectivity
715+
href: concepts/telephony/monitoring-troubleshooting-telephony/troubleshoot-tls-certificate-sip-options.md
716+
- name: Troubleshoot outbound calls
717+
href: concepts/telephony/monitoring-troubleshooting-telephony/troubleshoot-outbound-calls.md
718+
- name: SIP protocol details for direct routing
719+
href: concepts/telephony/direct-routing-sip-specification.md
712720
- name: Call Automation
713721
items:
714722
- name: Overview

0 commit comments

Comments
 (0)