简体   繁体   English

istio 无法安装在通过 AWS 中的 Kops 构建的 Kubernetes 集群中

[英]istio is failing to install in a Kubernetes cluster built via Kops in AWS

I can't get the demo profile to work with istioctl.我无法让演示配置文件与 istioctl 一起使用。 It seems like istioctl is having trouble creating IngressGateway and the AddonComponents.似乎 istioctl 在创建 IngressGateway 和 AddonComponents 时遇到了问题。 I have tried doing the helm installation with similar issues.我试过用类似的问题进行 helm 安装。 I did a fresh k8s cluster from kops and the same issue.我从 kops 做了一个新的 k8s 集群和同样的问题。 Any help debugging this issue would be greatly appreciated.任何调试此问题的帮助将不胜感激。

I am following these instructions.我正在遵循这些说明。 https://istio.io/docs/setup/getting-started/#download https://istio.io/docs/setup/getting-started/#download

I am running我在跑步

 istioctl manifest apply --set profile=demo --logtostderr

This is the output这是 output

2020-04-06T19:59:24.951136Z info    Detected that your cluster does not support third party JWT authentication. Falling back to less secure first party JWT. See https://istio.io/docs/ops/best-practices/security/#configure-third-party-service-account-tokens for details.
- Applying manifest for component Base...
✔ Finished applying manifest for component Base.
- Applying manifest for component Pilot...
✔ Finished applying manifest for component Pilot.
- Applying manifest for component IngressGateways...
- Applying manifest for component EgressGateways...
- Applying manifest for component AddonComponents...
✔ Finished applying manifest for component EgressGateways.
2020-04-06T20:00:11.501795Z error   installer   error running kubectl: exit status 1
✘ Finished applying manifest for component AddonComponents.
2020-04-06T20:00:40.418396Z error   installer   error running kubectl: exit status 1
✘ Finished applying manifest for component IngressGateways.
2020-04-06T20:00:40.421746Z info    
Component AddonComponents - manifest apply returned the following errors:
2020-04-06T20:00:40.421823Z info    Error: error running kubectl: exit status 1

2020-04-06T20:00:40.421884Z info    Error detail:


Error from server (Timeout): error when creating "STDIN": Timeout: request did not complete within requested timeout 30s (repeated 1 times)


clusterrole.rbac.authorization.k8s.io/kiali unchanged
clusterrole.rbac.authorization.k8s.io/kiali-viewer unchanged
clusterrole.rbac.authorization.k8s.io/prometheus-istio-system unchanged
clusterrolebinding.rbac.authorization.k8s.io/kiali unchanged
clusterrolebinding.rbac.authorization.k8s.io/prometheus-istio-system unchanged

serviceaccount/kiali-service-account unchanged
serviceaccount/prometheus unchanged
configmap/istio-grafana unchanged
configmap/istio-grafana-configuration-dashboards-citadel-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-galley-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-istio-mesh-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-istio-performance-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-istio-service-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-istio-workload-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-mixer-dashboard unchanged
configmap/istio-grafana-configuration-dashboards-pilot-dashboard unchanged
configmap/kiali configured
configmap/prometheus unchanged
secret/kiali unchanged
deployment.apps/grafana unchanged
deployment.apps/istio-tracing unchanged
deployment.apps/kiali unchanged
deployment.apps/prometheus unchanged
service/grafana unchanged
service/jaeger-agent unchanged
service/jaeger-collector unchanged
service/jaeger-collector-headless unchanged
service/jaeger-query unchanged
service/kiali unchanged
service/prometheus unchanged
service/tracing unchanged
service/zipkin unchanged


2020-04-06T20:00:40.421999Z info    
Component IngressGateways - manifest apply returned the following errors:
2020-04-06T20:00:40.422056Z info    Error: error running kubectl: exit status 1

2020-04-06T20:00:40.422096Z info    Error detail:

Error from server (Timeout): error when creating "STDIN": Timeout: request did not complete within requested timeout 30s (repeated 2 times)


serviceaccount/istio-ingressgateway-service-account unchanged
deployment.apps/istio-ingressgateway configured
poddisruptionbudget.policy/ingressgateway unchanged
role.rbac.authorization.k8s.io/istio-ingressgateway-sds unchanged
rolebinding.rbac.authorization.k8s.io/istio-ingressgateway-sds unchanged
service/istio-ingressgateway unchanged


2020-04-06T20:00:40.422134Z info    

✘ Errors were logged during apply operation. Please check component installation logs above.

Error: failed to apply manifests: errors were logged during apply operation

I ran the below to verify install before running the above commands.在运行上述命令之前,我运行了以下命令来验证安装。

istioctl verify-install

Checking the cluster to make sure it is ready for Istio installation...

#1. Kubernetes-api
-----------------------
Can initialize the Kubernetes client.
Can query the Kubernetes API Server.

#2. Kubernetes-version
-----------------------
Istio is compatible with Kubernetes: v1.16.7.

#3. Istio-existence
-----------------------
Istio will be installed in the istio-system namespace.

#4. Kubernetes-setup
-----------------------
Can create necessary Kubernetes configurations: Namespace,ClusterRole,ClusterRoleBinding,CustomResourceDefinition,Role,ServiceAccount,Service,Deployments,ConfigMap. 

#5. SideCar-Injector
-----------------------
This Kubernetes cluster supports automatic sidecar injection. To enable automatic sidecar injection see https://istio.io/docs/setup/kubernetes/additional-setup/sidecar-injection/#deploying-an-app

As mentioned in your logs如您的日志中所述

2020-04-06T19:59:24.951136Z info Detected that your cluster does not support third party JWT authentication. 2020-04-06T19:59:24.951136Z info 检测到您的集群不支持第三方 JWT 身份验证。 Falling back to less secure first party JWT.退回到不太安全的第一方 JWT。


As mentioned here正如这里提到的

To determine if your cluster supports third party tokens, look for the TokenRequest API:要确定您的集群是否支持第三方令牌,请查找 TokenRequest API:

$ kubectl get --raw /api/v1 | jq '.resources[] | select(.name | index("serviceaccounts/token"))'
{
    "name": "serviceaccounts/token",
    "singularName": "",
    "namespaced": true,
    "group": "authentication.k8s.io",
    "version": "v1",
    "kind": "TokenRequest",
    "verbs": [
        "create"
    ]
}

While most cloud providers support this feature now, many local development tools and custom installations may not.虽然现在大多数云提供商都支持此功能,但许多本地开发工具和自定义安装可能不支持。 To enable this feature, please refer to the Kubernetes documentation .要启用此功能,请参阅Kubernetes 文档


To authenticate with the Istio control plane, the Istio proxy will use a Service Account token.为了向 Istio 控制平面进行身份验证,Istio 代理将使用服务帐户令牌。 Kubernetes supports two forms of these tokens: Kubernetes 支持这些令牌中的两个 forms:

Third party tokens, which have a scoped audience and expiration.第三方令牌,具有范围受众和到期时间。 First party tokens, which have no expiration and are mounted into all pods.第一方令牌,没有过期并安装到所有 pod 中。 Because the properties of the first party token are less secure, Istio will default to using third party tokens.由于第一方令牌的属性不太安全,Istio 将默认使用第三方令牌。 However, this feature is not enabled on all Kubernetes platforms.但是,并非所有 Kubernetes 平台都启用此功能。

If you are using istioctl to install, support will be automatically detected.如果您使用 istioctl 安装,将自动检测支持。 This can be done manually as well, and configured by passing --set values.global.jwtPolicy=third-party-jwt or --set values.global.jwtPolicy=first-party-jwt.这也可以手动完成,并通过传递--set values.global.jwtPolicy=third-party-jwt--set values.global.jwtPolicy=first-party-jwt 进行配置。


If that won't work I would open a new github issue, or add a comment here as issue with installation is similar.如果这不起作用,我会打开一个新的 github 问题,或者在此处添加评论,因为安装问题类似。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 使用Kops的AWS上的Kubernetes群集 - NodePort服务不可用 - Kubernetes Cluster on AWS with Kops - NodePort Service Unavailable 问题:使用 Kops 在 AWS 上创建 kubernetes 集群 - Problem : creating a kubernetes cluster on AWS using Kops 无法使用kops在AWS上安装Kubernetes - Unable to install Kubernetes on AWS using kops 如何用kops更改现有的kubernetes aws集群(更改节点类型) - how to change existing kubernetes aws cluster with kops (change nodes type) 适用于kubernetes集群的更好框架/工具-Kops vs Kube-aws - Better framework/tool for kubernetes cluster - kops vs kube-aws 使用 kops 在 aws 上创建 kubernetes EC2 集群 - Create kubernetes EC2 cluster on aws using kops 在AWS托管的kubernetes集群中的KOPS部署主节点上拒绝连接 - Connection refused on KOPS deployed master node in kubernetes cluster hosted on AWS Kubernetes 集群中只有两个主节点启动,AWS 中有 kops - Only two master nodes are up in Kubernetes cluster with kops in AWS 使用kops,认证失败在AWS上的kubernetes集群中自定义SSL证书 - Custom SSL certificate in kubernetes cluster on AWS using kops, authentiction failure KOPS:在AWS VPC上具有专用网络的Kubernetes集群:错误列出节点 - KOPS: Kubernetes Cluster with private networking on AWS VPC: Error Listing Nodes
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM