RouteController failed to create a route on GKE

微笑、不失礼 提交于 2020-01-06 08:00:45

问题


I have a cluster on GKE whose node pool I create when I want to use the cluster, and delete when I'm done with it.

It's a two node cluster with the master in europe-west2-a and with and whose node zones are europe-west2-a and europe-west2-b.

The most recent creation resulted in the node in zone B failing with NetworkUnavailable because RouteController failed to create a route. The reason was because Could not create route xxx 10.244.1.0/24 for node xxx after 342.263706ms: instance not found.

Why would this be happening all of a sudden, and what can I do to fix it?!


回答1:


You didn't mention which version of GKE you are using so just for clarification:

Changes in access scopes Beginning with Kubernetes version 1.10, gcloud and GCP Console no longer grants the compute-rw access scope on new clusters and new node pools by default. Furthermore, if --scopes is specified in gcloud container create, gcloud no longer silently adds compute-rw or storage-ro.

In any case you can still revert to legacy access scopes but this is not recommended approach.

Hope this help.




回答2:


With gke 1.13.6-gke.13, some of the default scopes were changed, including the compute-rw scope being removed. I think that due to the age of the cluster, this scope was necessary for a route to be correctly created between nodes in a node pool.

In the end, my gcloud creation command had these scopes:

--scopes https://www.googleapis.com/auth/projecthosting,storage-rw,monitoring,trace,compute-rw



来源:https://stackoverflow.com/questions/56722303/routecontroller-failed-to-create-a-route-on-gke

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!