istio部署bookinfo二

[root@slave istio-1.14.1]# kubectl apply -f samples/bookinfo/platform/kube/bookinfo.yaml 
service/details created
serviceaccount/bookinfo-details created
deployment.apps/details-v1 created
service/ratings created
serviceaccount/bookinfo-ratings created
deployment.apps/ratings-v1 created
service/reviews created
serviceaccount/bookinfo-reviews created
deployment.apps/reviews-v1 created
deployment.apps/reviews-v2 created
deployment.apps/reviews-v3 created
service/productpage created
serviceaccount/bookinfo-productpage created
deployment.apps/productpage-v1 created

[root@slave istio-1.14.1]# kubectl get services
NAME                       TYPE        CLUSTER-IP       EXTERNAL-IP   PORT(S)    AGE
details                    ClusterIP   10.106.6.152     <none>        9080/TCP   4m31s
helm-mysql                 ClusterIP   10.108.151.91    <none>        3306/TCP   194d
helm-postgresql            ClusterIP   10.103.113.146   <none>        5432/TCP   194d
helm-postgresql-headless   ClusterIP   None             <none>        5432/TCP   194d
kubernetes                 ClusterIP   10.96.0.1        <none>        443/TCP    197d
nginx-headless             ClusterIP   None             <none>        80/TCP     184d
productpage                ClusterIP   10.98.49.140     <none>        9080/TCP   4m26s
ratings                    ClusterIP   10.100.18.25     <none>        9080/TCP   4m28s
reviews                    ClusterIP   10.106.50.207    <none>        9080/TCP   4m27s

 [root@slave istio-1.14.1]# kubectl get deployment
NAME                     READY   UP-TO-DATE   AVAILABLE   AGE
details-v1               0/1     0            0           20m
helm-mysql               1/1     1            1           194d
nfs-client-provisioner   1/1     1            1           184d
productpage-v1           0/1     0            0           20m
ratings-v1               0/1     0            0           20m
reviews-v1               0/1     0            0           20m
reviews-v2               0/1     0            0           20m
reviews-v3               0/1     0            0           20m
 

 [root@slave istio-1.14.1]# kubectl get deployment -o wide
NAME                     READY   UP-TO-DATE   AVAILABLE   AGE    CONTAINERS               IMAGES                                                    SELECTOR
details-v1               0/1     0            0           22m    details                  docker.io/istio/examples-bookinfo-details-v1:1.16.4       app=details,version=v1
helm-mysql               1/1     1            1           194d   helm-mysql               mysql:5.7.30                                              app=helm-mysql,release=helm-mysql
nfs-client-provisioner   1/1     1            1           184d   nfs-client-provisioner   jmgao1983/nfs-client-provisioner:latest                   app=nfs-client-provisioner
productpage-v1           0/1     0            0           22m    productpage              docker.io/istio/examples-bookinfo-productpage-v1:1.16.4   app=productpage,version=v1
ratings-v1               0/1     0            0           22m    ratings                  docker.io/istio/examples-bookinfo-ratings-v1:1.16.4       app=ratings,version=v1
reviews-v1               0/1     0            0           22m    reviews                  docker.io/istio/examples-bookinfo-reviews-v1:1.16.4       app=reviews,version=v1
reviews-v2               0/1     0            0           22m    reviews                  docker.io/istio/examples-bookinfo-reviews-v2:1.16.4       app=reviews,version=v2
reviews-v3               0/1     0            0           22m    reviews                  docker.io/istio/examples-bookinfo-reviews-v3:1.16.4       app=reviews,version=v3

 # kubectl  describe deployment details-v1
Name:                   details-v1
Namespace:              default
CreationTimestamp:      Sat, 11 Jun 2022 22:57:58 +0800
Labels:                 app=details
                        version=v1
Annotations:            deployment.kubernetes.io/revision: 1
Selector:               app=details,version=v1
Replicas:               1 desired | 0 updated | 0 total | 0 available | 1 unavailable
StrategyType:           RollingUpdate
MinReadySeconds:        0
RollingUpdateStrategy:  25% max unavailable, 25% max surge
Pod Template:
  Labels:           app=details
                    version=v1
  Service Account:  bookinfo-details
  Containers:
   details:
    Image:        docker.io/istio/examples-bookinfo-details-v1:1.16.4
    Port:         9080/TCP
    Host Port:    0/TCP
    Environment:  <none>
    Mounts:       <none>
  Volumes:        <none>
Conditions:
  Type             Status  Reason
  ----             ------  ------
  Available        False   MinimumReplicasUnavailable
  ReplicaFailure   True    FailedCreate
  Progressing      False   ProgressDeadlineExceeded
OldReplicaSets:    <none>
NewReplicaSet:     details-v1-7d88846999 (0/1 replicas created)
Events:            <none>

# kubectl get replicasets
NAME                                DESIRED   CURRENT   READY   AGE
details-v1-7d88846999               1         0         0       141m
helm-mysql-7f96dd4fcb               1         1         1       195d
nfs-client-provisioner-5b6d7dd69b   1         1         1       184d
productpage-v1-7795568889           1         0         0       141m
ratings-v1-754f9c4975               1         0         0       141m
reviews-v1-55b668fc65               1         0         0       141m
reviews-v2-858f99c99                1         0         0       141m
reviews-v3-7886dd86b9               1         0         0       141m
 

# kubectl describe replicaset details-v1-7d88846999
Name:           details-v1-7d88846999
Namespace:      default
Selector:       app=details,pod-template-hash=7d88846999,version=v1
Labels:         app=details
                pod-template-hash=7d88846999
                version=v1
Annotations:    deployment.kubernetes.io/desired-replicas: 1
                deployment.kubernetes.io/max-replicas: 2
                deployment.kubernetes.io/revision: 1
Controlled By:  Deployment/details-v1
Replicas:       0 current / 1 desired
Pods Status:    0 Running / 0 Waiting / 0 Succeeded / 0 Failed
Pod Template:
  Labels:           app=details
                    pod-template-hash=7d88846999
                    version=v1
  Service Account:  bookinfo-details
  Containers:
   details:
    Image:        docker.io/istio/examples-bookinfo-details-v1:1.16.4
    Port:         9080/TCP
    Host Port:    0/TCP
    Environment:  <none>
    Mounts:       <none>
  Volumes:        <none>
Conditions:
  Type             Status  Reason
  ----             ------  ------
  ReplicaFailure   True    FailedCreate
Events:
  Type     Reason        Age                  From                   Message
  ----     ------        ----                 ----                   -------
  Warning  FailedCreate  50m                  replicaset-controller  Error creating: Internal error occurred: failed calling webhook "namespace.sidecar-injector.istio.io": failed to call webhook: Post "https://istiod.istio-system.svc:443/inject?timeout=10s": net/http: TLS handshake timeout
  Warning  FailedCreate  16m (x24 over 142m)  replicaset-controller  Error creating: Internal error occurred: failed calling webhook "namespace.sidecar-injector.istio.io": failed to call webhook: Post "https://istiod.istio-system.svc:443/inject?timeout=10s": context deadline exceeded
[root@slave istio-1.14.1]# 
 

[root@slave istio-1.14.1]# kubectl api-versions | grep admissionregistration
admissionregistration.k8s.io/v1
 

[root@slave istio-1.14.1]# kubectl describe cm istio-sidecar-injector -n istio-system|grep policy
policy: enabled
 

# kubectl get ValidatingWebhookConfiguration
NAME                                      WEBHOOKS   AGE
ingress-nginx-admission                   1          194d
istio-validator-istio-system              1          34h
istiod-default-validator                  1          34h
network.kubesphere.io                     1          185d
notification-manager-validating-webhook   2          184d
resourcesquotas.quota.kubesphere.io       1          185d
users.iam.kubesphere.io                   1          184d
 

# kubectl api-versions | grep admissionregistration.k8s.io
admissionregistration.k8s.io/v1
 

可能是内存和磁盘空间不够导致一些pod启动失败,虚拟机硬盘和内存扩容后,再查看bookinfo的pod已经运行了

[root@hxhzzy ~]# kubectl get pods -n bookinfo
NAME                              READY   STATUS    RESTARTS            AGE
details-v1-7d88846999-5gdgh       1/1     Running   1 (<invalid> ago)   13h
productpage-v1-7795568889-xx8fj   1/1     Running   1 (<invalid> ago)   13h
ratings-v1-754f9c4975-5fszw       1/1     Running   1 (<invalid> ago)   13h
reviews-v1-55b668fc65-q5pm5       1/1     Running   1 (<invalid> ago)   13h
reviews-v2-858f99c99-xz5g9        1/1     Running   1 (<invalid> ago)   13h
reviews-v3-7886dd86b9-dtfxm       1/1     Running   1 (<invalid> ago)   13h
[root@hxhzzy ~]# kubectl get pods --all-namespaces
NAMESPACE       NAME                                        READY   STATUS    RESTARTS             AGE
bookinfo        details-v1-7d88846999-5gdgh                 1/1     Running   1 (<invalid> ago)    13h
bookinfo        productpage-v1-7795568889-xx8fj             1/1     Running   1 (<invalid> ago)    13h
bookinfo        ratings-v1-754f9c4975-5fszw                 1/1     Running   1 (<invalid> ago)    13h
bookinfo        reviews-v1-55b668fc65-q5pm5                 1/1     Running   1 (<invalid> ago)    13h
bookinfo        reviews-v2-858f99c99-xz5g9                  1/1     Running   1 (<invalid> ago)    13h
bookinfo        reviews-v3-7886dd86b9-dtfxm                 1/1     Running   1 (<invalid> ago)    13h
default         helm-mysql-7f96dd4fcb-dt6jh                 1/1     Running   2 (<invalid> ago)    13h
default         nfs-client-provisioner-5b6d7dd69b-c9m7s     1/1     Running   1 (<invalid> ago)    13h
ingress-nginx   ingress-nginx-controller-86468dc757-gzxpl   1/1     Running   1 (<invalid> ago)    15h
istio-system    istio-egressgateway-575d8bd99b-xvrjq        1/1     Running   1 (<invalid> ago)    13h
istio-system    istio-ingressgateway-865c667b48-4ktfr       1/1     Running   1 (<invalid> ago)    13h
istio-system    istiod-8495d444bb-bp7w2                     1/1     Running   1 (<invalid> ago)    13h
istio-system    istiod-8495d444bb-sz2bg                     1/1     Running   1 (<invalid> ago)    13h
kube-system     calico-kube-controllers-56b8f699d9-bkls7    1/1     Running   169 (4h4m ago)       195d
kube-system     calico-node-f82br                           1/1     Running   19 (<invalid> ago)   212d
kube-system     calico-node-t452w                           1/1     Running   45 (4h4m ago)        212d
kube-system     coredns-7f6cbbb7b8-wkqdr                    1/1     Running   122                  195d
kube-system     etcd-node                                   1/1     Running   68                   212d
kube-system     kube-apiserver-node                         1/1     Running   138                  200d
kube-system     kube-controller-manager-node                1/1     Running   219 (3h58m ago)      195d
kube-system     kube-proxy-9l8bv                            1/1     Running   15 (<invalid> ago)   212d
kube-system     kube-proxy-t5t6q                            1/1     Running   27 (4h4m ago)        212d
kube-system     kube-scheduler-node                         1/1     Running   205 (3h58m ago)      195d
kube-system     metrics-server-687cb5444-64rc8              1/1     Running   4 (<invalid> ago)    15h
kube-system     snapshot-controller-0                       1/1     Running   1 (<invalid> ago)    14h
kube-system     tiller-deploy-6fddb8878-dk74n               1/1     Running   2 (<invalid> ago)    15h
kube-system     weave-net-54lvw                             2/2     Running   63 (4h4m ago)        212d
kube-system     weave-net-jpvlw                             2/2     Running   31 (<invalid> ago)   212d
mysql-sts       mysql-0                                     1/1     Running   1 (<invalid> ago)    14h
mysql-sts       mysql-1                                     1/1     Running   1 (<invalid> ago)    14h
mysql-sts       mysql-2                                     1/1     Running   2 (<invalid> ago)    14h
 

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值