I've read the question titled "How is Docker.io different from a normal virtual machine?", but I'm still not certain how "virtual" docker containers are. For example, in a scientific setting, repeatability is very important. If an image produces a certain result on one machine, will the computation be exactly the same on another if using the same image?

(I don't really know at what level different operating systems, kernels, hardware, or architectures can alter calculations in practice, or at what layer Docker abstracts things, if at all.)

Thanks! :)


Docker is just a management layer around an LXC container, essentially a Linux-flavoured jail.

An LXC container uses the same processor and kernel as the host, but uses it's own libraries (i.e. the libraries inside the container filesystem).

So for repeatability, you need to ensure all those attributes are the same. If you already have an answer for this with respect to LXC containers, it's 100% applicable to Docker containers.

| improve this answer | |
  • Thanks for the response @MickeyB. Ok, it seems like running it in a virtual machine would be necessary either way for a truly consistent environment. – Chris Cooper Apr 4 '14 at 23:42

This really depends on which computations you think of:

  • A operation like "multiple the date by 23" is never idempotent because time changes.
  • If your operation's result depends on specific kernel settings, Docker can't guarantee it to be same across different systems
  • If your operation depends on external, physical factors like network latency even a VM won't help.

That said, one of Docker's main goals is to ease repeatable operations. So in most cases, especially in a scientific setting where I doubt the result of a operation/computation ever depends on kernel settings, Docker seems like a good fit. And you're not the first one using it in such environment: http://bcbio.wordpress.com/2014/03/06/improving-reproducibility-and-installation-of-genomic-analysis-pipelines-with-docker/

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.