How to solve mounting error when running docker?

I am running docker on an Amazon m2.large instance running Ubuntu 14.04 LTS
(GNU/Linux 3.13.0-24-generic x86_64).

Here is the output of docker info

  • Persist Data files in docker container
  • How do named volumes work in docker?
  • How to use env attribute of Vagrant Docker provider?
  • Docker webpack dev server
  • Running Desktop Apps on Docker Containers on Windows 10
  • How to push image from private registry to hub.docker.com?
  • Containers: 10
    Images: 72
    Storage Driver: devicemapper
     Pool Name: docker-202:16-475138-pool
     Data file: /mnt/docker/devicemapper/devicemapper/data
     Metadata file: /mnt/docker/devicemapper/devicemapper/metadata
     Data Space Used: 2574.9 Mb
     Data Space Total: 102400.0 Mb
     Metadata Space Used: 4.5 Mb
     Metadata Space Total: 2048.0 Mb
    Execution Driver: native-0.2
    Kernel Version: 3.13.0-24-generic
    WARNING: No swap limit support
    

    Here is the output of docker version:

    Client version: 1.0.1
    Client API version: 1.12
    Go version (client): go1.2.1
    Git commit (client): 990021a
    Server version: 1.0.1
    Server API version: 1.12
    Go version (server): go1.2.1
    Git commit (server): 990021a
    

    I am running docker as follows:

    docker run \
       --volume /mnt/dir_1:/outputs:rw \
       --volume /mnt/dir_2:/inputs:ro \
       --detach=false \
       --cidfile=/mnt/dir_3/container_id \
       my_image \
       arg_1 \
       arg_2
    

    However I get the following error:

    2014/07/01 22:26:59 Error response from daemon: Error mounting '/dev/mapper/docker-202:16-475138-e1d927e16afbf1537f66bb0b6f3df56be7160cea7abefe19059aff2c00c55a0a-init' on '/mnt/docker/devicemapper/mnt/e1d927e16afbf1537f66bb0b6f3df56be7160cea7abefe19059aff2c00c55a0a-init': invalid argument
    

    I already ran this command successfully once and it produced the expected output. Now however it returns this error. How do I solve this? Thanks.

  • Give access to Docker Swarm cluster
  • shell script to connect to docker daemon
  • Should I created three images for Apache http server, php and memcached separately?
  • Cant connect to Mysql docker container from host
  • couchbase - [Errno 113] No route to host
  • CakePHP - How to connect to docker's db container by using socket in CakePHP project
  • One Solution collect form web for “How to solve mounting error when running docker?”

    The solution to this appears to be to move away from the default driver ‘devmapper’ and use the ‘btrfs’ driver which a correspondingly formatted filesystem. An even more performant option, is to use the ‘overlayfs’ driver.

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.