Kubernetes Monitoring
Consider usage of our brand new full-stack infrastructure monitoring tool XorMon Next Generation as LPAR2RRD replacement.
It brings a new level of infrastructure monitoring by relying on a modern technology stack.
In particular, reporting, exporting, alerting and presentation capabilities are unique on the market.
kubectl get pods -n kube-system
$ kubectl create serviceaccount lpar2rrd
apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRole metadata: name: lpar2rrd rules: - apiGroups: ["","metrics.k8s.io"] resources: ["pods","nodes","services","nodes/proxy", "endpoints", "namespaces"] verbs: ["get", "watch", "list"] - nonResourceURLs: ["/metrics"] verbs: ["get"]Apply it by:
$ kubectl apply -f ClusterRole.yml
apiVersion: rbac.authorization.k8s.io/v1 kind: ClusterRoleBinding metadata: name: lpar2rrd subjects: - kind: ServiceAccount name: lpar2rrd namespace: default roleRef: apiGroup: rbac.authorization.k8s.io kind: ClusterRole name: lpar2rrdMake sure it is the same namespace as the serviceaccount like default above.
$ kubectl apply -f ClusterRoleBinding.yml
apiVersion: v1 kind: Secret metadata: name: lpar2rrd-token annotations: kubernetes.io/service-account.name: lpar2rrd type: kubernetes.io/service-account-tokenApply it by:
$ kubectl apply -f Lpar2rrdSecret.ymlGet lpar2rrd token:
$ kubectl describe secret lpar2rrd-token
$ kubectl config view
$ crontab -l | grep "load_kubernetes.sh" $
$ crontab -e # Kubernetes support 0,20,40 * * * * /home/lpar2rrd/lpar2rrd/load_kubernetes.sh > /home/lpar2rrd/lpar2rrd/load_kubernetes.out 2>&1
# su - lpar2rrd $ tar xvf lpar2rrd-7.XX.tar $ cd lpar2rrd-7.XX $ ./install.sh $ cd /home/lpar2rrd/lpar2rrd
cd /home/lpar2rrd/lpar2rrd . etc/lpar2rrd.cfg; $PERL bin/perl_modules_check.plIf there is missing "LWP::Protocol::https" then check this docu to fix it
umask 022 cd /home/lpar2rrd/lpar2rrd cp html/.htaccess www cp html/.htaccess lpar2rrd-cgi
$ crontab -l | grep load.sh $
$ crontab -e # LPAR2RRD UI 0,30 * * * * /home/lpar2rrd/lpar2rrd/load.sh > /home/lpar2rrd/lpar2rrd/load.out 2>&1Assure there is just one such entry in crontab.
# echo "lpar2rrd" >> /etc/cron.allow
$ crontab -l | grep "load_kubernetes.sh" $
$ crontab -e # Kubernetes support 0,20,40 * * * * /home/lpar2rrd/lpar2rrd/load_kubernetes.sh > /home/lpar2rrd/lpar2rrd/load_kubernetes.out 2>&1
$ cd /home/lpar2rrd/lpar2rrd $ ./load.sh
tail /var/log/httpd/error_log # Apache error log tail /var/log/httpd/access_log # Apache access log tail /var/tmp/lpar2rrd-realt-error.log # STOR2RRD CGI-BIN log tail /var/tmp/systemd-private*/tmp/lpar2rrd-realt-error.log # STOR2RRD CGI-BIN log when Linux has enabled private temp
umask 022 cd /home/lpar2rrd/lpar2rrd/ cp bin/test-healthcheck-cgi.sh lpar2rrd-cgi/go to the web browser: http://<your web server>/lpar2rrd/test.html