<@U04S8PLJWMT> I'm getting such errors when trying...
# ask-ai
s
@kapa.ai I'm getting such errors when trying to set new source or destination:
Copy code
Failed to create pod ion-postgres-check-xxxxxxxxxxxxx
Operation: [patch] for kind: [Pod] with name: [ion-postgres-check-xxxxxxxxxxxxx] in namespace: [airbyte] failed
PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
What could be the issue? I'm using service account for operating Airbyte in my Kubernetes and it has all needed permissions. I'm using chart v2.
k
Based on the error message you're seeing, there are actually two distinct issues that might be occurring: ## 1. Service Account Configuration Issue The error "Failed to create pod" with "Operation: [patch] for kind: [Pod]" suggests a problem with service account configuration. According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/49938), when using Airbyte 1.3.x with a custom service account name (not
airbyte-admin
), the workload-launcher may incorrectly try to use
airbyte-admin
as the service account when creating pods, even though you've specified a different service account in your values.yaml. Workaround: As mentioned in the issue, you can create an additional service account named
airbyte-admin
with the same role bindings as your current service account. This allows the workload-launcher to successfully start pods. ## 2. SSL/TLS Certificate Issue The "PKIX path building failed: unable to find valid certification path to requested target" error indicates an SSL/TLS certificate validation problem. This typically occurs when: - Your Kubernetes cluster uses self-signed certificates or an internal CA - The Java trust store in Airbyte's connector pods doesn't recognize the certificate authority This is a known issue discussed in [this forum post](https://discuss.airbyte.io/t/983) and [this GitHub issue](https://github.com/airbytehq/airbyte/issues/38537). ## Recommended Steps 1. First, verify your service account configuration matches what's expected in your Helm values 2. Check if you need to create the
airbyte-admin
service account as a workaround 3. If the certificate error persists, you may need to configure your Kubernetes cluster's certificate trust or investigate mounting custom trust stores into the connector pods Could you confirm which Airbyte version you're using and whether your service account is named something other than
airbyte-admin
?
A message from kapa.ai
Based on the error message you're seeing, there are actually two distinct issues that might be occurring: ## 1. Service Account Configuration Issue The error "Failed to create pod" with "Operation: [patch] for kind: [Pod]" suggests a problem with service account configuration. According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/49938), when using Airbyte 1.3.x with a custom service account name (not
airbyte-admin
), the workload-launcher may incorrectly try to use
airbyte-admin
as the service account when creating pods, even though you've specified a different service account in your values.yaml. Solution: The issue can be fixed by explicitly defining the ServiceAccount name via the
global.jobs.kube.serviceAccountName
Helm value, as mentioned in [the same issue](https://github.com/airbytehq/airbyte/issues/49938). Temporary Workaround: Create an additional service account named
airbyte-admin
with the same role bindings as your current service account. ## 2. SSL/TLS Certificate Issue The "PKIX path building failed: unable to find valid certification path to requested target" error indicates an SSL/TLS certificate validation problem. This typically occurs when: - Your Kubernetes cluster uses self-signed certificates or an internal CA - The Java trust store in Airbyte's connector pods doesn't recognize the certificate authority This is a known issue discussed in [this forum post](https://discuss.airbyte.io/t/983) and affects various connectors including [MongoDB](https://github.com/airbytehq/airbyte/issues/36781) and [Oracle](https://github.com/airbytehq/airbyte/issues/38537). ## Recommended Steps 1. First, add
global.jobs.kube.serviceAccountName
to your Helm values with your service account name 2. If that doesn't resolve it, try creating an
airbyte-admin
service account as a temporary workaround 3. If the certificate error persists after resolving the service account issue, you may need to configure custom trust stores for your connectors Could you confirm which exact Airbyte version you're using and the name of your service account?
s
@kapa.ai I'm using helm chart v2.0.19. It is using Airbyte 2.0.1
k
A message from kapa.ai
Thank you for providing the version information. You're using Helm chart v2.0.19 with Airbyte 2.0.1. Based on the knowledge sources available, the service account issue I mentioned appears to be specific to Airbyte 1.3.x versions. Since you're on Airbyte 2.0.1, the root cause is more likely the SSL/TLS certificate validation problem indicated by the "PKIX path building failed" error. ## Primary Issue: Certificate Trust The error suggests that when Airbyte tries to create connector pods in your Kubernetes cluster, the Java applications running in those pods cannot validate the SSL certificates used by your Kubernetes API server. This is common when: - Your Kubernetes cluster uses self-signed certificates - Your cluster uses an internal Certificate Authority (CA) - The default Java trust store doesn't include your cluster's CA certificate ## Recommended Actions 1. Verify your Kubernetes cluster's certificate configuration - Check if your cluster is using self-signed or internally-signed certificates 2. Check service account configuration - Even though this is less likely the issue in 2.0.1, ensure your service account has proper RBAC permissions for creating and patching pods 3. Review Helm chart configuration - Make sure your
values.yaml
correctly specifies the service account name under the appropriate configuration keys for chart v2 Unfortunately, the knowledge sources don't contain specific information about how to configure custom trust stores or certificate handling in Airbyte 2.0.x Helm chart v2. You may need to: - Check the [Airbyte documentation](https://docs.airbyte.com) for certificate configuration options in v2 - Open a GitHub issue if this appears to be a bug specific to chart v2 - Consult with your Kubernetes administrator about certificate trust configuration Could you share what type of Kubernetes cluster you're running (EKS, GKE, self-managed, etc.) and whether it uses custom certificates?
s
@kapa.ai one more information I will provide - connector pods are not even start to create. They are not available in cluster at all
k
A message from kapa.ai
Thank you for that important clarification. If the connector pods are not being created at all (not even appearing in the cluster), this changes the diagnosis significantly. ## Root Cause Analysis Based on the error message and the fact that pods aren't being created, the issue is occurring during the pod creation/patch operation itself, not after the pod is running. The "PKIX path building failed" error in this context means: The workload-launcher pod (which is responsible for creating connector pods) cannot communicate with the Kubernetes API server due to SSL certificate validation failure. ## Why This Happens According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/50979), workload pods need proper service account configuration. However, in your case, the workload-launcher itself is failing to create pods because: 1. The workload-launcher pod is trying to make API calls to Kubernetes to create connector pods 2. These API calls fail SSL validation because the Java client in workload-launcher doesn't trust your Kubernetes API server's certificate 3. As a result, the connector pods never get created ## Recommended Actions 1. Check workload-launcher logs - Look at the logs of your
workload-launcher
pod for more detailed error messages:
Copy code
bash    kubectl logs -n airbyte deployment/airbyte-workload-launcher
2. Verify Kubernetes API server certificate - Check if your cluster uses self-signed or internal CA certificates 3. Check workload-launcher service account - Ensure the workload-launcher has the correct service account and RBAC permissions 4. Review Helm values - Verify your service account configuration in your Helm values, particularly for the workload-launcher component Unfortunately, the knowledge sources don't contain specific information about configuring certificate trust for the workload-launcher in Helm chart v2. This may require opening a GitHub issue or consulting the Airbyte documentation for certificate configuration options in your version. Can you share the logs from your workload-launcher pod?
s
@kapa.ai my service account has correct permissions and it is correctly set in workload-launcher values. Workload-launcher logs only shows errors mentioned by me.
k
A message from kapa.ai
Thank you for confirming those details. Since the service account is correctly configured and the workload-launcher logs only show the PKIX certificate error, this confirms that the issue is specifically with SSL/TLS certificate validation between the workload-launcher and the Kubernetes API server. ## The Core Problem The workload-launcher pod's Java client cannot validate your Kubernetes API server's SSL certificate. This prevents it from making the API calls needed to create connector pods, which is why the pods never appear in your cluster. ## Potential Solutions Based on the knowledge sources, here are the approaches that have been discussed for similar certificate issues: 1. Custom Trust Store - According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/38537), some users have tried mounting custom trust stores into pods. However, the issue notes that while you can mount a custom trust store into the worker pod, "there does not appear to be a configuration flag which allows this" for the pods that the worker schedules. 2. Certificate Configuration - The [forum discussion](https://discuss.airbyte.io/t/983) mentions that connectors don't show configuration options for custom trust stores, and users have struggled with self-signed certificates and internal CAs. ## Next Steps Unfortunately, the knowledge sources don't contain specific solutions for configuring certificate trust in the workload-launcher for Helm chart v2.0.19. I recommend: 1. Open a GitHub issue - This appears to be a legitimate bug or missing feature for environments with custom Kubernetes certificates 2. Check if there are any Helm values for configuring Java trust stores or certificate validation in the workload-launcher component 3. Consider if your Kubernetes cluster can use certificates from a public CA as a temporary workaround The knowledge sources indicate this is a known limitation across various Airbyte connectors when dealing with custom certificates, but don't provide a definitive solution for your specific version and component (workload-launcher in chart v2). Would you be able to share your Kubernetes cluster type (EKS, GKE, self-managed) and whether using certificates from a public CA is an option?
s
@kapa.ai I don't believe this is SSL problem. I'm getting the same problem when trying to add custom connector from Docker repository
k
A message from kapa.ai
You're right to question the SSL diagnosis. Looking at the error more carefully and considering that you're getting the same error when adding a custom connector from a Docker repository, this points to a different issue. ## Likely Root Cause: Image Pull Configuration Based on [this GitHub issue](https://github.com/airbytehq/airbyte/issues/52034), the error you're seeing could be related to duplicate imagePullSecrets configuration. The issue shows a very similar error pattern:
Copy code
failed to create typed patch object: .spec.imagePullSecrets: duplicate entries for key [name="seniorsacred"]
This occurs when the same imagePullSecret is specified multiple times in the pod specification, causing the Kubernetes API to reject the pod creation with a 500 error. ## Another Possibility: Image Registry Prefix According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/21123), when using custom connectors or private registries, Airbyte may have issues with image references that don't include the registry prefix. The issue describes problems pulling connector images in Kubernetes environments with strict policies. ## Recommended Actions 1. Check your imagePullSecrets configuration in your Helm values - look for any duplicate entries 2. Verify your custom connector image reference - ensure it includes the full registry path (e.g., `docker.io/your-org/your-connector:tag`) 3. Review the workload-launcher logs more carefully - look for any messages about imagePullSecrets or image pull policies beyond just the PATCH error 4. Check if you have multiple places where imagePullSecrets might be configured (global values, connector-specific values, etc.) Can you share: - How you're specifying your custom connector image in the UI? - Whether you have any imagePullSecrets configured in your Helm values? - The complete error message from workload-launcher if there are any additional details beyond what you initially shared?
s
@kapa.ai I don't have imagePullSecrets set anywhere and there are no more errors in workload-launcher logs. Also, image reference is correct
k
A message from kapa.ai
Thank you for that clarification. Since you don't have imagePullSecrets configured and the image reference is correct, let me reconsider the issue. ## Re-examining the Error Looking back at your original error:
Copy code
Failed to create pod ion-postgres-check-xxxxxxxxxxxxx Operation: [patch] for kind: [Pod] with name: [...] in namespace: [airbyte] failed PKIX path building failed: sun.security.provider.certpath.SunCertPathBuilderException: unable to find valid certification path to requested target
The fact that this error occurs during the PATCH operation (not during image pull or pod startup) and happens consistently across different connector types (including custom ones) strongly suggests this is indeed an SSL/TLS issue with the Kubernetes API server communication. ## The Issue The workload-launcher is successfully creating the initial pod object, but when it tries to PATCH the pod (which is part of Airbyte's pod creation process using server-side apply), the Kubernetes client library fails to validate the API server's certificate. ## What's Happening According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/44443), the pod creation process involves a PATCH operation that can fail for various reasons. In your case, the PKIX error during the PATCH operation indicates the Java Kubernetes client in workload-launcher cannot establish a trusted SSL connection to your Kubernetes API server. ## Questions to Help Diagnose 1. What type of Kubernetes cluster are you running? (EKS, GKE, AKS, self-managed, etc.) 2. Does your cluster use custom or self-signed certificates? 3. Can you check if other Java-based applications in your cluster can successfully interact with the Kubernetes API? 4. Are there any network policies or service mesh configurations that might be interfering with the workload-launcher's API calls? Unfortunately, the knowledge sources don't contain specific configuration options for resolving certificate trust issues in the workload-launcher for Helm chart v2. This appears to be a gap that may require opening a GitHub issue with the Airbyte team.
s
@kapa.ai 1. EKS 2. Custom cert 3. Well, Airbyte itself was deployed without any problem 4. Not sure
k
A message from kapa.ai
Thank you for providing those details. This is very helpful. ## The Issue is Clear Now You're running on EKS with custom certificates, and Airbyte itself deployed successfully. This confirms that: 1. Your service account and RBAC permissions are correct (otherwise Airbyte wouldn't have deployed) 2. The Airbyte control plane components can communicate with the Kubernetes API 3. However, the workload-launcher specifically is having SSL certificate validation issues when trying to create connector pods ## Why This Happens on EKS The key difference is that while the main Airbyte components (server, webapp, etc.) deployed successfully, the workload-launcher uses a Java-based Kubernetes client that needs to trust your EKS cluster's custom certificate authority. The Java trust store in the workload-launcher pod doesn't include your custom CA certificate. ## The Problem According to the knowledge sources, this is a known limitation. As mentioned in [this GitHub issue about Oracle connector](https://github.com/airbytehq/airbyte/issues/38537): > "There does not seem to be a way to tell Airbyte to trust this internal root CA, OR (less ideally) to disable TLS certificate verification altogether." The issue also notes: > "We can indeed mount a custom trust store into the worker pod, but not the pods which the worker pod schedules." ## Recommended Actions 1. Open a GitHub issue - This appears to be a legitimate gap in Airbyte's Helm chart v2 for environments with custom Kubernetes certificates. The workload-launcher needs a way to trust custom CAs. 2. Temporary workaround options to investigate: - Check if there's a way to configure the workload-launcher's Java trust store via Helm values - See if you can use EKS's default certificate instead of your custom one for the API server - Investigate if there are any environment variables or Java system properties you can set for the workload-launcher Unfortunately, the knowledge sources don't contain a definitive solution for configuring certificate trust in the workload-launcher for Helm chart v2 on EKS with custom certificates. This appears to be a missing feature that would need to be addressed by the Airbyte team. Would you like me to help you draft a GitHub issue describing this problem?
s
@kapa.ai small update - we don't use any custom certificate in our EKS.
k
A message from kapa.ai
Thank you for that important correction. If you're not using custom certificates in your EKS cluster, then we need to reconsider the root cause entirely. ## Re-evaluating the Issue Since you're using standard EKS certificates (which should be trusted by default Java trust stores), the "PKIX path building failed" error is puzzling. Let me explore other possibilities: ## Potential Causes 1. Network connectivity issue - The workload-launcher might not be able to reach the Kubernetes API server properly, and the SSL error could be a symptom rather than the root cause 2. Service mesh or network policies - As you mentioned you're "not sure" about network policies, this could be interfering with the workload-launcher's communication with the API server 3. EKS-specific configuration - There might be something specific about your EKS setup (VPC configuration, security groups, etc.) that's causing issues 4. Workload-launcher configuration issue - There might be a misconfiguration in how the workload-launcher is connecting to the Kubernetes API ## Diagnostic Steps 1. Check if workload-launcher can reach the Kubernetes API:
Copy code
bash    kubectl exec -n airbyte deployment/airbyte-workload-launcher -- curl -k https://kubernetes.default.svc
2. Verify there are no network policies blocking the workload-launcher:
Copy code
bash    kubectl get networkpolicies -n airbyte
3. Check if you're using a service mesh (Istio, Linkerd, etc.):
Copy code
bash    kubectl get pods -n airbyte -o jsonpath='{.items[*].spec.containers[*].name}'
Look for sidecar containers like
istio-proxy
or
linkerd-proxy
4. Review your EKS cluster's API server endpoint configuration - Is it public, private, or both? According to [this forum post](https://discuss.airbyte.io/t/2661), one user resolved a similar issue by stopping the use of Istio for Airbyte deployment. Can you check if you have Istio or another service mesh running in your cluster?
s
@kapa.ai ok, so: 1. this curl returns 401 2. no, there is nothing 3. this command returns:
Copy code
airbyte-bootloader-container airbyte-cron airbyte-server-container airbyte-temporal airbyte-worker-container airbyte-workload-api-server-container airbyte-workload-launcher-container
k
A message from kapa.ai
Thank you for running those diagnostics. This is very revealing! ## Key Finding: 401 Unauthorized Error The fact that the curl command returns 401 Unauthorized is significant. This indicates that the workload-launcher pod can reach the Kubernetes API server, but it's not properly authenticated. ## Root Cause Based on [this GitHub issue](https://github.com/airbytehq/airbyte/issues/65567), the 401 error suggests a bearer token mismatch between the worker/workload-launcher and the workload-api-server. According to the issue: > "WORKLOAD_API_BEARER_TOKEN (and header) wasn't aligned between the Worker and the Workload API Server pods." ## The Solution According to the same issue, you need to set matching authentication tokens across your deployments. Here's the fix: 1. Generate a token:
Copy code
bash    TOKEN=$(openssl rand -hex 24)
2. Set the token on all relevant deployments:
Copy code
bash    kubectl -n airbyte set env deployment/airbyte-workload-api-server WORKLOAD_API_AUTH_HEADER=Authorization WORKLOAD_API_BEARER_TOKEN=$TOKEN    kubectl -n airbyte set env deployment/airbyte-worker WORKLOAD_API_AUTH_HEADER=Authorization WORKLOAD_API_BEARER_TOKEN=$TOKEN    kubectl -n airbyte set env deployment/airbyte-server WORKLOAD_API_AUTH_HEADER=Authorization WORKLOAD_API_BEARER_TOKEN=$TOKEN
3. Restart the deployments:
Copy code
bash    kubectl -n airbyte rollout restart deploy/airbyte-workload-api-server airbyte-worker airbyte-server
4. Wait for rollouts to complete:
Copy code
bash    kubectl -n airbyte rollout status deployment airbyte-workload-api-server    kubectl -n airbyte rollout status deployment airbyte-worker    kubectl -n airbyte rollout status deployment airbyte-server
## Why This Happened This is a known issue with Helm chart deployments where the bearer tokens between components can become misaligned, causing authentication failures that manifest as various errors including the PKIX error you were seeing. Try this fix and let me know if it resolves your issue!
s
@kapa.ai this doesn't work either
k
A message from kapa.ai
I apologize that the bearer token fix didn't resolve your issue. Let me reconsider the problem. ## Going Back to the Original Error Since the curl command returned 401 when trying to reach the Kubernetes API server from within the workload-launcher pod, this suggests the workload-launcher's service account token may not be properly configured for authenticating with the Kubernetes API server itself (not the Workload API). ## Key Questions 1. Can you verify the workload-launcher pod has a service account token mounted?
Copy code
bash    kubectl exec -n airbyte deployment/airbyte-workload-launcher -- ls -la /var/run/secrets/kubernetes.io/serviceaccount/
2. What service account is the workload-launcher using?
Copy code
bash    kubectl get pod -n airbyte -l app.kubernetes.io/name=workload-launcher -o jsonpath='{.items[0].spec.serviceAccountName}'
3. Does that service account have the necessary RBAC permissions?
Copy code
bash    kubectl get rolebindings,clusterrolebindings -n airbyte -o json | grep -i <service-account-name>
## Additional Diagnostic According to [this GitHub issue](https://github.com/airbytehq/airbyte/issues/39512), similar "Unauthorized" errors during pod creation can occur when the service account doesn't have proper permissions to PATCH pods. Can you share: - The output of the commands above? - Your complete Helm values configuration (with sensitive data redacted)? - The full stack trace from the workload-launcher logs if there's more detail than what you initially shared? This will help identify whether it's a service account configuration issue, RBAC permissions issue, or something else entirely.