Linux Namespace vs Kubernetes Namespace
People think a Kubernetes namespace is a Linux namespace, and it is not. A Linux namespace is a wall inside one computer. It hides the other programs from a container. A Kubernetes namespace is a label. It splits a cluster into groups, such as one per team. By itself, it walls nothing off.
Kubernetes Namespace
A named area in one Kubernetes cluster. It keeps teams and apps apart.
A Kubernetes namespace splits one cluster into named areas. Each name only has to be unique inside its own namespace. So two teams can both have an app called web. Rules and limits can be set per namespace. A new cluster starts with four, and your work goes in the one called default unless you say otherwise.
Linux Namespace
A Linux trick that gives programs a private view of the system. Each box is built on it.
A Linux namespace gives a group of programs their own private view of one part of the system. In a process namespace, the programs see only each other. In a network namespace, they get their own network cards and ports. Linux has eight kinds. They also cover files, users and the computer's name. A container is mostly a program started inside a set of these.
In one line
- Kubernetes Namespace
- A named area in one Kubernetes cluster. It keeps teams and apps apart.
- Linux Namespace
- A Linux trick that gives programs a private view of the system. Each box is built on it.