Skip to main content

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ranrun.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what are those images, really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do docker run ubuntu echo "hello world", it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world".

In the same way when we do docker run -it ubuntu /bin/bash, it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what are those images named after operating systems are all about? How different it is it to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

TheIs the idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ran.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what those images really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do docker run ubuntu echo "hello world", it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world".

In the same way when we do docker run -it ubuntu /bin/bash, it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what those images named after operating systems are all about? How different it is to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

The idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is run.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what are those images, really? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do docker run ubuntu echo "hello world", it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world".

In the same way when we do docker run -it ubuntu /bin/bash, it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what are those images named after operating systems all about? How different is it to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

Is the idea that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

Tweeted twitter.com/ServerFault/status/743650122211393536
added 5 characters in body
Source Link
GregL
  • 9.9k
  • 2
  • 28
  • 37

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ran.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what those images really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do

docker run ubuntu echo "hello world" docker run ubuntu echo "hello world", it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world"echo "hello world". 

In the same way when we do

docker run -it ubuntu /bin/bash itdocker run -it ubuntu /bin/bash, it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what those images named after operating systems are all about? How different it is to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

The idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ran.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what those images really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do

docker run ubuntu echo "hello world" it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world". In the same way when we do

docker run -it ubuntu /bin/bash it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what those images named after operating systems are all about? How different it is to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

The idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ran.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what those images really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do docker run ubuntu echo "hello world", it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world". 

In the same way when we do docker run -it ubuntu /bin/bash, it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what those images named after operating systems are all about? How different it is to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

The idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?

Source Link
user1620696
  • 1.5k
  • 2
  • 11
  • 9

Why do we use a OS Base Image with Docker if containers have no Guest OS?

I've just started to study Docker and there's something that's being quite confusing for me. As I've read on Docker's website a container is different from a virtual machine. As I understood a container is just a sandbox inside of which an entire isolated file system is ran.

I've also read that a container doesn't have a Guest OS installed. Instead it relies on the underlying OS Kernel.

All of that is fine. What I'm confused is that there are Docker images named after operating systems. We see images like Ubuntu, Debian, Fedora, CentOS and so on.

My point is: what those images really are? How is it different creating a container based on the Debian image than creating a Virtual Machine and installing Debian?

I thought containers had no Guest OS installed, but when we create images we base them on some image named after one OS.

Also, in examples I saw when we do

docker run ubuntu echo "hello world" it seems we are spinning up a VM with Ubuntu and making it run the command echo "hello world". In the same way when we do

docker run -it ubuntu /bin/bash it seems we are spinning up a VM with Ubuntu and accessing it using command line.

Anyway, what those images named after operating systems are all about? How different it is to run a container with one of those images and spinning up a VM with the corresponding Guest OS?

The idea is that we just share the kernel with the host OS (and consequently we have access to the underlying machine hardware resources, without the need to virtualize hardware), but still use the files and binaries of each different system on the containers in order to support whatever application we want to run?