<@U04S8PLJWMT> Our connection went on stuck for ho...
# ask-ai
f
@kapa.ai Our connection went on stuck for hours until we've stopped it with the following log
Copy code
025-08-10 12:39:17 platform > Using job log path: /workspace/163542/0/logs.log
2025-08-10 12:39:17 platform > Executing worker wrapper. Airbyte version: 1.2.0
2025-08-10 12:39:17 platform > Creating workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync
2025-08-10 12:39:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:41:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:43:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:45:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:47:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:49:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
2025-08-10 12:51:22 platform > Workload 48671749-0a89-4541-8f8e-fcb8a0db01b1_163542_0_sync is pending
How can I go deeper understanding what is the issue?
k
When a sync job in Airbyte remains in the "pending" state for an extended period, as shown in your logs, it typically indicates an issue with resource availability, scheduling, or underlying infrastructure (such as Kubernetes pods not being scheduled or started). Here are steps and considerations to help you dig deeper: 1. Check Pod and Resource Status - If you are running Airbyte on Kubernetes, verify whether the worker pods for the sync are being scheduled and started. A common cause for jobs being stuck in "pending" is that the required pods cannot be created due to insufficient resources (CPU, memory) or other scheduling constraints. You can check pod status with:
Copy code
kubectl get pods -n <your-namespace>
- Look for pods in "Pending" state and describe them to see why they are not starting:
Copy code
kubectl describe pod <pod-name> -n <your-namespace>
2. Check Storage (MinIO) and Disk Space - Several users have reported that Airbyte syncs can hang if the MinIO storage (used for job logs and artifacts) is full. The default persistent volume claim (PVC) for MinIO is often only 500MB, which can fill up quickly in busy environments. If MinIO runs out of space, new jobs may not start or may hang in pending state. You can resolve this by: - Increasing the MinIO PVC size in your Helm values.yaml:
Copy code
yaml        minio:          storage:            volumeClaimValue: 2Gi
- Deleting old logs from MinIO, especially under
/storage/airbyte-storage/job-logging/workspace
and
/storage/airbyte-storage/workload/output
if you need a quick fix. Be aware this will remove historical logs. - Consider setting
TEMPORAL_HISTORY_RETENTION_IN_DAYS
to a lower value (e.g., 7) to reduce log retention and prevent future overflows [All sync jobs hanging indefinitely](https://github.com/airbytehq/airbyte/issues/55812). 3. Review Airbyte and Kubernetes Logs - Check the Airbyte platform and worker logs for errors or warnings around the time the job was scheduled. Look for messages about resource exhaustion, pod scheduling failures, or storage issues. - If you see errors like "No pod found running for workload" or repeated "pending" messages, it further points to pod scheduling or resource issues [Sync Concurrency configuration](https://github.com/airbytehq/airbyte/issues/49925). 4. Check for Platform or Version-Specific Issues - Some Airbyte versions have had bugs or resource management issues that could cause jobs to hang. Upgrading to the latest stable version is often recommended, as many such issues have been addressed in recent releases [Sync usually works, but randomly hangs forever](https://discuss.airbyte.io/t/2308). 5. Other Common Causes - Network issues, node maintenance, or Kubernetes cluster problems can also cause jobs to hang in pending. Review your cluster health and recent events. Summary of Next Steps: - Check Kubernetes pod status and events. - Verify MinIO (or other storage) is not full. - Review Airbyte and platform logs for errors. - Consider increasing resource allocations or upgrading Airbyte if you are on an older version. If after these checks the issue persists, sharing the relevant logs (from both Airbyte and Kubernetes) will help further diagnose the root cause. Let me know if you need specific commands or help interpreting any logs you find!
f
@kapa.ai I found on kubectl that one pending pod has
0/1 nodes are available: 1 Insufficient cpu. preemption: 0/1 nodes are available: 1 No preemption victims found for incoming pod.
k
A message from kapa.ai
The message
0/1 nodes are available: 1 Insufficient cpu. preemption: 0/1 nodes are available: 1 No preemption victims found for incoming pod.
from Kubernetes means that your Airbyte sync job pod is pending because there is not enough available CPU on any node in your cluster to schedule the pod. This is a common issue when the resource requests or limits for Airbyte jobs are set too high, or when your cluster is already fully utilized. According to Airbyte documentation and user reports, you can address this by: 1. Lowering Resource Requests/Limits: Adjust the CPU and memory requests/limits for Airbyte job pods in your
values.yaml
file. For example:
Copy code
yaml    global:      jobs:        resources:          requests:            cpu: 75m            memory: 150Mi          limits:            cpu: 150m            memory: 500Mi
This will reduce the minimum resources required for each job pod, making it easier for Kubernetes to schedule them if your nodes are under heavy load or are small in size. [Scaling Airbyte After Installation](https://docs.airbyte.com/platform/enterprise-setup/scaling-airbyte) [Configuring Connector Resources](https://docs.airbyte.com/platform/operator-guides/configuring-connector-resources) 2. Scaling Your Cluster: If you consistently see this issue, you may need to add more nodes or increase the size of your existing nodes to provide more available CPU for Airbyte jobs. The documentation recommends ensuring your cluster can handle at least
2 x <number-of-possible-concurrent-connections>
pods at once for sync jobs, as each sync typically uses two workers (source and destination) [Scaling Airbyte](https://docs.airbyte.com/platform/operator-guides/scaling-airbyte). 3. Check for Stuck or Resource-Hogging Pods: Sometimes, other pods may be consuming more resources than expected, preventing new pods from being scheduled. Review your cluster's resource usage and consider evicting or resizing other workloads if necessary. Summary: Your Airbyte sync job is pending due to insufficient CPU resources in your Kubernetes cluster. Lower the job resource requests/limits or scale your cluster to resolve this issue. For more details, see the official Airbyte documentation on scaling and configuring connector resources.
f
@kapa.ai I've restarted the job and now went fine, is there the possibility to retrieve pod logs for specific connection job in some way?
k
A message from kapa.ai
Yes, you can retrieve pod logs for a specific connection job in Airbyte running on Kubernetes. Here’s how you can do it: 1. Identify the Pod: First, find the pod associated with your specific job. You can list pods in your namespace and look for names that include the job or connection ID.
Copy code
bash    kubectl get pods -n <namespace>
2. View Logs Directly: Once you have the pod name, you can view the logs with:
Copy code
bash    kubectl logs <pod-name> -n <namespace>
3. Browse or Copy Output Files: If you want to browse or copy specific output files (such as logs or config files) from the pod, you can exec into the pod or use `kubectl cp`: - To browse:
Copy code
bash      kubectl exec -it <pod-name> -n <namespace> -c main bash
- To copy a file:
Copy code
bash      kubectl cp <namespace>/<pod-name>:/path/to/file ./local-file
For example, to copy a catalog file:
Copy code
bash    kubectl cp jobs/normalization-worker-3605-0-sxtox:/config/destination_catalog.json ./catalog.json
More details and examples are available in the Airbyte documentation [here](https://docs.airbyte.com/platform/operator-guides/browsing-output-logs#browsing-on-kubernetes). Note: If the pod has already completed and is no longer running, you may not be able to exec into it. In such cases, you can still retrieve logs with
kubectl logs
as long as the pod object exists and logs are retained by your cluster. If the pod has been deleted, the logs are no longer accessible unless you have configured external log storage. For more information, see the official documentation: [Browsing logs on Kubernetes](https://docs.airbyte.com/platform/operator-guides/browsing-output-logs#browsing-on-kubernetes).
f
@kapa.ai is it possible to set a maximum number of retries for "Workload pending"?
k
A message from kapa.ai
I'm sorry, but the knowledge sources do not mention any configuration option to set a maximum number of retries specifically for the "Workload pending" state in Airbyte. The available retry configurations in Airbyte focus on sync job attempts and backoff intervals after failures during job execution, not on how many times a workload can remain or retry while pending scheduling in the cluster. You can configure the number of sync job attempts and backoff behavior using environment variables such as
SYNC_JOB_MAX_ATTEMPTS
and related settings, but these apply to job execution failures, not to the pending state due to resource constraints or scheduling issues [Configuring Airbyte - Jobs](https://docs.airbyte.com/platform/operator-guides/configuring-airbyte#jobs). If you need to control how long a job can remain pending, you may need to manage this at the Kubernetes level (e.g., with pod timeouts or cluster autoscaling), but this is not covered in the Airbyte documentation provided.