Question: How can I schedule master node running pod/service as worker node? By deafult, only worker node could run the pod, master only response for the scheduler/configuration. $ kubectl get nodes -o json | jq .items[].spec.taints [ { “effect”: “NoSchedule”, “key”: “node-role.kubernetes.io/master” } ] $ kubectl get nodes -o json | grep master “node-role.kubernetes.io/master”: “” […]
DevOps
Endpoint is not Created for Service in Kubernetes
The Problem Endpoints shows ‘none’: $ kubectl get svc NAME TYPE CLUSTER-IP EXTERNAL-IP PORT(S) AGE kubernetes ClusterIP 10.yy.0.1 <none> 443/TCP 9d test ClusterIP 10.xx.97.97 <none> 6379/TCP 21s $ kubectl describe svc test Name: test Namespace: default Labels: <none> Annotations: kubectl.kubernetes.io/last-applied-configuration: {“apiVersion”:”v1″,”kind”:”Service”,”metadata”:{“annotations”:{},”name”:”test”,”namespace”:”default”},”spec”:{“clusterIP”:”10.xx.97.97″,”… Selector: app=test Type: ClusterIP IP: 10.xx.97.97 Port: <unset> 6379/TCP TargetPort: 6379/TCP Endpoints: <none> Session […]
Troubleshooting kubectl Error: The connection to the server x.x.x.x:6443 was refused – did you specify the right host or port?
This document describes steps to troubleshoot kubectl error: The connection to the server x.x.x.x:6443 was refused – did you specify the right host or port? 1. The kubectl should be executed on the Master Node. 2. Current user must have Kubernetes cluster configuration environment variable (Details of how to are listed under section Preparing to […]
“docker dead but subsys locked” – error while starting docker
The Problem The docker engine package was upgraded. After that the user is not able to start the docker service, and revert back with error “docker dead but subsys locked” on verifying the status of the service. Under normal circumstances, the general solution would be to remove the lock file and the dead files of […]
How to check the status and space used by images and containers
This post objective is to find out the stats of running container, system information related to space used by images and containers on /var/lib/docker. 1. ‘docker stats‘ command used to check the containers stats on system like CPU usage, IO usage, Memory usage. Below example is for 2 running containers dockerweb and webserver2. # docker […]
6 Bash Shell Command Line Chaining Operators in Linux
Introduction In this article, I will explain you 6 Bash shell command line Chaining Operators (Linux operator). Now let’s discuss what is chaining operator. Chaining operator is something which helps to run multiple commands at once like we execute a script and task completes automatically. Usually, people use Bash shell command line Chaining Operators (Linux […]
What are Shell Scripts? How to Create Shell Scripts?
What Is a Shell? A shell is a program that provides an interface between a user and an operating system (OS) kernel. An OS starts a shell for each user when the user logs in or opens a terminal or console window. What Is a Shell Script? A shell script is a file that contains […]
How to backup and restore Docker containers
The post outlines the steps to take the backup (snapshot) of docker Container and restore it. Please note that this post mainly discusses committing a container as an image. This works on the container that does not use data volume. For containers with data volume, backup of the data volume must be taken separately. Taking […]
Run Docker as a non-root user
The Docker containers by default run with the root privilege and so does the application that runs inside the container. This is another major concern from the security perspective because hackers can gain root access to the Docker host by hacking the application running inside the container. Method 1 – Add user to Docker group […]
How to Configure Btrfs as the Storage Engine in Docker
Docker is an open platform management tool for Linux Containers. It provides a means for developers and system administrators to build and package applications into lightweight containers. Docker uses devicemapper devices as the default storage engine. To use Btrfs as the storage engine, perform the following steps. Note that Red Hat Enterprise Linux (RHEL) removes […]