Failed to open TCP connection to login.microsoftonline.com:443 (execution expired)

Jun Taka 5 Reputation points
2023-09-04T03:28:15.5866667+00:00

Hello,

We encountered the error as title.

Some connections, not all, to Microsoft like

login.microsoftonline.com:443

*.blob.core.windows.net:443

seem very slow from my Vultr instance.

Do you have any help?

Azure Blob Storage
Azure Blob Storage
An Azure service that stores unstructured data in the cloud as blobs.
2,853 questions
0 comments No comments
{count} votes

2 answers

Sort by: Most helpful
  1. Jun Taka 5 Reputation points
    2023-09-07T01:41:03.48+00:00

    Hello Pranathi, Thank you for your reply.

    Actually, the issue has gone. But I don't know why. I texted with Vultr support. They say it's a Microsoft problem especially IPv6 connection, and Microsoft has changed something. What do you think? Did you make any change?

    I run this perl code to confirm, it's just opens the connection:

    use Benchmark qw(:all);
    use IO::Socket::INET;
    
    for (my $i = 0; $i < 10; $i++) {
      my $t0 = new Benchmark;
      my $socket = new IO::Socket::INET(PeerHost => 'login.microsoftonline.com', PeerPort => '443', Proto => 'tcp');
      my $t1 = new Benchmark;
    
      print "$i: " . timestr(timediff($t1, $t0)) . "\n";
    }
    

    Results:

    0: 0 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    1: 0 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    2: 0 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    3: 131 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    4: 131 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    5: 0 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    6: 131 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    7: 7 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    8: 0 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    9: 130 wallclock secs ( 0.00 usr + 0.00 sys = 0.00 CPU)
    

    Attempt 3, 4, 6 and 9 took more than 2 minutes. So we got some "execution expired" errors, not always.

    Regards,

    1 person found this answer helpful.
    0 comments No comments

  2. Pranathi Panyam_MSFT 1,041 Reputation points Microsoft Employee
    2023-09-06T17:17:54.1133333+00:00

    Hello Jun Taka, Welcome to Microsoft Q&A, thank you for posting your query here!!

    The error message "Failed to open TCP connection to login.microsoftonline.com:443 (execution expired)" typically indicates that there was a problem establishing a network connection to the Microsoft Azure Active Directory (Azure AD) authentication server at login.microsoftonline.com on port 443, which is the default HTTPS port.

    Here are some steps you can take to troubleshoot and resolve this issue:

    Check Your Internet Connection: Ensure that your computer or server has a working internet connection. Try accessing other websites to confirm that your internet connection is not the root cause of the issue.

    Firewall or Proxy: If you are behind a corporate firewall or proxy server, it's possible that these network configurations are blocking the connection to login.microsoftonline.com. Check with your network administrator to ensure that necessary ports and domains are allowed through the firewall or proxy.If you're in a corporate or enterprise environment, there may be specific firewall rules or security policies that affect outbound connections. Check with your organization's IT or security team to ensure there are no restrictions on outbound connections to Azure AD services.

    Network Latency: High network latency or network congestion can cause connection timeouts. You can test network latency to login.microsoftonline.com using tools like ping or traceroute. If you observe high latency or packet loss, it could be a network-related issue.

    If the issue persists after checking these steps, it may be helpful to involve your IT department or network administrator, as they can provide further assistance in diagnosing and resolving network connectivity issues. Additionally, monitoring network logs or using network diagnostic tools may help pinpoint the cause of the problem.

    Please "Accept as Answer" if it helped so it can help others in community looking for help on similar topics.

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.