Istio部署未发生

时间:2018-11-26 16:56:42

标签: kubernetes minikube istio

我正在尝试在minikube集群中安装istio

我按照本页https://istio.io/docs/setup/kubernetes/quick-start/

上的教程进行操作

我正在尝试使用选项1:https://istio.io/docs/setup/kubernetes/quick-start/#option-1-install-istio-without-mutual-tls-authentication-between-sidecars

我可以看到已经创建了服务,但是部署似乎失败了。

kubectl get pods -n istio-system 
No resources found

我该如何解决?

这是获得部署的结果

kubectl get deployment -n istio-system
NAME                     DESIRED   CURRENT   UP-TO-DATE   AVAILABLE   AGE
grafana                  1         0         0            0           4m
istio-citadel            1         0         0            0           4m
istio-egressgateway      1         0         0            0           4m
istio-galley             1         0         0            0           4m
istio-ingressgateway     1         0         0            0           4m
istio-pilot              1         0         0            0           4m
istio-policy             1         0         0            0           4m
istio-sidecar-injector   1         0         0            0           4m
istio-telemetry          1         0         0            0           4m
istio-tracing            1         0         0            0           4m
prometheus               1         0         0            0           4m
servicegraph             1         0         0            0           4m

2 个答案:

答案 0 :(得分:2)

这对我有用。启动minikube时请勿使用--extra-config。这导致kube-controller-manager-minikube崩溃,因为它找不到文件

  

错误启动控制器:无法启动证书控制器:   读取CA证书文件“ /var/lib/localkube/certs/ca.crt”时出错:打开   /var/lib/localkube/certs/ca.crt:没有这样的文件或目录

只需使用此命令启动minikube。我有minikube V0.30.0。

minikube start

输出:

Starting local Kubernetes v1.10.0 cluster...
Starting VM...
Downloading Minikube ISO
 170.78 MB / 170.78 MB [============================================] 100.00% 0s
Getting VM IP address...
Moving files into cluster...
Downloading kubelet v1.10.0
Downloading kubeadm v1.10.0
Finished Downloading kubeadm v1.10.0
Finished Downloading kubelet v1.10.0
Setting up certs...
Connecting to cluster...
Setting up kubeconfig...
Starting cluster components...
Kubectl is now configured to use the cluster.
Loading cached images from config file.

指向istio-1.0.4 folder,运行此命令

kubectl apply -f install/kubernetes/helm/istio/templates/crds.yaml

这应该安装所有必需的crds

运行此命令

kubectl apply -f install/kubernetes/istio-demo.yaml

成功创建规则,服务,部署等后,运行此命令

 kubectl get pods -n istio-system                                                                                                          

NAME                                      READY   STATUS      RESTARTS   AGE
grafana-9cfc9d4c9-h2zn8                   1/1     Running     0          5m
istio-citadel-74df865579-d2pbq            1/1     Running     0          5m
istio-cleanup-secrets-ghlbf               0/1     Completed   0          5m
istio-egressgateway-58df7c4d8-4tg4p       1/1     Running     0          5m
istio-galley-8487989b9b-jbp2d             1/1     Running     0          5m
istio-grafana-post-install-dn6bw          0/1     Completed   0          5m
istio-ingressgateway-6fc88db97f-49z88     1/1     Running     0          5m
istio-pilot-74bb7dcdd-xjgvz               0/2     Pending     0          5m
istio-policy-58878f57fb-t6fqt             2/2     Running     0          5m
istio-security-post-install-vqbzw         0/1     Completed   0          5m
istio-sidecar-injector-5cfcf6dd86-lr8ll   1/1     Running     0          5m
istio-telemetry-bf5558589-8hzcc           2/2     Running     0          5m
istio-tracing-ff94688bb-bwzfs             1/1     Running     0          5m
prometheus-f556886b8-9z6vp                1/1     Running     0          5m
servicegraph-55d57f69f5-fvqbg             1/1     Running     0          5m

答案 1 :(得分:0)

也请尝试自定义安装via Helm template。您不需要为此部署Tiller。

1)kubectl apply -f install / kubernetes / helm / istio / templates / crds.yaml

2)掌舵模板install / kubernetes / helm / istio --name istio --namespace istio-system --set grafana.enabled = true --set servicegraph.enabled = true --set tracing.enabled = true- set kiali.enabled = true --set sidecarInjectorWebhook.enabled = true --set global.tag = 1.0.5> $ HOME / istio.yaml

3)kubectl创建名称空间istio-system

4)kubectl apply -f $ HOME / istio.yaml