Docker Community Forums

Share and learn in the Docker community.

Unable to mount existing data volumes in beta 23

beta

(Jonathan Brinley) #1

Expected behavior

Starting a container with an existing data volume should mount that data volume.

Actual behavior

docker: Error response from daemon: missing device in volume options.

Steps to reproduce the behavior

  1. Create a data volume. docker volume create --name mysqldata
  2. Mount the volume in a container. docker run --rm -it -v mysqldata:/var/lib/mysql mysql:5.5 /bin/bash
  3. Reboot the computer.
  4. Mount the volume in a container. docker run --rm -it -v mysqldata:/var/lib/mysql mysql:5.5 /bin/bash

Now docker responds with an error.

docker: Error response from daemon: missing device in volume options.
See 'docker run --help'.

I noticed this after updating to beta 23.

How do I recover the data volume?

Information

Docker for Mac: version: 2f0427a
OS X: version 10.11.6 (build: 15G31)
logs: /tmp/DE98ED6A-CF8C-42C0-B387-CB3A5C604478/20160821-085104.tar.gz
[OK] docker-cli
[OK] virtualization kern.hv_support
[OK] menubar
[OK] moby-syslog
[OK] dns
[OK] disk
[OK] system
[OK] app
[OK] osxfs
[OK] virtualization VT-X
[OK] db
[OK] slirp
[OK] logs
[OK] env
[OK] vmnetd
[OK] moby-console
[OK] moby
[OK] driver.amd64-linux


(Carlos Valiente) #2

Similar behaviour here on my Mac. Looks like my setup is very similar to @jbrinley’s:

Docker for Mac: version: 2f0427a
OS X: version 10.11.6 (build: 15G31)
logs: /tmp/1C8AF78C-40CB-4923-A722-4CAC02100491/20160822-184025.tar.gz
[OK]     docker-cli
[OK]     virtualization kern.hv_support
[OK]     menubar
[OK]     moby-syslog
[OK]     dns
[OK]     disk
[OK]     system
[OK]     app
[OK]     osxfs
[OK]     virtualization VT-X
[OK]     db
[OK]     slirp
[OK]     logs
[OK]     env
[OK]     vmnetd
[OK]     moby-console
[OK]     driver.amd64-linux

(Adamgotterer) #3

`I had the same problem as well. Resetting docker to factory seemed to have fixed the problem.


(Florian Dehn) #4

I had the same issue in Version 1.12.1-beta26.1 (build: 12100)
Resetting docker to factory defaults also fixed the problem for me.