Câu hỏi phỏng vấn Docker
Câu hỏi

Can you create containers wihout their own PID namespace?

Câu trả lời

Yes, you can create containers without their own PID namespace in Docker. By default, Docker creates a separate PID namespace for each container, which isolates the processes running inside the container from those on the host and other containers. However, you can configure a container to share the host's PID namespace by using the --pid flag with the value host when running the docker run or docker create command.

Here is an example command to create a container that shares the host's PID namespace:

bash Copy
docker run --pid host busybox:latest ps

In this configuration, processes inside the container will share the same PID space as processes on the host. This means that processes inside the container can see and interact with processes running on the host, which can lead to potential resource conflicts and security concerns. ...

middle

middle

Gợi ý câu hỏi phỏng vấn

junior

What is Docker image?

junior

What are the various states that a Docker container can be in at any given point in time?

expert

Name some limitations of containers vs VM

Bình luận

Chưa có bình luận nào

Chưa có bình luận nào