四,kubeconfig文件的使用:
定义环境变量,这个环境变量非常非常重要 KUBECONFIG 它的值是这个kubeconfig文件的绝对路径就可以了,我把这个文件存放到了23服务器的/media 文件夹下了:
export KUBECONFIG=/media/bootstrap.kubeconfig
OK,现在就可以使用kubectl试试使用此kubeconfig文件连接192.168.217.23:8443 这个apiserver了(还是在23服务器上):
[root@node3 media]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE default static-web-node3 1/1 Running 0 4h42m kube-system coredns-7ff77c879f-nsj95 1/1 Running 0 5h25m kube-system etcd-node3 1/1 Running 0 5h25m kube-system kube-apiserver-node3 1/1 Running 0 5h25m kube-system kube-controller-manager-node3 1/1 Running 0 5h25m kube-system kube-flannel-ds-amd64-6cdl5 1/1 Running 0 5h25m kube-system kube-proxy-vdhzr 1/1 Running 0 5h25m kube-system kube-scheduler-node3 1/1 Running 0 5h25m kube-system storage-provisioner 1/1 Running 0 5h25m
证明连接没有问题,kubectl config view 可以查看当前使用的kubeconfig文件的大概信息,可以看到证书的详细信息是隐藏了,集群名称也是前面设置的my:
[root@node3 media]# kubectl config view apiVersion: v1 clusters: - cluster: certificate-authority-data: DATA+OMITTED server: https://192.168.217.23:8443 name: myminikube contexts: - context: cluster: myminikube user: minikube name: default current-context: default kind: Config preferences: {} users: - name: minikube user: client-certificate-data: REDACTED client-key-data: REDACTED
那么,把这个文件传到另一台服务器,例如192.168.217.24服务器上,此服务器上只安装了一个kubectl:
版本说明:
注意,kubectl我安装的版本是1.22.2,管理的集群minikube的版本是1.18.8,因此,最后有一个报警,说客户端和服务端版本最好相差1,否则会出问题。
[root@node4 ~]# ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 1000 link/ether 00:0c:29:5b:a4:eb brd ff:ff:ff:ff:ff:ff inet 192.168.217.24/24 brd 192.168.217.255 scope global ens33 [root@node4 ~]# kubectl version Client Version: version.Info{Major:"1", Minor:"22", GitVersion:"v1.22.2", GitCommit:"8b5a19147530eaac9476b0ab82980b4088bbc1b2", GitTreeState:"clean", BuildDate:"2021-09-15T21:38:50Z", GoVersion:"go1.16.8", Compiler:"gc", Platform:"linux/amd64"} Server Version: version.Info{Major:"1", Minor:"18", GitVersion:"v1.18.8", GitCommit:"9f2892aab98fe339f3bd70e3c470144299398ace", GitTreeState:"clean", BuildDate:"2020-08-13T16:04:18Z", GoVersion:"go1.13.15", Compiler:"gc", Platform:"linux/amd64"} WARNING: version difference between client (1.22) and server (1.18) exceeds the supported minor version skew of +/-1
192.168.217.23上面安装的minkube版本是1.18.8:
[root@node3 media]# ip a 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN qlen 1000 link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo valid_lft forever preferred_lft forever inet6 ::1/128 scope host valid_lft forever preferred_lft forever 2: ens33: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UNKNOWN qlen 1000 link/ether 00:0c:29:70:12:12 brd ff:ff:ff:ff:ff:ff inet 192.168.217.23/24 brd 192.168.217.255 scope global ens33 [root@node3 media]# kubectl get no NAME STATUS ROLES AGE VERSION node3 Ready master 5h34m v1.18.8
说明kubectl确实是客户端,192.168.217.24服务器上只需要安装一个kubectl就可以了。
23上,上传前面命令制作的kubeconfig文件到24根目录:
[root@node3 media]# scp bootstrap.kubeconfig 192.168.217.24:~/ root@192.168.217.24's password: bootstrap.kubeconfig 100% 5482 1.5MB/s 00:00
在24服务器上使用传来的文件(定义环境变量):
[root@node4 ~]# export KUBECONFIG=/root/bootstrap.kubeconfig [root@node4 ~]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE default static-web-node3 1/1 Running 0 4h55m kube-system coredns-7ff77c879f-nsj95 1/1 Running 0 5h38m kube-system etcd-node3 1/1 Running 0 5h38m kube-system kube-apiserver-node3 1/1 Running 0 5h38m kube-system kube-controller-manager-node3 1/1 Running 0 5h38m kube-system kube-flannel-ds-amd64-6cdl5 1/1 Running 0 5h38m kube-system kube-proxy-vdhzr 1/1 Running 0 5h38m kube-system kube-scheduler-node3 1/1 Running 0 5h38m kube-system storage-provisioner 1/1 Running 0 5h39m
OK了,现在只需要把上面这个环境变量写入/etc/profile文件内,以后集群开机后就只需要登录24服务器就可以进行集群管理工作了。那么,假如有多个集群呢?
这个就简单了,把每个集群的kubeconfig文件都统一放置到一个服务器内,比如我这个192.168.217.24服务器内,然后进行kubeconfig文件的合并。
五,kubeconfig文件的合并
现在有两个集群,一个是kubeadm安装的高可用四节点集群,vip为192.168.217.100,一个是minkube,IP地址为192.168.217.23
将kubeadm部署的集群的kubeconfig文件kubeadm-config放置到192.168.217.24服务器上,文件内容如下:
[root@node4 ~]# cat kubeadm-config apiVersion: v1 clusters: - cluster: certificate-authority-data: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUMvakNDQWVhZ0F3SUJBZ0lCQURBTkJna3Foa2lHOXcwQkFRc0ZBREFWTVJNd0VRWURWUVFERXdwcmRXSmwKY201bGRHVnpNQjRYRFRJeU1URXdNVEV5TXpReE1sb1hEVE15TVRBeU9URXlNelF4TWxvd0ZURVRNQkVHQTFVRQpBeE1LYTNWaVpYSnVaWFJsY3pDQ0FTSXdEUVlKS29aSWh2Y05BUUVCQlFBRGdnRVBBRENDQVFvQ2dnRUJBTk50CjBPUC94dmlnSlZSb0lteGpWd1JXREZUWWxFWVV5eW5NL0xOL09GRnJxdk1mV0FTa280UlpPazNMa05kSW9XWXQKdmErUXc4eEFKb2NjVkgzQkF6N1VDRG1aWkNJbVN2M2JSVitBL2VxLzlqbERINjE4L2JSQ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: kubernetes user: kubernetes-admin name: kubernetes-admin@kubernetes current-context: kubernetes-admin@kubernetes kind: Config preferences: {} users: - name: kubernetes-admin user: client-certificate-data: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSURJVENDQWdtZ0F3SUJBZ0lJWTFlRWwvV21KTjR3RFFZSktvWklodmNOQVFFTEJRQXdGVEVUTUJFR0ExVUUKQXhNS2EzVmlaWEp1WlhSbGN6QWVGdzB5TWpFeE1ERXhNak0wTVRKYUZ3MHlNekV4TURFeE1qTTBNVFJhTURReApGekFWQmdOVkJBb1REbk41YzNSbGJUcHRZWE4wWlhKek1Sa3dGd1lEVlFRREV4QnJkV0psY201bGRHVnpMV0ZrCmJXbHVNSUlCSWpBTkJna3Foa2lHOXcwQkFRRUZBQU9DQVE4QU1JSUJDZ0tDQVFFQXI4STl1dnh6ZlJqU1lzVzAKaGxRWTB6NXdpcEVaVWJJS0N2NVppcjdtU2lzVXN4V21lc2xEOW1TMHNJOEIwRXBxbjVnMjVnRTg5c1lDa0R3SQpVWVpqZHVDd1paeDNlTmZsSmdES04xTmxXU3ljRzZhSGI2NzdncWVPWStlNHBxRTV1YzNPRWVyRTR6ajJPTHZBCjdjYjVYT0lqWXNKRkxINlMyODVoN2NyU3JMdVJudklwYXdVQ3V0MmdXZGFPYUJ2RDRqUzBiMUQ5RkFjYktZVXAKT2FuZTdmRTAyNHdBZlNjd3FUdmlRVEhTbFZLdFByeUh4TUluMnlmc3ZNT0NseWRCdCtDemdDM0lnb1QzWXpPUgp3WDloTVF6bEx2cU1Ga2Rub1ZHelo4Q2tGNVRmM01QckxKZzc0QlFjVGtlWU1HQkJSVHZBYU9uUlpJMFI5NDYzCkduQTgzUUlEQVFBQm8xWXdWREFPQmdOVkhROEJBZjhFQkFNQ0JhQXdFd1lEVlIwbEJBd3dDZ1lJS3dZQkJRVUgKQXdJd0RBWURWUjBUQVFIL0JBSXdBREFmQmdOVkhTTUVHREFXZ0JSS2l3VG9xL2grNS9F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dQMG5zVzB2a1pieVhWTmRlUENlb3U1RTdtM20xc0s1b1hCNkFBYQpWVTFaaUVlbUtvMWJsdGZZdm5mRWF1MnlMZ09qYm1icndSK0NXSzh4WFIxRERYZkdGN0lvcXpoN3BLYkZyZDdDCmpJT2dmb3ZQWVEvVWozeGprUE9aMERNQ2dZQlVOczJSd0xnNndvLytGRHBJV2xwUWh2Q1RrYVNLWjVocWNib0wKbCtVOUJXSzFoaElycE83MXN0REh4cmllYVZ3a0hYUXNnODFQRFB1YXB1YUh3UVVWS0FsL2VVNW14bmxPZXpXQgpSM09DL0tGUE83b3QzbEZ2bzlSbHlOUkpuT2FkVkFycG9aNmVzY3VUempXN1hCYzBxK0FqbC9CclloNGMxSG9pCnJCK0VQd0tCZ1FDd042NDFkZi85Z2NhaTdYRXkvanNkbm1lVnBxTG9TSzBuV09HdXhIMFR2dkxmVGtuMHQ4TE4KMFRXelVOaExKT1ZTcWgyUCtPQWs2dzd2UlFMeEU2L2pVMmNuRzBpZURkMU96cmlFM1JjMEtzZUVBUjNyU1JoWQp5YnRITnlDOWtsdlZmSTk3Tnk3bVZxMENKaTBQUVplTFZ3UUdya3EwNGZ6SVBRTTl0Yi9yYUE9PQotLS0tLUVORCBSU0EgUFJJVkFURSBLRVktLS0tLQo=
激活环境变量后,可以正常管理此高可用集群:
[root@node4 ~]# export KUBECONFIG=/root/kubeadm-config [root@node4 ~]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE kube-system calico-kube-controllers-796cc7f49d-k586w 1/1 Running 2 (3m48s ago) 2d2h kube-system calico-node-7x86d 1/1 Running 2 (3m50s ago) 2d2h kube-system calico-node-dhxcq 1/1 Running 2 (4m ago) 2d2h kube-system calico-node-jcq6p 1/1 Running 4 (110s ago) 2d2h kube-system calico-node-vjtv6 1/1 Running 2 (3m48s ago) 2d2h kube-system coredns-7f6cbbb7b8-7c85v 1/1 Running 18 (3m48s ago) 7d23h kube-system coredns-7f6cbbb7b8-7xm62 1/1 Running 2 (3m48s ago) 2d2h
OK,开始kubeconfig文件的合并,两个文件同时写入环境变量,文件之间用 :隔离开就是合并啦:
export KUBECONFIG=/root/kubeadm-config:/root/bootstrap.kubeconfig
config view 可以读取环境变量后,将相关内容显示出来:
[root@node4 ~]# kubectl config view apiVersion: v1 clusters: - cluster: certificate-authority-data: DATA+OMITTED server: https://192.168.217.100:6443 name: kubernetes - cluster: certificate-authority-data: DATA+OMITTED server: https://192.168.217.23:8443 name: myminikube contexts: - context: cluster: myminikube user: minikube name: default - context: cluster: kubernetes user: kubernetes-admin name: kubernetes-admin@kubernetes current-context: kubernetes-admin@kubernetes kind: Config preferences: {} users: - name: kubernetes-admin user: client-certificate-data: REDACTED client-key-data: REDACTED - name: minikube user: client-certificate-data: REDACTED client-key-data: REDACTED
OK,先看看在使用哪个集群:
1. [root@node4 ~]# kubectl config current-context 2. kubernetes-admin@kubernetes
对比这个输出,我们可以看到context的名字是kubernetes这个集群,也就是kubeadm部署的HA集群 ,下面的命令也验证了这一点。
[root@node4 ~]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE kube-system calico-kube-controllers-796cc7f49d-k586w 1/1 Running 2 (13m ago) 2d3h kube-system calico-node-7x86d 1/1 Running 2 (13m ago) 2d3h 略略略
OK,通过 config use-context 也就是切换上下文的方式,切换kubectl管理集群:
1. [root@node4 ~]# kubectl config use-context default 2. Switched to context "default".
验证一哈,确实切换到minikube了:
[root@node4 ~]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE default static-web-node3 1/1 Running 0 5h35m kube-system coredns-7ff77c879f-nsj95 1/1 Running 0 6h18m kube-system etcd-node3 1/1 Running 0 6h18m 略略略
在切换到kubeadm部署的HA集群:
[root@node4 ~]# kubectl config use-context kubernetes-admin@kubernetes Switched to context "kubernetes-admin@kubernetes".
验证,可以看到完美切换:
[root@node4 ~]# kubectl get po -A NAMESPACE NAME READY STATUS RESTARTS AGE kube-system calico-kube-controllers-796cc7f49d-k586w 1/1 Running 2 (20m ago) 2d3h kube-system calico-node-7x86d 1/1 Running 2 (20m ago) 2d3h 略略略
那么环境变量合并的方式对于目前来说是足够了,仅仅几个集群嘛,无所谓,爱谁谁了。如果达到几十个上百个集群,那么,还是需要通过命令来合并集群的kubeconfig文件了。
六,命令方式合并kubeconfig文件
这个方法比较简单,主要是确定合并方向,是把minikube的kubeconfig文件合并到HA的kubeconfig文件内,因此,将24服务器上的HAkubeconfig文件改名为two-cs-config, 然后将此文件传到minkube的服务器也就是192.168.217.23服务器上,在执行以下的三个命令将它的本地证书内嵌到kubeconfig文件内,在将此文件传到24服务器就,就可以正常使用了(命令会追加写入指定内容到kubeconfig文件内,不会覆盖)
mv kubeadm-config two-cs-config
[root@node3 mnt]# kubectl config set-cluster myminikube \ > --certificate-authority=/root/.minikube/ca.crt \ > --embed-certs=true \ > --server=${KUBE_APISERVER} \ > --kubeconfig=two-cs-config Cluster "myminikube" set. [root@node3 mnt]# kubectl config set-credentials minikube \ > --client-certificate=/root/.minikube/profiles/minikube/client.crt \ > --client-key=/root/.minikube/profiles/minikube/client.key \ > --embed-certs=true \ > --kubeconfig=two-cs-config User "minikube" set. [root@node3 mnt]# kubectl config set-context default \ > --cluster=myminikube \ > --user="minikube" \ > --kubeconfig=two-cs-config Context "default" created. [root@node3 mnt]# cat two-cs-config apiVersion: v1 clusters: - cluster: certificate-authority-data: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSUMvakNDQWVhZ0F3SUJBZ0lCQURBTkJna3Foa2lHOXcwQkFRc0ZBREFWTVJNd0VRWURWUVFERXdwcmRXSmwKY201bGRHVnpNQjRYRFRJeU1URXdNVEV5TXpReE1sb1hEVE15TVRBeU9URXlNelF4TWxvd0ZURVRNQkVHQTFVRQpBeE1LYTNWaVpYSnVaWFJsY3pDQ0FTSXdEUVlKS29aSWh2Y05BUUVCQlFBRGdnRVBBRENDQVFvQ2dnRUJBTk50CjBPUC94dmlnSlZSb0lteGpWd1JXREZUWWxFWVV5eW5N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pTckJ2RlpNSWJJSEpzRE83cG5WVGkvWW95VWg5TFdndnB1TQpvMDdjOWJKM21YN25OVGFyOU1la1JnZ2hTTHBkTHBjaFlOSEY5bkFzQ3liblI3L05ZZVZlYUFSM2xRaWNETTJBCnAxV2YwYzhJZ0tJUHk0Z0k2MThOQkhtSUlnTEU1Yk1BSkczalFDNXBzcnM1ZXlsUnVrNkdCbEpia280YThJS1cKQm9QWHFtM2M1WGd3c0MvckhxU1lyL2RaYXlOL3dGQmIyRWJIS1gyMXRpZEZKYXhITGZKaUhRM1pjRGl5eHdqTwpSNTA3SzgvbTQrVEJrM012RzlFNUp4S2xiNk43M0NSbGo4ZUtJRm1vanBDRk5EWk5udkNPc3FnZ1YybXhHaEtDCkRLRXZ6SFI0VkhnRnliUHNEb0tOY2NjbERxeTRMelFkK3c4agotLS0tLUVORCBDRVJUSUZJQ0FURS0tLS0tCg== server: https://192.168.217.23:8443 name: myminikube contexts: - context: cluster: myminikube user: minikube name: default - context: cluster: kubernetes user: kubernetes-admin name: kubernetes-admin@kubernetes current-context: kubernetes-admin@kubernetes kind: Config preferences: {} users: - name: kubernetes-admin user: client-certificate-data: LS0tLS1CRUdJTiBDRVJUSUZJQ0FURS0tLS0tCk1JSURJVENDQWdtZ0F3SUJBZ0lJWTFlRWwvV21KTjR3RFFZSktvWklodmNOQVFFTEJRQXdGVEVUTUJFR0ExVUUKQXhNS2EzVmlaWEp1WlhSbGN6QWVGdzB5TWpFeE1ERXhNak0wTVRKYUZ3MHlNekV4TURFeE1qTTBNVFJhTURReApGekFWQmdOVkJBb1REbk41YzNSbGJUcHRZWE4wWlhKek1Sa3dGd1lEVlFRREV4QnJkV0psY201bGRHVnpMV0ZrCmJXbHVNSUlCSWpBTkJna3Foa2lHOXcwQkFRRUZBQU9DQVE4QU1JSUJDZ0tDQVFFQXI4STl1dnh6ZlJqU1lzVzAKaGxRWTB6NXdpcEVaVWJJS0N2NVppcjdtU2lzVXN4V21lc2xEOW1TMHNJOEIwRXB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