Web consoles stays in 'Connecting' status for a long time in VMware Cloud Director
search cancel

Web consoles stays in 'Connecting' status for a long time in VMware Cloud Director

book

Article ID: 404767

calendar_today

Updated On:

Products

VMware Cloud Director

Issue/Introduction

  • Opening web consoles in VMware Cloud Director(VCD) UI shows the 'Connecting' status for a long time and console won't open.
  • The issue is seen in any web browsers,any operating system(OS),for all tenants and any type of users. 
  • Not all virtual machines are affected - some consoles work in the first try itself.
  • New or existing VMs can be affected.
  • VMware Remote Console (VMRC) consoles work as expected.
  • The consoles of the affected VMs can be opened successfully from vCenter(VC) directly.
  • Clearing the browser cache doesn't resolve the issue.
  • From the browser logs > Network tab opened in the tenant portal, there are 2 'acquireMksTicket' requests for the console ticket as below: 

    POST https://www.example.com/api/vApp/vm-########-####-####-####-############/screen/action/acquireMksTicket  

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <MksTicket
    ...
    <Host>www.example.com:443</Host>
        <Vmx></Vmx>
        <Ticket>/cst-12345....--tp-....--</Ticket>
        <Port>443</Port>
    </MksTicket>

    POST https://www.example.com/api/vApp/vm-########-####-####-####-############/screen/action/acquireMksTicket  

    <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
    <MksTicket
    ...
    <Host>https://www.example.com:443</Host>
        <Vmx></Vmx>
        <Ticket>/cst-67890....--tp-....--</Ticket>
        <Port>443</Port>
    </MksTicket>

  • The browser logs > Console tab opened after initiating the web console shows: 

    ²Dispatching ticket request vm-########-####-####-####-############

  • From virtual machine logs, we see both the ticket requests are issued and soon marked as expired.

    vmx - VigorTransportProcessClientPayload: opID=vcd-1#######-####-####-####-############ seq=#####1: Receiving MKS.IssueTicket request.
    DATETHR:MIN:39.136Z In(05) vmx - SOCKET 69 (115) creating new listening socket on port -1
    DATETHR:MIN:39.136Z In(05) vmx - Issuing new webmks ticket 1ticket... (120 seconds)
    DATETHR:MIN:39.136Z In(05) vmx - VigorTransport_ServerSendResponse opID=vcd-1#######-####-####-####-############ seq=#####1: Completed MKS.IssueTicket request with messages in 300 US.
    DATETHR:MIN:39.136Z In(05) vmx - VigorTransportProcessClientPayload: opID=vcd-2#######-####-####-####-############ seq=#####2: Receiving MKS.IssueTicket request.
    DATETHR:MIN:39.136Z In(05) vmx - SOCKET 71 (120) creating new listening socket on port -1
    DATETHR:MIN:39.136Z In(05) vmx - Issuing new webmks ticket 2ticket... (120 seconds)
    DATETHR:MIN:39.136Z In(05) vmx - VigorTransport_ServerSendResponse opID=vcd-2#######-####-####-####-############ seq=#####2: Completed MKS.IssueTicket request with messages in 36 US.
    ...
    DATETHR:MIN:44.531Z In(05) mks - Accepting connection for webmks ticket 1ticket...
    DATETHR:MIN:44.531Z In(05) mks - Expiring webmks ticket 1ticket...
    DATETHR:MIN:44.531Z In(05) mks - Releasing webmks ticket 1ticket...
    ...
    DATETHR:MIN:44.538Z In(05) mks - Accepting connection for webmks ticket 2ticket...
    DATETHR:MIN:44.538Z In(05) mks - Expiring webmks ticket 2ticket...
    DATETHR:MIN:44.538Z In(05) mks - Releasing webmks ticket 2ticket...

Environment

VMware Cloud Director 10.5.1

VMware Cloud Director 10.6

VMware Cloud Director 10.6.0.1

Cause

For the VM with issue, the API response time is significantly higher (around 5+ seconds) than the success case (~300ms). The retry interval to request a console is set to 5 seconds in the affected versions which is not sufficient at times to get the first console request actioned. 

Resolution

The workaround includes:

  1. Close and re-open the web console multiple times until the console loads successfully. Once the console loads successfully, the issue is not seen with that VM again. 
  2. Use VMRC console

To resolve the issue permanently, upgrade to VCD 10.6.1.1 which increases the retry interval from 5s to 8s. 

You can download VCD 10.6.1.1 from the Broadcom Support Portal.

Additional Information

Enable the browser logs and capture it to identify the API errors as per How to collect a HAR log file for troubleshooting Cloud Director issues