Fails to open a console in vSphere web client of virtual machine which name contains non-ASCII characters
search cancel

Fails to open a console in vSphere web client of virtual machine which name contains non-ASCII characters

book

Article ID: 338633

calendar_today

Updated On:

Products

VMware vCenter Server

Issue/Introduction

Symptoms:
  • When you open the console of a virtual machine which name contains non-ASCII characters (etc, the Chinese, Japanese, Korean) from vSphere web client, you will see a black screen with a message:
      The console has been disconnected. Close this window and re-launch the console to reconnect.
  • The console could be opened successfully in VMRC and vSphere Client.
  • In the C:\ProgramData\VMware\vCenterServer\logs\vsphere-client\logs\vsphere_client_virgo.log file, you see entries similar to:
     [2017-10-18T10:53:33.403+08:00] [ERROR] http-bio-9443-exec-10 o.a.c.c.C.[.[localhost].[/vsphere-client].[AuthdAdapter] Servlet.service() for servlet [AuthdAdapter]       in context with path [/vsphere-client] threw exception java.lang.RuntimeException: AuthdException: 502 Input not in UTF-8 encoding.
     [2017-10-25T14:35:46.597+08:00] [ERROR] http-bio-9443-exec-10 o.a.c.c.C.[.[localhost].[/vsphere-client].[AuthdAdapter] Servlet.service() for servlet                     [AuthdAdapter] in context with path [/vsphere-client] threw exception java.lang.RuntimeException: AuthdException: 501 Command 'CONNECT/vmfs/volumes/59229873-             898df66d-750d-005056b6b89d/??/??.vmx' not authorized for specified VM


 
 


Environment

VMware vCenter Server 6.x
VMware vCenter Server 6.0.x

Cause

The problem is during Authd handshake. The Socket InputStream is not able to decode UTF-8 properly on CISWIN machines.

Resolution

This is a known issue affecting vCenter Server 6.x
 
To workaround the issue, JVM needs to be started with "-Dfile.encoding=UTF-8" parameter which will set the right character encoding for non-ASCII.
  1. Stop  VMware vSphere Web Client service on vCenter server.
  2. Backup JVM configuration file located under the path "C:\Program Files\VMware\vCenter Server\WebClient\server\wrapper\conf\wrapper.conf"
  3. Add below lines in the JVM configuration file of vSphere Web Client
           # Set the default charset
       wrapper.java.additional.*=-Dfile.encoding=UTF-8


            Note: The '*' stands for a number. It should be equal to the last number of ‘wrapper.java.additional',parameter in JVM configuration file plus one.  
                      For example, the last number of this parameter is 'wrapper.java.additional.19', the '*' should be 20. So the full parameter is wrapper.java.addtional.20=-Dfile.encoding=UTF-8
       4. Start VMware vSphere Web Client service.
       5. Login vSphere Web Client and try to open console of the virtual machine.

In vCenter 6.5:

  1. The command line arguments for vsphere-client is,
C:\ProgramData\VMware\vCenterServer\cfg\vmware-vmon\svcCfgfiles\vsphere-client.json
  1. Find the line "-classpath", and add "-Dfile.encoding=UTF-8" before it.
  2. Start VMware vSphere Web Client service.
  3. Login vSphere Web Client and try to open console of the virtual machine.

 



Additional Information