"Authentication required" error when pairing cloud sites in VMware Cloud Director Availability
search cancel

"Authentication required" error when pairing cloud sites in VMware Cloud Director Availability

book

Article ID: 314986

calendar_today

Updated On:

Products

VMware Cloud Director VMware Live Recovery VMware vSphere ESXi

Issue/Introduction

  • When you pair cloud sites in the VMware Cloud Director Availability Provider Portal, the task fails and you see the following error:
Authentication required.
  • When you repair cloud sites in the VMware Cloud Director Availability Provider Portal, the task fails and you see the following error on the remote site entry:
Certificate differs from the expected one.
  • In /opt/vmware/h4/cloud/log/cloud.log on the VMware Cloud Director Availability vApp Replication Manager, you may see similar messages:
DEBUG - [UI__##########-####-####-############] [job-59] com.vmware.h4.jobengine.JobExecution     : Task ##########-####-####-############ (WorkflowInfo{type='pair', resourceType='site', resourceId='Provider-Site', isPrivate=false, resourceName='Service Provider Site'}) completed with result VcloudSiteInfo{apiPublicUrl='null', isLocal=false, state=PeerState{incomingCommError=null, outgoingCommError=ApiError{code='RemoteAuthenticationFailure', msg='Authentication failure.', args=[], stacktrace='com.vmware.h4.cloud.api.exceptions.RemoteAuthenticationFailureException: Authentication failure.
    at com.vmware.h4.cloud.peer.client.PeerCloudFactory.lambda$initErrorDeserializer$0(PeerCloudFactory.java:59)
    at com.vmware.rest.client.AbstractRestClient.convert(AbstractRestClient.java:208)
    at com.vmware.rest.client.json.RestClient.exchange(RestClient.java:103)

    ...

2019-08-26 14:47:34.011 ERROR - [UI__###########-####-####-############_Ez] [https-####] c.v.h.c.c.error.ExceptionAdvisorBase     : A GET request from root[###.##.###.##] to /vm-replications/summary?sourceSiteType=vcloud&destinationSiteType=vcloud&site=Tenant-Site failed. 

com.vmware.exception.CertificateMismatchException: java.security.cert.CertificateException: Certificate seen on the network differs from the certificate we expected
    at com.vmware.exception.converter.ClientExceptionConverter.convertException(ClientExceptionConverter.java:50)
    at com.vmware.rest.client.AbstractRestClient.genericExchange(AbstractRestClient.java:146)
    at com.vmware.rest.client.json.RestClient.exchange(RestClient.java:96)
    ...

Note: The preceding log excerpts are only examples. Date, time, and environmental variables may vary depending on your environment.



Environment

VMware Cloud Director Availability 3.0.x
VMware Cloud Director Availability 4.7.5

Cause

This issue can occur when the administrative API session that is used to pair the sites is unable to authenticate because the source IP is not trusted. This can happen because administrative API access is restricted by default from VMware Cloud Director Availability 3.0.1 onwards.

Resolution

To resolve this issue, you can temporarily disable administrative API session restrictions based on source IP in VMware Cloud Director Availability

For each VMware Cloud Director Availability site, perform the following steps:

  1. Log in to the VMware Cloud Director Availability Provider Portal.
  2. In the left pane, click Configuration.
  3. Under Security settings, next to Restrict Admin APIs by source IP click Edit.
  4. In the Restrict Admin APIs by source IP window, select Allow admin access from anywhere and click Apply.

With the administrative APIs allowed from anywhere, pair the sites as per the following steps:

  1. In one site, log into the VMware Cloud Director Availability Provider Portal.
  2. In the left pane, click Sites.
  3. On the Cloud sites page, click New Pairing.
  4. In the New Pairing window, configure the connection to the cloud site, and click Pair.
  5. To complete the pair process, accept the remote vCloud Availability vApp Replication Manager SSL certificate.

Note: Once the sites are successfully paired, the Restrict Admin APIs by source IP setting can be reversed.

Additional Information