The Analytics Agent startup fails with the following error in the Analytics Agent logs:
[2017-06-02T13:09:47,657+02:00] [ERROR] [analytics-agent-sync-thread-0] [c.a.a.agent.sync.ErrorMessageHelper] Analytics agent failed to connect to the controller registration endpoint. com.appdynamics.analytics.shared.rest.exceptions.ClientException: Could not execute request to https://<controller host>/rest/analytics/agent/register ... ... Caused by: sun.security.validator.ValidatorException: PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
The issue occurs when using a self-signed certificate for the Controller.
The Analytics Agent uses a truststore for the JRE to validate the certificate of the connecting server. The truststore does not have self-signed certificates added to the store by default.
Import the client certificate to the JRE truststore, which is located in the Java directory used by the Analytics Agentby default.