Install OS and Provisioner plugin for K8S
1) Download the following configuration (
wget http://archive.mapr.com/tools/KubernetesDataFabric/v<version>/*.yaml
2) Use the
1) Download the following configuration (
.yaml
) files from below location .wget http://archive.mapr.com/tools/KubernetesDataFabric/v<version>/*.yaml
2) Use the
kubectl create
command with the -f
option to create the namespace for the plug-in and provisioner
[root@tssperf09 K8S]# kubectl create -f kdf-namespace.yaml
namespace "mapr-system" created
[root@tssperf09 K8S]#
3) Now use the
kubectl create
command with -f
option to install the Role bases Access control.
[root@tssperf09 K8S]# kubectl create -f kdf-rbac.yaml
serviceaccount "maprkdf" created
clusterrole "mapr:kdf" created
clusterrolebinding "mapr:kdf" created
[root@tssperf09 K8S]#
4) Modify kdf-plugin-centos.yaml and add Host IP and port of your API server.
env:
- name : KUBERNETES_SERVICE_LOCATION
value: "10.10.72.249:6443"
- name : FLEXVOLUME_PLUGIN_PATH
value: "/usr/libexec/kubernetes/kubelet-plugins/volume/exec"
5) Now use the
kubectl create
command with -f
option to create OS plug-in depending your specific OS.
[root@tssperf09 K8S]# kubectl create -f kdf-plugin-centos.yaml
daemonset "mapr-kdfplugin" created
[root@tssperf09 K8S]#
In this step there are 2 stages
Stage 1 ) Copy files/lib from the container image to plugin dir.
Stage 2 ) Copy plugin files from plugin dir to /opt/mapr
All the logs of interest for installation of the plugin are under /opt/mapr/logs/install-k8s-plugin.log
Logs for Plugin init is under /opt/mapr/logs/plugin-k8s.log
6) Use the
kubectl create
command with the -f
option to install the provisioner on a single node of the Kubernetes cluster
[root@tssperf09 K8S]# kubectl create -f kdf-provisioner.yaml
deployment "mapr-kdfprovisioner" created
[root@tssperf09 K8S]#
If everything went well you will see a pod will be running a provisioner , in this particular case POD is running on node tssperf11 .
[root@tssperf09 logs]# kubectl get pods --all-namespaces -o wide --sort-by=.status.hostIP | grep -i provisioner
mapr-system mapr-kdfprovisioner-79b86f459d-hjkcn 1/1 Running 0 13d 192.168.217.130 tssperf11.lab
[root@tssperf09 logs]#
To list all the services running on all the pods in K8S cluster below command would be handy.
[root@tssperf09 K8S]# kubectl get pods --all-namespaces -o wide --sort-by=.status.hostIP
NAMESPACE NAME READY STATUS RESTARTS AGE IP NODE
kube-system kube-proxy-kln5q 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system calico-kube-controllers-d554689d5-mv6lz 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
mapr-system mapr-kdfplugin-srcln 1/1 Running 0 1h 192.168.196.223 tssperf09.lab
kube-system kube-scheduler-tssperf09.lab 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system calico-node-z6tqw 2/2 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system etcd-tssperf09.lab 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system kube-apiserver-tssperf09.lab 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system kube-controller-manager-tssperf09.lab 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system kube-dns-6f4fd4bdf-x2g82 3/3 Running 0 4d 192.168.196.222 tssperf09.lab
kube-system calico-etcd-8s8mf 1/1 Running 0 4d 10.10.72.249 tssperf09.lab
kube-system kube-proxy-68tv4 1/1 Running 0 4d 10.10.72.250 tssperf10.lab
mapr-system mapr-kdfplugin-6l5n7 1/1 Running 0 1h 192.168.61.65 tssperf10.lab
kube-system calico-node-rcxzm 2/2 Running 0 4d 10.10.72.250 tssperf10.lab
kube-system kube-proxy-cknz7 1/1 Running 0 4d 10.10.72.251 tssperf11.lab
kube-system calico-node-x5qds 2/2 Running 0 4d 10.10.72.251 tssperf11.lab
mapr-system mapr-kdfplugin-crzhk 1/1 Running 0 1h 192.168.217.129 tssperf11.lab
mapr-system mapr-kdfprovisioner-79b86f459d-hjkcn 1/1 Running 0 1h 192.168.217.130 tssperf11.lab
[root@tssperf09 K8S]#
No comments:
Post a Comment