Importing the Cloudera certificate in the Spark cluster

If your environment contains a custom set of trusted certificate authorities, you need to import the Cloudera certificate to your environment and apply it to the node where Spark is running.

  1. Run the following command to export a certificate from the Cloudera environment:
    openssl s_client -showcerts -connect [***CDP-PUBLIC-CLOUD-HOSTNAME***]:443 </dev/null 2>/dev/null | openssl x509 -outform PEM > share.pem
  2. Convert the created share.pem file to share.cert by running the following command:
    openssl x509 -outform der -in share.pem -out share.cert
  3. Import the certificate into the Java Virtual Machine (JVM) of the Spark cluster.
    keytool -importcert -alias cdpcert -keystore /usr/lib/jvm/java-11-openjdk-amd64/lib/security/cacerts -file ${CERT_HOME}/share.cert -storepass changeit -noprompt