Questions tagged [kubernetes]

Kubernetes is an open source container cluster manager.

Filter by
Sorted by
Tagged with
0 votes
0 answers
6 views

Another Kubernetes routing question, access services on bare metal from external network

Its taken me many attempts, and countless hours spread out over various attempts the past two years or so, but I have finally made some real progress on getting a kubernetes cluster setup and working ...
  • 101
1 vote
1 answer
34 views

CLOSE_WAIT not visible on the kubernetes node

Debugging a tcp: out of memory error, I found that a process (from a container) has a lot of connection on CLOSE_WAIT status aka 08 when I cat /proc/XXX/net/tcp But neither netstat or ss were showing ...
  • 293
3 votes
3 answers
182 views

AWK to launch OS commands from items in a CSV file with a jump line

I have a CSV file that looks like: keyuat,carsim,logs-keyuat-carsim lowuat,carsimserver,logs-lowuat-carsimserver utils,dash,logs-utils-dash utils,lifecycle,logs-utils-lifecycle utils,lifecycle-nodejs,...
  • 33
1 vote
0 answers
34 views

Why error "error: open /dev/null.lock: permission denied"?

I try to config kubernetes, but once I run the command kubectl config set-credentials... I get the error error: open /dev/null.lock: permission denied Why is that? When I search for the error, I ...
  • 23
0 votes
0 answers
26 views

Configure Multiple Schedulers

i am trying to do a customize scheduler but i keep getting this error, i am following the official k8s documentation: https://kubernetes.io/docs/tasks/extend-kubernetes/configure-multiple-schedulers/ ...
0 votes
0 answers
15 views

What is the cni.lock file for?

What does the $HOME/.config/cni/net.d/cni.lock file do for (rootless) podman? (I've read cni.lock exists in Docker too, so I've tagged this post Docker as well.) I can control where the container's ...
0 votes
0 answers
13 views

kubeadm init - unable to create ConfigMap

When Installing stacked HA cluster on Ubuntu: LOAD_BALANCER_DNS_LOAD_BALANCER_PORT=192.170.1.165:6443 sudo kubeadm init --v=9 --control-plane-endpoint "$LOAD_BALANCER_DNS_LOAD_BALANCER_PORT"...
  • 143
0 votes
0 answers
18 views

How to change kubernetes cluster name?

I am new to kubernetes. The default cluster name is Kubernetes and I want to rename it to something more meaningful. Can anybody help?
0 votes
0 answers
17 views

Why it have to do SNAT on endpoint IP when do NAT hairpin?

I was trying to figure out how kube-proxy works. So I built a expriment enviroment using docker. There are two containers: net-tool with IP 172.0.0.3 and nginx with IP 172.0.0.4. I use ipvsadm built a ...
0 votes
1 answer
48 views

Get return value from kubectl exec out into powershell script [closed]

So I'm working on a powershell script that runs a pester test. The script connects to a Kubernetes pod with a Mongo database. The goal is to check whether or not a collection in the database is empty. ...
0 votes
2 answers
34 views

is it possible to fix the sh: 1: clear: not found error when login into kubernetes pod

when I login the kubernetes v1.23 pod using this command: exec kubectl exec -i -t -n reddwarf-storage reddwarf-postgresql-postgresql-0 -c reddwarf-postgresql -- sh -c "clear; (bash || ash || sh)&...
  • 409
0 votes
0 answers
20 views

Installing Camunda Modeler in Kubernetes

I am new to Camunda and Kubernetes. I have to install camunda modeler in Kubernetes cluster. I took time to search it in internet but I coundn’t find a way. Is there any possible way to install ...
  • 1
1 vote
0 answers
25 views

When binding to vfio-pci for PCI Passthrough, I lose my ssh connection. How can I overcome this?

I am going through this KubeVirt article on PCI Passthrough. When I get to the step that unbinds the Ethernet controller from the igb driver, I lose my ssh connection. echo 0000:02:00.3 > /sys/bus/...
  • 571
0 votes
1 answer
47 views

How to SSH into Pod from outside a cluster without Internet access ? (K8S)

I created a K8S cluster (2 nodes and 1 master), that has no access to Internet, only the piloting machine has. I wanted to SSH into a Ubuntu-OpenSSH Pod, from outside the cluster and did a port-...
0 votes
0 answers
23 views

How to quickly & transparently re-mount NFS share?

I have 3 nodes running NFS servers all serving the same underlying storage: Node1 10.9.0.1 Node2 10.9.0.2 Node3 10.9.0.3 In addition, I also have a load balancer proxy on 10.9.0.10 which simply ...
2 votes
1 answer
6k views

kubeadm init missing optional cgroups

It seems that since I've updated to the newest kernel (Ubuntu server 22), I get this message during kubeadm init How to get rid of the following error? : user@kubemaster:~$ sudo kubeadm init [init] ...
0 votes
0 answers
122 views

Kubernetes - Can I set Number of Open Files Limit per pod/container?

So in Linux, we can use /proc/sys/fs/file-max to set system(node) wide limit. Is there a way to set per pod/container?
0 votes
1 answer
263 views

No token for microk8s dashboard

I use Rocky Linux 8 and installed micro8ks with Snap. I tried to enable the dashboard of microk8s according to this docu: https://microk8s.io/docs/addon-dashboard microk8s enable dashboard token=$(...
  • 183
1 vote
2 answers
193 views

Why k3s is still seeing swap on Debian Bullseye?

I've installed k3s on Debian Bullseye (on M1 Pro through qemu/UTM). k3s recommend to disable the swap. After reading the answers of the following questions: How to safely turn off swap permanently ...
0 votes
1 answer
80 views

Podman sharing one port with every contianer running in a pod?

On Kubernetes, a typical design paradigm is to share one container on every container running such that they call connect localhost with a given port. Then Kubernetes will route that traffic to the ...
  • 23.9k
0 votes
0 answers
386 views

Alpine: How to forceful remove freetype package from OpenJDK Runtime Environment(Alpine 8.302.08-r2) even if it would break dependencies?

I'm trying to setup a docker config for my java spring applicaiton. So appln is running absolutely fine but We found out that there is a apk package called as freetype which is having critical ...
  • 101
0 votes
1 answer
422 views

How to allow ServiceAccount list namespaces it has access to within a cluster?

I have a cluster with multiple namespaces. Let's call them: ns1 and ns2 I also have multiple service accounts, lets call them sa1 and sa2, all in one namespace - sa-ns. Both users can access all ...
0 votes
0 answers
373 views

Routing outgoing traffic on specific port through specific interface

First of all, I would like to thank you for all the previous answers everywhere? I couldn't get there without them. Learned a lot from the Stackexchange community (both about iptables and more). ...
0 votes
0 answers
20 views

How to configure similar to do-ip6 setting (unbound) in coredns of kubernetes

do-ip6 is an option in unbound dns where we can enable or disable whether ip6 queries are answered or issued. do-ip6: yes or no. Default is yes. If disabled, queries are not answered on IPv6, and ...
0 votes
0 answers
14 views

how to run K8s pod replicas with few variable values in their conf?

I have to run some containers in K8s, more than 1 replicas for a microservice. I'm using configmaps to load the configuration of the microservice. There are few values that need. to be incrementally ...
  • 1,723
0 votes
0 answers
662 views

what does fork/exec : permission denied mean?

I am building a container inside of a container(Gitlab runner kubernetes pod) but it keeps failing. The Dockerfile of the container to build is: FROM ubuntu USER root RUN ["touch", "...
  • 241
0 votes
1 answer
482 views

Kubernetes OutOfcpu error when Requests.cpu == Limits.cpu

I'm running Kubernetes Jobs in which I set limits and requests both to the same number of CPUs. In some of these jobs I'm occasionally seeing OutOfcpu errors When I kubectl describe pods PODNAME I see ...
  • 1,020
1 vote
0 answers
87 views

SQL output piped to `kubectl exec` crashes, if not replacing TABS with SPACES

The context: I'm generating SQL from a backup dump, inside a subshell, to then pipe it to mysql for execution: ( echo "SET FOREIGN_KEY_CHECKS=0;"; tar --to-stdout -xvjf archive.tar; echo &...
1 vote
1 answer
53 views

Linux picking wrong source IP

I have an EC2 instance running on a k8s cluster. The instance has three three interface cards. 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000 ...
2 votes
1 answer
386 views

How can "/sys/class/net/eth0/iflink" have system wide information in a container

I was looking for ways to tcpdump a Kubernetes pod. Each pod creates a virtual interface and it is hard to know which interface belongs to the actual pod. I found a method that helps identify the ...
  • 191
0 votes
0 answers
47 views

The platform does not support either IP_TRANSPARENT or IPV6_TRANSPARENT

How to make a Linux host IP_TRANSPARENT or IPV6_TRANSPARENT? Basically, we are trying to install an envoyproxy container in Kubernetes (on-prem). We are getting the error below. But if we remove '...
0 votes
1 answer
229 views

How to use the linux top command to get cpu usage metrics inside a pod

I'm currently looking at the solution to get the cpu usage metrics using the linux "top" command. with top command I see that it only gives a momentary cpu stats. How can I get a metrics ...
0 votes
0 answers
502 views

How get mobaxterm work with kubectl?

mobaxterm is not able to read kube config setting when using with kubectl. I am using MobaXterm_21.2 installed version. When i run - kubectl version, its woking as expected  kubectl version Client ...
  • 604
0 votes
0 answers
77 views

Kubelet fails to pull any image

I tried deploying this image from docker hub onto a pod in my lab. The pod gets stuck on "ContainerCreating" and when I run kubectl describe pod, I see the following in loop Normal ...
0 votes
1 answer
40 views

Does the "offical" HAProxy ingress controller provide drain support?

We're exploring using the "offical" HARoxy ingress controller (https://www.haproxy.com/documentation/kubernetes/latest/) and require traffic to continue to be sent to a pod that is in a ...
2 votes
1 answer
535 views

Backspace in shell moves cursor to the right

There's this remote shell I login into that, when I try to delete a character, instead of visually showing the character being deleted, it remains there and the cursor moves to the right. This shell ...
0 votes
2 answers
583 views

multiple schedules for a single task in a k8s cronjob

Warning: k8s greenhorn on this side. I need to run a task that will be set up in a k8s cronjob. I need it to run every 45 minutes. Having this in the schedule does not work: 0/45 * * * * Because it ...
  • 515
2 votes
0 answers
754 views

Is setting cgroup_enable=cpuset necessary in this case?

I am setting up a raspberry pi based cluster using kubeadm and containerd as the CRI. I have 8GB nodes and I have installed Ubuntu 20.04 on them. I need to setup cgroups and the various instructions ...
1 vote
0 answers
30 views

Maximum open security on NFS export of shared directory

I have a huge problem with Kubernetes and permission problems with PVCs. Here's my NFS export line: /srv/nfs4 192.168.1.0/24(rw,sync,no_subtree_check,crossmnt,fsid=0) /srv/nfs4/k8s ...
0 votes
1 answer
23 views

Who should be allowed access to /etc/kubernetes/pki/ca.crt?

Beginners' question. Who would you allow access to /etc/kubernetes/pki/ca.crt? What damage to you cluster if someone is not a cluster administrator has got access (e.g. copying and distributing, ...
0 votes
1 answer
378 views

stdin buffer - what is it?

While reading the "Kubernetes in Action" book I saw the following excerpt (p. 124): Listing 5.2 Enabling standard input for a container apiVersion: v1 kind: Pod metadata: name: kiada-...
  • 259
2 votes
0 answers
124 views

Make memory.limit_in_bytes ignore file cache

When using cgroups (either standalone or as part of docker or kubernetes) memory.limit_in_bytes counts file cache towards the processes memory usage. This has an unexpected side effect that I'm trying ...
  • 121
1 vote
0 answers
220 views

Inodes on /run filesystem is full

Inode on /run is getting full for all our nodes that are being managed by EKS, especially for small instances like t3a.medium below output from df -i. Filesystem Inodes IUsed IFree IUse% Mounted ...
  • 11
0 votes
0 answers
154 views

How does DNS work in Kubernetes?

I'm having issue with DNS resolve in Kubernetes. It's quite complex, please be patient to read. ENV: On-premise and private Cloud OS Ubuntu Server 20.04 LTS System Network: VPN s2s Custom DNS (10....
  • 1
1 vote
1 answer
143 views

zsh - How to properly create a shortcut for inline expansion of a long command

I'm trying to figure out the best way to create inline expansions of fragments of commands. The "long form" would be like: kubectl get pods --show-labels or kubectl get po -o custom-...
  • 11
1 vote
0 answers
252 views

Errors when trying to get kubectl completion working

My question is why do I see this error when trying to get kubectl autocomplete working in my terminal. I really only care about getting the zsh one working. I'm simply using some other examples of ...
-2 votes
1 answer
452 views

error: unable to find container named "container-name" [closed]

When I using this command to update container in kubernetes cluster in GitHub Actions: - name: deploy to cluster uses: steebchen/kubectl@v2.0.0 with: # defaults to latest kubectl binary ...
  • 409
1 vote
0 answers
92 views

what privillege should I give to the kubernetes nfs mount path

when I start the postgresql in kubernetes cluster, the log look like this: postgresql 07:00:48.68 postgresql 07:00:48.68 Welcome to the Bitnami postgresql container postgresql 07:00:48.68 Subscribe ...
  • 409
1 vote
1 answer
1k views

How to deal with special characters in docker registry credential in new version of kubectl

Today I want to add a docker registry credential in kubernetes v1.21.3 (it works fine in lower version of kubernetes but have problem in new version of kubernetes): kubectl create secret docker-...
  • 409
0 votes
1 answer
87 views

invalid subcommand: "upload" when using kubeadm to upload config

When I want to use kubeadm kubeadm version: &version.Info{Major:"1", Minor:"21", GitVersion:"v1.21.3", GitCommit:"ca643a4d1f7bfe34773c74f79527be4afd95bf39", ...
  • 409