Les appels d'API échouent et renvoient des erreurs d'expiration de délai
Restez organisé à l'aide des collections
Enregistrez et classez les contenus selon vos préférences.
Vous consultez la documentation d'Apigee et d'Apigee hybrid. Consultez la documentation d'Apigee Edge.
Symptôme
Vous pouvez observer l'un des symptômes suivants :
Les applications clientes reçoivent des erreurs d'expiration de délai en réponse aux appels d'API dans Apigee hybrid.
Vous observez des erreurs telles que Error from server (invalid) ou The Job
"apigee-resources-install" is invalid lors de l'application de la configuration (overrides.yaml)) au cluster pendant l'installation d'Apigee hybrid.
Messages d'erreur
Vous pouvez rencontrer l'une des erreurs suivantes :
Réponse d'erreur aux appels d'API
Les requêtes API sur Apigee hybrid peuvent échouer avec le message d'erreur suivant :
* Connection failed
* connect to 34.84.67.39 port 443 failed: Operation timed out
* Failed to connect to example.apis.com port 443: Operation timed out
* Closing connection 0
curl: (7) Failed to connect to example.apis.com port 443: Operation timed out
Erreurs observées lors de l'application de la configuration (overrides.yaml) aux clusters.
Vous pouvez observer l'une des erreurs suivantes lors de l'application de la configuration (fichier overrides.yaml) aux clusters lors de l'installation :
Erreur #1
apigeectl init -f overrides/overrides.yaml
...
...
Error from server (Invalid): error when applying patch:
to:
Resource: "batch/v1, Resource=jobs", GroupVersionKind: "batch/v1, Kind=Job"
Name: "istio-init-crd-10-1.4.6", Namespace: "istio-system"
to:
Resource: "batch/v1, Resource=jobs", GroupVersionKind: "batch/v1, Kind=Job"
Name: "istio-init-crd-11-1.4.6", Namespace: "istio-system"
to:
Resource: "batch/v1, Resource=jobs", GroupVersionKind: "batch/v1, Kind=Job"
Name: "istio-init-crd-14-1.4.6", Namespace: "istio-system"
Ces erreurs peuvent se produire si le service istio-ingressgateway est à l'état pending et ne peut pas être associé à une adresse IP externe comme indiqué ci-dessous :
kubectl get services -n istio-system
NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE
istio-ingressgateway LoadBalancer 10.198.5.104 <pending> 15020:31927/TCP, 12h
80:31381/TCP,
443:31391/TCP,
31400:31401/TCP,
15443:32623/TCP
Le service istio-ingressgateway peut présenter l'état pending pour les raisons suivantes :
Les tâches incomplete/erroneous dans l'espace de noms istio-system peuvent faire basculer le service istio-ingressgateway vers l'état pending indéfiniment et empêcher sa liaison à une adresse IP externe.
Les tâches incomplete dans l'espace de noms apigee-system peuvent faire basculer le service istio- ingressgateway vers l'état pending indéfiniment et empêcher sa liaison à une adresse IP externe.
Une plage d'adresses IP incorrecte peut être configurée dans le fichier istio-operator.yaml et faire basculer le service istio-ingressgateway vers l'état pending indéfiniment, ce qui empêche la liaison à une adresse IP externe pendant l'installation.
Cause : des tâches dans l'espace de noms istio-system sont en état d'erreur/en attente.
Diagnostic
Vérifiez l'état des tâches dans l'espace de noms istio-system à l'aide de la commande suivante :
kubectl get jobs -n istio-system
L'état des tâches doit être complete. Si l'état des tâches est erroneous/pending, il s'agit de la cause du problème.
Solution
Si l'une des tâches présente l'état pending ou erroneous, supprimez-la à l'aide de la commande suivante :
Réexécutez l'installation en appliquant le fichier overrides.yaml :
apigeectl apply -f overrides.yaml
Cause : la tâche apigee-resources-install dans l'espace de noms apigee-system peut se trouver dans un état d'erreur.
Diagnostic
Vérifiez l'état des tâches dans l'espace de noms apigee-system à l'aide de la commande suivante :
kubectl get jobs -n apigee-system
L'état des tâches doit être complete. Si l'état des tâches est erroneous/pending, il s'agit de la cause du problème. L'exemple de résultat suivant montre que la tâche apigee-resources-install a abouti.
kubectl get jobs -n apigee-system
NAME COMPLETIONS DURATION AGE
apigee-resources-install 1/1 23s 16d
Solution
Si les tâches sont à l'état pending ou erroneous, supprimez-les à l'aide de la commande suivante :
Réexécutez l'installation en appliquant le fichier overrides.yaml :
apigeectl apply -f overrides.yaml
Cause : une plage d'adresses IP incorrecte est attribuée à l'équilibreur de charge externe.
Diagnostic
Vérifiez l'adresse IP configurée pour l'équilibreur de charge dans le fichier istio-
operator.yaml. Par exemple, l'extrait suivant indique l'emplacement du fichier istio-operator.yaml dans lequel l'adresse IP est configurée :
Le service istio-ingressgateway est configuré en tant qu'équilibreur de charge (indiqué par type) dans le fichier istio-operator.yaml. Lors de l'installation d'ASM, un équilibreur de charge est créé avec l'adresse IP configurée et connecté de manière à communiquer avec le service istio-
ingressgateway. Par conséquent, l'adresse IP configurée doit être correcte et réservée à l'équilibreur de charge.
Contactez votre équipe réseau et vérifiez que l'adresse IP configurée pour loadBalancerIP est correcte. Si l'adresse est incorrecte, le service d'équilibrage de charge ne pourra pas s'associer à l'adresse IP. Dans une telle situation, le service istio-ingressgateway reste indéfiniment à l'état pending.
Solution
Collaborez avec votre équipe réseau et configurez l'adresse IP correcte dans le fichier istio-
operator.yaml.
Réexécutez l'installation d'ASM et appliquez le fichier overrides.yaml :
apigeectl apply -f overrides.yaml
Vous devez collecter des informations de diagnostic
Si le problème persiste, même après avoir suivi les instructions ci-dessus, rassemblez les informations de diagnostic suivantes, puis contactez Google Cloud Customer Care :
L'ID de projet Google Cloud
Nom de l'organisation Apigee Hybrid
Nom du cluster Kubernetes
Nom du projet Google Cloud si le cluster Kubernetes se trouve dans un autre projet Google Cloud.
Le fichier overrides.yaml
Le fichier Istio-operator .yaml utilisé lors de l'installation d'ASM.
Collectez les journaux de chaque pod istio-ingressgateway dans l'espace de noms istio-system :
Collectez la description de chaque pod dans l'espace de noms istio-system :
kubectl describe pod NAME_OF_ISTIO_INGRESSGATEWAY_POD -n istio-system > /tmp/NAME_OF_ISTIO_INGRESSGATEWAY_POD.yaml
Collectez la liste des services dans l'espace de noms istio-system :
kubectl get svc -n istio-system
Sauf indication contraire, le contenu de cette page est régi par une licence Creative Commons Attribution 4.0, et les échantillons de code sont régis par une licence Apache 2.0. Pour en savoir plus, consultez les Règles du site Google Developers. Java est une marque déposée d'Oracle et/ou de ses sociétés affiliées.
Dernière mise à jour le 2025/09/04 (UTC).
[[["Facile à comprendre","easyToUnderstand","thumb-up"],["J'ai pu résoudre mon problème","solvedMyProblem","thumb-up"],["Autre","otherUp","thumb-up"]],[["Difficile à comprendre","hardToUnderstand","thumb-down"],["Informations ou exemple de code incorrects","incorrectInformationOrSampleCode","thumb-down"],["Il n'y a pas l'information/les exemples dont j'ai besoin","missingTheInformationSamplesINeed","thumb-down"],["Problème de traduction","translationIssue","thumb-down"],["Autre","otherDown","thumb-down"]],["Dernière mise à jour le 2025/09/04 (UTC)."],[[["\u003cp\u003eThis document addresses issues where Apigee hybrid API calls time out or configuration applications to the cluster fail.\u003c/p\u003e\n"],["\u003cp\u003eThe primary symptoms of these issues include timeout errors for client applications and specific errors during the application of \u003ccode\u003eoverrides.yaml\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eThe root cause of these symptoms is often the \u003ccode\u003eistio-ingressgateway\u003c/code\u003e service being in a \u003ccode\u003epending\u003c/code\u003e state and unable to bind to an external IP address.\u003c/p\u003e\n"],["\u003cp\u003eSolutions involve checking and resolving incomplete or erroneous jobs in the \u003ccode\u003eistio-system\u003c/code\u003e or \u003ccode\u003eapigee-system\u003c/code\u003e namespaces and ensuring the correct IP address range is configured for the external load balancer.\u003c/p\u003e\n"],["\u003cp\u003eIf the problem persists, diagnostic information such as logs, service lists, project IDs, and configuration files should be collected for Google Cloud Customer Care assistance.\u003c/p\u003e\n"]]],[],null,["# API calls fail with timeout errors\n\n*You're viewing **Apigee** and **Apigee hybrid** documentation.\nView [Apigee Edge](https://docs.apigee.com/api-platform/troubleshoot/404-support-d) documentation.*\n| **Note:** This document is applicable for Apigee hybrid users only.\n\nSymptom\n-------\n\n\nYou may observe one of the following symptoms:\n\n1. The client applications get timeout errors as a response for API calls on Apigee hybrid.\n2. You observe errors such as `Error from server (invalid)` or `The Job\n \"apigee-resources-install\" is invalid` while applying configuration (`overrides.yaml`) to the cluster during hybrid installation.\n\nError messages\n--------------\n\n\nYou may observe one of the following errors:\n\n### Error response to API calls\n\n\nThe API requests on Apigee hybrid may fail with the following error message: \n\n```scdoc\n* Connection failed\n* connect to 34.84.67.39 port 443 failed: Operation timed out\n* Failed to connect to example.apis.com port 443: Operation timed out\n* Closing connection 0\ncurl: (7) Failed to connect to example.apis.com port 443: Operation timed out\n```\n\n### Errors observed while applying configuration (overrides.yaml) to clusters\n\n\nYou may observe one of the following errors while applying configuration\n(`overrides.yaml` file) to clusters during the installation: \n\n### Error #1\n\n```\nhelm upgrade operator apigee-operator/ \\\n --install \\\n --create-namespace \\\n --namespace APIGEE_NAMESPACE \\\n --atomic \\\n -f OVERRIDES_FILE\n```\n\n\u003cbr /\u003e\n\n```text\n...\n...\nError from server (Invalid): error when applying patch:\nto:\nResource: \"batch/v1, Resource=jobs\", GroupVersionKind: \"batch/v1, Kind=Job\"\nName: \"istio-init-crd-10-1.4.6\", Namespace: \"istio-system\"\nto:\nResource: \"batch/v1, Resource=jobs\", GroupVersionKind: \"batch/v1, Kind=Job\"\nName: \"istio-init-crd-11-1.4.6\", Namespace: \"istio-system\"\nto:\nResource: \"batch/v1, Resource=jobs\", GroupVersionKind: \"batch/v1, Kind=Job\"\nName: \"istio-init-crd-14-1.4.6\", Namespace: \"istio-system\"\n```\n\n### Error #2\n\n```\nhelm upgrade operator apigee-operator/ \\\n--install \\\n--create-namespace \\\n--namespace APIGEE_NAMESPACE \\\n--atomic \\\n-f OVERRIDES_FILE\n```\n\n\u003cbr /\u003e\n\n```carbon\n...\n...\nThe Job \"apigee-resources-install\" is invalid: spec.template: Invalid value:\ncore.PodTemplateSpec{ObjectMeta:v1.ObjectMeta{Name:\"apigee-resources-install\",\nGenerateName:\"\", Namespace:\"\", SelfLink:\"\", UID:\"\", ResourceVersion:\"\",\nGeneration:0,\n```\n\nPossible causes\n---------------\n\n\nThese errors can happen if the `istio-ingressgateway` service is in a\n`pending` state and unable to bind to an external IP address as shown below: \n\n```\nkubectl get services -n istio-system\nNAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE\nistio-ingressgateway LoadBalancer 10.198.5.104 \u003cpending\u003e 15020:31927/TCP, 12h\n 80:31381/TCP,\n 443:31391/TCP,\n 31400:31401/TCP,\n 15443:32623/TCP\n```\n\n\nThe possible causes for the `istio-ingressgateway` service to be in a\n`pending` state are as follows:\n\nCause: Jobs in istio-system namespace in erroneous/pending state\n----------------------------------------------------------------\n\n### Diagnosis\n\n1. Check the status of the jobs in the `istio-system` namespace using the following command: \n\n ```\n kubectl get jobs -n istio-system\n ```\n2. The status of the jobs must be `complete`. If the status of the jobs is in an `erroneous/pending` state, then that's the cause of this problem.\n\n### Resolution\n\n1. If any of the jobs are in the `pending` or `erroneous` state, delete them using the following command: \n\n ```\n kubectl -n istio-system delete job JOB_NAME_FROM_STEP_1\n ```\n2. Re-run the installation by applying the `overrides.yaml` file:\n\n\n Update the `apigee-serving-cert` using\n [Helm](/apigee/docs/hybrid/latest/helm-reference): \n\n ```\n helm install operator apigee-operator/\n --namespace APIGEE_NAMESPACE \\\n --atomic \\\n -f OVERRIDES_FILE \\\n --dry-run=server\n ```\n\n Make sure to include all of the settings shown, including `--atomic`\n so that the action rolls back on failure.\n\n Install the chart: \n\n ```\n helm upgrade operator apigee-operator/\n --namespace APIGEE_NAMESPACE \\\n --atomic \\\n -f OVERRIDES_FILE\n ```\n\nCause: apigee-resources-install job in the apigee-system namespace may be in erroneous state\n--------------------------------------------------------------------------------------------\n\n| **Note:** The `apigee-resources-install` job is not part of hybrid versions 1.13 and later.\n\n### Diagnosis\n\n1. Check the status of the jobs in the `apigee-system` namespace using the following command: \n\n ```\n kubectl get jobs -n apigee-system\n ```\n2. The status of the jobs must be `complete`. If the status of the jobs is in an `erroneous/pending` state, then that's the cause of this problem. The following sample output shows that the job `apigee-resources-install `is successfully completed. \n\n ```\n kubectl get jobs -n apigee-system\n NAME COMPLETIONS DURATION AGE\n apigee-resources-install 1/1 23s 16d\n ```\n\n### Resolution\n\n1. If the jobs are in the `pending` or `erroneous` state, delete them using the following command: \n\n ```\n kubectl -n apigee-system delete job JOB_NAME_FROM_STEP_1\n ```\n2. Re-run the installation by applying the `overrides.yaml` file: \n\n ```\n apigeectl apply -f overrides.yaml\n ```\n\nCause: Incorrect IP address range assigned to external load balancer\n--------------------------------------------------------------------\n\n### Diagnosis\n\n1. Check the IP address configured for the load balancer in the `istio-\n operator.yaml` file. For example, the following snippet shows the location in the `istio-operator.yaml` file where the IP address is configured: \n\n ```gdscript\n -name: istio-ingressgateway\n enabled: true\n k8s:\n service:\n type: LoadBalancer\n loadBalancerIP: 10.195.24.23\n ```\n2. The `istio-ingressgateway` service is configured as a load balancer (indicated by type) in the `istio-operator.yaml` file. During the ASM installation, a load balancer is created with the configured IP address and wired to communicate with the `istio-\n ingressgateway` service. Therefore, the IP address configured should be correct and reserved for the load balancer.\n3. Engage your network team and verify that the IP address configured for `loadBalancerIP` is correct. If it is incorrect, then the load balancer service will not be able to bind to the IP address. This causes the `istio-ingressgateway` service to be in the `pending` state forever.\n\n### Resolution\n\n1. Work with your network team and configure the correct IP address in the `istio-\n operator.yaml` file.\n2. Re-run the installation for the [Apigee ingress gateway](/apigee/docs/hybrid/latest/managing-ingress) and apply the `overrides.yaml` file: \n\n ```\n helm upgrade $ORG_NAME apigee-org/ \\\n --install \\\n --namespace APIGEE_NAMESPACE \\\n --atomic \\\n -f OVERRIDES_FILE\n ```\n\nMust gather diagnostic information\n----------------------------------\n\n\nIf the problem persists even after following the above instructions, gather the following\ndiagnostic information and then contact [Google Cloud Customer Care](https://cloud.google.com/support-hub/):\n\n1. The Google Cloud Project ID\n2. The name of the Apigee hybrid organization\n3. Kubernetes Cluster name\n4. Google Cloud project name if kubernetes cluster resides in different Google Cloud project\n5. The `overrides.yaml` file\n6. The `Istio-operator .yaml` file used during the ASM installation.\n7. Collect the logs from each `istio-ingressgateway` pod in the `istio-system` namespace: \n\n ```\n kubectl logs NAME_OF_ISTIO_INGRESSGATEWAY_POD -n istio-system \u003e /tmp/NAME_OF_ISTIO_INGRESSGATEWAY_POD.log\n ```\n8. Collect the description of the each pod in the `istio-system` namespace: \n\n ```\n kubectl describe pod NAME_OF_ISTIO_INGRESSGATEWAY_POD -n istio-system \u003e /tmp/NAME_OF_ISTIO_INGRESSGATEWAY_POD.yaml\n ```\n9. Collect the list of services in the `istio-system` namespace: \n\n ```\n kubectl get svc -n istio-system\n ```"]]