New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error starting daemon: error initializing graphdriver: driver not supported #15651

Closed
alambike opened this Issue Aug 18, 2015 · 46 comments

Comments

Projects
None yet
@alambike
Copy link
Contributor

alambike commented Aug 18, 2015

After upgrade from 1.7.1 to 1.8.1 docker daemon refuse to start. It fails with this error log message:

ERRO[0000] Failed to GetDriver graph btrfs /lxc/docker  
FATA[0000] Error starting daemon: error initializing graphdriver: driver not supported 

docker version:
Client:
Version: 1.8.1
API version: 1.20
Go version: go1.4.2
Git commit: d12ea79
Built: Thu Aug 13 02:32:18 UTC 2015
OS/Arch: linux/amd64
Cannot connect to the Docker daemon. Is 'docker -d' running on this host?

uname -a:
Linux alambike-MM061 3.13.0-61-generic #100~precise1-Ubuntu SMP Wed Jul 29 12:06:40 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux

I was running docker in my laptop, with ubuntu 12.04, with the btrfs driver, but after upgrade from 1.7.1 to 1.8.1 the docker daemon refuses to start.
The upgrade process was made with the recommended script curl -sSL https://get.docker.com/ | sh

It seems can't find correct driver now

# docker -s btrfs -d -D
Warning: '-d' is deprecated, it will be removed soon. See usage.
WARN[0000] please use 'docker daemon' instead.          
DEBU[0000] Registering GET, /images/search              
DEBU[0000] Registering GET, /containers/json            
DEBU[0000] Registering GET, /containers/{name:.*}/export 
DEBU[0000] Registering GET, /containers/{name:.*}/json  
DEBU[0000] Registering GET, /containers/{name:.*}/attach/ws 
DEBU[0000] Registering GET, /info                       
DEBU[0000] Registering GET, /version                    
DEBU[0000] Registering GET, /containers/ps              
DEBU[0000] Registering GET, /containers/{name:.*}/top   
DEBU[0000] Registering GET, /containers/{name:.*}/stats 
DEBU[0000] Registering GET, /containers/{name:.*}/archive 
DEBU[0000] Registering GET, /_ping                      
DEBU[0000] Registering GET, /events                     
DEBU[0000] Registering GET, /images/json                
DEBU[0000] Registering GET, /images/get                 
DEBU[0000] Registering GET, /images/{name:.*}/get       
DEBU[0000] Registering GET, /images/{name:.*}/history   
DEBU[0000] Registering GET, /images/{name:.*}/json      
DEBU[0000] Registering GET, /containers/{name:.*}/changes 
DEBU[0000] Registering GET, /containers/{name:.*}/logs  
DEBU[0000] Registering GET, /exec/{id:.*}/json          
DEBU[0000] Registering POST, /images/{name:.*}/tag      
DEBU[0000] Registering POST, /containers/{name:.*}/pause 
DEBU[0000] Registering POST, /containers/{name:.*}/rename 
DEBU[0000] Registering POST, /commit                    
DEBU[0000] Registering POST, /images/create             
DEBU[0000] Registering POST, /images/load               
DEBU[0000] Registering POST, /images/{name:.*}/push     
DEBU[0000] Registering POST, /containers/{name:.*}/unpause 
DEBU[0000] Registering POST, /containers/{name:.*}/restart 
DEBU[0000] Registering POST, /exec/{name:.*}/resize     
DEBU[0000] Registering POST, /containers/{name:.*}/resize 
DEBU[0000] Registering POST, /containers/create         
DEBU[0000] Registering POST, /containers/{name:.*}/kill 
DEBU[0000] Registering POST, /containers/{name:.*}/start 
DEBU[0000] Registering POST, /containers/{name:.*}/stop 
DEBU[0000] Registering POST, /containers/{name:.*}/copy 
DEBU[0000] Registering POST, /containers/{name:.*}/exec 
DEBU[0000] Registering POST, /exec/{name:.*}/start      
DEBU[0000] Registering POST, /auth                      
DEBU[0000] Registering POST, /build                     
DEBU[0000] Registering POST, /containers/{name:.*}/wait 
DEBU[0000] Registering POST, /containers/{name:.*}/attach 
DEBU[0000] Registering PUT, /containers/{name:.*}/archive 
DEBU[0000] Registering DELETE, /containers/{name:.*}    
DEBU[0000] Registering DELETE, /images/{name:.*}        
DEBU[0000] Registering OPTIONS,                         
DEBU[0000] Registering HEAD, /containers/{name:.*}/archive 
DEBU[0000] [graphdriver] trying provided driver "btrfs" 
ERRO[0000] Failed to GetDriver graph btrfs /lxc/docker  
DEBU[0000] docker group found. gid: 999                 
INFO[0000] Listening for HTTP on unix (/var/run/docker.sock) 
FATA[0000] Error starting daemon: error initializing graphdriver: driver not supported 
@GordonTheTurtle

This comment has been minimized.

Copy link

GordonTheTurtle commented Aug 18, 2015

Hi!

Please read this important information about creating issues.

If you are reporting a new issue, make sure that we do not have any duplicates already open. You can ensure this by searching the issue list for this repository. If there is a duplicate, please close your issue and add a comment to the existing issue instead.

If you suspect your issue is a bug, please edit your issue description to include the BUG REPORT INFORMATION shown below. If you fail to provide this information within 7 days, we cannot debug your issue and will close it. We will, however, reopen it if you later provide the information.

This is an automated, informational response.

Thank you.

For more information about reporting issues, see https://github.com/docker/docker/blob/master/CONTRIBUTING.md#reporting-other-issues


BUG REPORT INFORMATION

Use the commands below to provide key information from your environment:

docker version:
docker info:
uname -a:

Provide additional environment details (AWS, VirtualBox, physical, etc.):

List the steps to reproduce the issue:
1.
2.
3.

Describe the results you received:

Describe the results you expected:

Provide additional info you think is important:

----------END REPORT ---------

#ENEEDMOREINFO

@cpuguy83

This comment has been minimized.

Copy link
Contributor

cpuguy83 commented Aug 18, 2015

Failed to GetDriver graph btrfs /lxc/docker

Where is it getting this /lxc/docker path from?

@alambike

This comment has been minimized.

Copy link
Contributor

alambike commented Aug 18, 2015

I'm using a link in /var/lib/docker to a partition in btrfs

ls -l /var/lib/docker
lrwxrwxrwx 1 root root 11 jun 25  2014 /var/lib/docker -> /lxc/docker
mount
...
/dev/sda6 on /lxc type btrfs (rw)
@cpuguy83

This comment has been minimized.

Copy link
Contributor

cpuguy83 commented Aug 18, 2015

@alambike Ah, interesting.
Does this work if you do docker -d -D -s btrfs -g /lxc/docker?

@sleaze

This comment has been minimized.

Copy link

sleaze commented Aug 18, 2015

I'm also hitting this issue with the current docker (installed via the curl docker.io.. cmd).

additional note:

I'm not using btrfs, just aufs.

@alambike

This comment has been minimized.

Copy link
Contributor

alambike commented Aug 19, 2015

Sorry for the delay, same result with -g /lxc/docker

docker daemon -D -s btrfs -g /lxc/docker
DEBU[0000] Registering GET, /version                    
DEBU[0000] Registering GET, /containers/ps              
DEBU[0000] Registering GET, /containers/{name:.*}/changes 
DEBU[0000] Registering GET, /containers/{name:.*}/json  
DEBU[0000] Registering GET, /events                     
DEBU[0000] Registering GET, /images/search              
DEBU[0000] Registering GET, /images/get                 
DEBU[0000] Registering GET, /images/{name:.*}/get       
DEBU[0000] Registering GET, /images/{name:.*}/history   
DEBU[0000] Registering GET, /containers/json            
DEBU[0000] Registering GET, /containers/{name:.*}/export 
DEBU[0000] Registering GET, /containers/{name:.*}/archive 
DEBU[0000] Registering GET, /info                       
DEBU[0000] Registering GET, /containers/{name:.*}/top   
DEBU[0000] Registering GET, /containers/{name:.*}/logs  
DEBU[0000] Registering GET, /containers/{name:.*}/stats 
DEBU[0000] Registering GET, /exec/{id:.*}/json          
DEBU[0000] Registering GET, /_ping                      
DEBU[0000] Registering GET, /images/json                
DEBU[0000] Registering GET, /images/{name:.*}/json      
DEBU[0000] Registering GET, /containers/{name:.*}/attach/ws 
DEBU[0000] Registering POST, /containers/create         
DEBU[0000] Registering POST, /containers/{name:.*}/kill 
DEBU[0000] Registering POST, /containers/{name:.*}/start 
DEBU[0000] Registering POST, /containers/{name:.*}/stop 
DEBU[0000] Registering POST, /containers/{name:.*}/resize 
DEBU[0000] Registering POST, /containers/{name:.*}/exec 
DEBU[0000] Registering POST, /exec/{name:.*}/start      
DEBU[0000] Registering POST, /auth                      
DEBU[0000] Registering POST, /build                     
DEBU[0000] Registering POST, /containers/{name:.*}/wait 
DEBU[0000] Registering POST, /containers/{name:.*}/attach 
DEBU[0000] Registering POST, /containers/{name:.*}/copy 
DEBU[0000] Registering POST, /containers/{name:.*}/pause 
DEBU[0000] Registering POST, /containers/{name:.*}/rename 
DEBU[0000] Registering POST, /commit                    
DEBU[0000] Registering POST, /images/create             
DEBU[0000] Registering POST, /images/load               
DEBU[0000] Registering POST, /images/{name:.*}/push     
DEBU[0000] Registering POST, /images/{name:.*}/tag      
DEBU[0000] Registering POST, /containers/{name:.*}/unpause 
DEBU[0000] Registering POST, /containers/{name:.*}/restart 
DEBU[0000] Registering POST, /exec/{name:.*}/resize     
DEBU[0000] Registering PUT, /containers/{name:.*}/archive 
DEBU[0000] Registering DELETE, /containers/{name:.*}    
DEBU[0000] Registering DELETE, /images/{name:.*}        
DEBU[0000] Registering OPTIONS,                         
DEBU[0000] Registering HEAD, /containers/{name:.*}/archive 
DEBU[0000] [graphdriver] trying provided driver "btrfs" 
ERRO[0000] Failed to GetDriver graph btrfs /lxc/docker  
FATA[0000] Error starting daemon: error initializing graphdriver: driver not supported 
@cpuguy83

This comment has been minimized.

Copy link
Contributor

cpuguy83 commented Aug 20, 2015

Can you run the script from https://github.com/docker/docker/blob/master/contrib/check-config.sh and paste the output?

@alambike

This comment has been minimized.

Copy link
Contributor

alambike commented Aug 20, 2015

warning: /proc/config.gz does not exist, searching other paths for kernel config ...
info: reading kernel config from /boot/config-3.13.0-61-generic ...

Generally Necessary:
- cgroup hierarchy: properly mounted [/sys/fs/cgroup]
- apparmor: enabled and tools installed
- CONFIG_NAMESPACES: enabled
- CONFIG_NET_NS: enabled
- CONFIG_PID_NS: enabled
- CONFIG_IPC_NS: enabled
- CONFIG_UTS_NS: enabled
- CONFIG_DEVPTS_MULTIPLE_INSTANCES: enabled
- CONFIG_CGROUPS: enabled
- CONFIG_CGROUP_CPUACCT: enabled
- CONFIG_CGROUP_DEVICE: enabled
- CONFIG_CGROUP_FREEZER: enabled
- CONFIG_CGROUP_SCHED: enabled
- CONFIG_CPUSETS: enabled
- CONFIG_MEMCG: enabled
- CONFIG_MACVLAN: enabled (as module)
- CONFIG_VETH: enabled (as module)
- CONFIG_BRIDGE: enabled (as module)
- CONFIG_BRIDGE_NETFILTER: enabled
- CONFIG_NF_NAT_IPV4: enabled (as module)
- CONFIG_IP_NF_FILTER: enabled (as module)
- CONFIG_IP_NF_TARGET_MASQUERADE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_ADDRTYPE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_CONNTRACK: enabled (as module)
- CONFIG_NF_NAT: enabled (as module)
- CONFIG_NF_NAT_NEEDED: enabled
- CONFIG_POSIX_MQUEUE: enabled

Optional Features:
- CONFIG_MEMCG_KMEM: enabled
- CONFIG_MEMCG_SWAP: enabled
- CONFIG_MEMCG_SWAP_ENABLED: missing
    (note that cgroup swap accounting is not enabled in your kernel config, you can enable it by setting boot option "swapaccount=1")
- CONFIG_RESOURCE_COUNTERS: enabled
- CONFIG_BLK_CGROUP: enabled
- CONFIG_IOSCHED_CFQ: enabled
- CONFIG_CGROUP_PERF: enabled
- CONFIG_CGROUP_HUGETLB: enabled
- CONFIG_NET_CLS_CGROUP: enabled (as module)
- CONFIG_NETPRIO_CGROUP: enabled (as module)
- CONFIG_CFS_BANDWIDTH: enabled
- CONFIG_FAIR_GROUP_SCHED: enabled
- CONFIG_RT_GROUP_SCHED: missing
- CONFIG_EXT3_FS: missing
- CONFIG_EXT3_FS_XATTR: missing
- CONFIG_EXT3_FS_POSIX_ACL: missing
- CONFIG_EXT3_FS_SECURITY: missing
    (enable these ext3 configs if you are using ext3 as backing filesystem)
- CONFIG_EXT4_FS: enabled
- CONFIG_EXT4_FS_POSIX_ACL: enabled
- CONFIG_EXT4_FS_SECURITY: enabled
- Storage Drivers:
  - "aufs":
    - CONFIG_AUFS_FS: enabled (as module)
  - "btrfs":
    - CONFIG_BTRFS_FS: enabled (as module)
  - "devicemapper":
    - CONFIG_BLK_DEV_DM: enabled
    - CONFIG_DM_THIN_PROVISIONING: enabled (as module)
  - "overlay":
    - CONFIG_OVERLAY_FS: missing
  - "zfs":
    - /dev/zfs: missing
    - zfs command: missing
    - zpool command: missing
@Julio-Guerra

This comment has been minimized.

Copy link

Julio-Guerra commented Aug 21, 2015

More or less the same happened to me after switching to debian stretch which is now under linux 4.1 and since aufs support is dropped from debian 9 packaging (https://lists.debian.org/debian-kernel/2014/12/msg00136.html), I had to switch to overlayfs. I now have to compile aufs module to export my images and import them back to docker with overlayfs...

For the record, check-config.sh script returns :

warning: /proc/config.gz does not exist, searching other paths for kernel config ...
info: reading kernel config from /boot/config-4.1.0-1-amd64 ...

Generally Necessary:
- cgroup hierarchy: properly mounted [/sys/fs/cgroup]
- CONFIG_NAMESPACES: enabled
- CONFIG_NET_NS: enabled
- CONFIG_PID_NS: enabled
- CONFIG_IPC_NS: enabled
- CONFIG_UTS_NS: enabled
- CONFIG_DEVPTS_MULTIPLE_INSTANCES: enabled
- CONFIG_CGROUPS: enabled
- CONFIG_CGROUP_CPUACCT: enabled
- CONFIG_CGROUP_DEVICE: enabled
- CONFIG_CGROUP_FREEZER: enabled
- CONFIG_CGROUP_SCHED: enabled
- CONFIG_CPUSETS: enabled
- CONFIG_MEMCG: enabled
- CONFIG_MACVLAN: enabled (as module)
- CONFIG_VETH: enabled (as module)
- CONFIG_BRIDGE: enabled (as module)
- CONFIG_BRIDGE_NETFILTER: enabled (as module)
- CONFIG_NF_NAT_IPV4: enabled (as module)
- CONFIG_IP_NF_FILTER: enabled (as module)
- CONFIG_IP_NF_TARGET_MASQUERADE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_ADDRTYPE: enabled (as module)
- CONFIG_NETFILTER_XT_MATCH_CONNTRACK: enabled (as module)
- CONFIG_NF_NAT: enabled (as module)
- CONFIG_NF_NAT_NEEDED: enabled
- CONFIG_POSIX_MQUEUE: enabled

Optional Features:
- CONFIG_MEMCG_KMEM: missing
- CONFIG_MEMCG_SWAP: enabled
- CONFIG_MEMCG_SWAP_ENABLED: missing
    (note that cgroup swap accounting is not enabled in your kernel config, you can enable it by setting boot option "swapaccount=1")
- CONFIG_BLK_CGROUP: enabled
- CONFIG_IOSCHED_CFQ: enabled
- CONFIG_CGROUP_PERF: enabled
- CONFIG_CGROUP_HUGETLB: missing
- CONFIG_NET_CLS_CGROUP: enabled (as module)
- CONFIG_CGROUP_NET_PRIO: enabled
- CONFIG_CFS_BANDWIDTH: missing
- CONFIG_FAIR_GROUP_SCHED: enabled
- CONFIG_RT_GROUP_SCHED: missing
- CONFIG_EXT3_FS: missing
- CONFIG_EXT3_FS_XATTR: missing
- CONFIG_EXT3_FS_POSIX_ACL: missing
- CONFIG_EXT3_FS_SECURITY: missing
    (enable these ext3 configs if you are using ext3 as backing filesystem)
- CONFIG_EXT4_FS: enabled (as module)
- CONFIG_EXT4_FS_POSIX_ACL: enabled
- CONFIG_EXT4_FS_SECURITY: enabled
- Storage Drivers:
  - "aufs":
    - CONFIG_AUFS_FS: missing
  - "btrfs":
    - CONFIG_BTRFS_FS: enabled (as module)
  - "devicemapper":
    - CONFIG_BLK_DEV_DM: enabled (as module)
    - CONFIG_DM_THIN_PROVISIONING: enabled (as module)
  - "overlay":
    - CONFIG_OVERLAY_FS: enabled (as module)
  - "zfs":
    - /dev/zfs: missing
    - zfs command: missing
    - zpool command: missing
@alambike

This comment has been minimized.

Copy link
Contributor

alambike commented Aug 24, 2015

I think the problem is motivated by the compilation flags for deb package in ubuntu precise:
https://github.com/docker/docker/blob/master/contrib/builder/deb/ubuntu-debootstrap-precise/Dockerfile

I just downloaded the docker binary and works ok.

@cpuguy83

This comment has been minimized.

Copy link
Contributor

cpuguy83 commented Aug 24, 2015

ping @jfrazelle

@dustinlacewell

This comment has been minimized.

Copy link

dustinlacewell commented Aug 27, 2015

Can confirm. Same behavior as above using btrfs. Installing the binary directly fixed the issue.

@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Aug 30, 2015

@tianon

This comment has been minimized.

Copy link
Member

tianon commented Aug 31, 2015

https://github.com/docker/docker/blob/166412e529b3d2d49456fb27c117fa714d7aec16/contrib/builder/deb/generate.sh#L66-L73 has the relevant comments for why those are there:

  # - libdevmapper-dev is missing critical structs (too old)

  # - btrfs-tools is missing "ioctl.h" (too old), so it's useless
  #   (since kernels on precise are old too, just skip btrfs entirely)

The packages in Ubuntu 12.04 are too old to properly support compiling Docker with support for either devicemapper or btrfs, but with how old 12.04 is now (and especially with how old the kernels there are), using btrfs is somewhat shaky too. If someone could convince an Ubuntu developer to maintain btrfs-tools in precise-backports, we could consider changing this, but as-is we really don't have a lot of choice here.

I would highly recommend upgrading any system still running 12.04 to at least 14.04 ASAP.

@alambike

This comment has been minimized.

Copy link
Contributor

alambike commented Sep 2, 2015

OK, good to know, thanks for the info.
I have the ubuntu-precise in my older laptop, and have installed the HWE to update my kernel to 3.13, but the btrfs-tool package remains in a older version.

@alambike alambike closed this Sep 26, 2015

@allamand

This comment has been minimized.

Copy link

allamand commented Nov 24, 2015

I have similar issue after upgrading a kernel of my ubuntu 14.04 to kernel 3.16 using this tuto http://ubuntuhandbook.org/index.php/2014/08/install-upgrade-linux-kernel-3-16/

docker-machine can't manage to configure properly my docker daemon

INFO[0000] API listen on /var/run/docker.sock           
WARN[0000] Usage of loopback devices is strongly discouraged for production use. Please use `--storage-opt dm.thinpooldev` or use `man docker` to refer to dm.thinpooldev section. 
/var/run/docker.sock is up
WARN[0000] XFS is not supported in your system. Either the kernel doesnt support it or mkfs.xfs is not in your PATH. Defaulting to ext4 filesystem 
WARN[0008] Running modprobe bridge br_netfilter failed with message: modprobe: WARNING: Module br_netfilter not found.
insmod /lib/modules/3.16.0-031600-generic/kernel/net/llc/llc.ko 
insmod /lib/modules/3.16.0-031600-generic/kernel/net/802/stp.ko 
insmod /lib/modules/3.16.0-031600-generic/kernel/net/bridge/bridge.ko 
, error: exit status 1 
INFO[0008] Firewalld running: false                     
INFO[0008] Default bridge (docker0) is assigned with an IP address 172.17.0.0/16. Daemon option --bip can be used to set a preferred IP address 
WARN[0008] Your kernel does not support swap memory limit. 
INFO[0008] Loading containers: start.                   

INFO[0008] Loading containers: done.                    
INFO[0008] Daemon has completed initialization          
INFO[0008] Docker daemon                                 commit=a34a1d5 execdriver=native-0.2 graphdriver=devicemapper version=1.9.1
INFO[0008] GET /v1.21/version                           
INFO[0009] GET /v1.21/version                           
INFO[0010] Processing signal 'terminated'               
FATA[0000] Error starting daemon: error initializing graphdriver: driver not supported 
@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Nov 24, 2015

@sebmoule that's most likely because you no longer have aufs installed after the upgrade. You can try installing it; see http://docs.docker.com/engine/installation/ubuntulinux/#prerequisites-by-ubuntu-version. But regardless, that doesn't sound like a bug in docker, but something going wrong upgrading the kernel.

@merwan

This comment has been minimized.

Copy link

merwan commented Dec 3, 2015

I upgraded from Debian Jessie to testing and I'm now using linux-image-4.2 and I encountered the same kind of issue with a missing aufs driver.

A quick fix is to delete the docker aufs folder. You might lose some data, so please do it with care!

sudo rm -rf /var/lib/docker/aufs
@YesThatAllen

This comment has been minimized.

Copy link

YesThatAllen commented Dec 20, 2015

Curious what some data might include...

@merwan

This comment has been minimized.

Copy link

merwan commented Dec 20, 2015

@YesThatAllen : you may lose all your containers and images. If you can rebuild them easily then it's not really a problem.
I first switched to device-mapper driver but I encountered another issue which filled up my / partition. I'm now using btrfs, I hope it will work well...

@YesThatAllen

This comment has been minimized.

Copy link

YesThatAllen commented Dec 20, 2015

Thanks @merwan

In my case, removing the aufs folder set up a failure where docker couldn't find an ID.

A dose of rm -rf /var/lib/docker/ and a complete reinstall of docker-engine made things right without real data loss.

@dradux

This comment has been minimized.

Copy link

dradux commented Jan 11, 2016

Thanks @merwan for the quick fix
FYI, I /var/lib/docker mounted as a xfs partition which was working fine with an older version of docker but an upgrade to 1.9.1 caused a "docker error initializing graphdriver: driver not supported". I uninstalled all of docker-engine and cleaned the /var/lib/docker directory. Then reinstalled docker-image and all is working fine now.

@mglantz

This comment has been minimized.

Copy link

mglantz commented Jan 13, 2016

I hit this when upgrading from Red Hat Enterprise Linux 7.1 to 7.2 which took me from docker-1.6.0-11.el7.x86_64 to docker-1.8.2-8.el7.x86_64. To get this solved, I had to do:

systemctl stop docker
rm -rf /var/lib/docker
lvremove /dev/volumegroup/docker-pool
docker-storage-setup
systemctl start docker

@linas

This comment has been minimized.

Copy link

linas commented Feb 19, 2016

This one bit me too, its now 6 months later.

@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Feb 19, 2016

@linas it's not a bug; this error is because a graph driver that was previously used is no longer available, or multiple "graph" directories were found (e.g. directories for both aufs and devicemapper were found). Instead of "randomly" picking one of them (leading to "where have my images gone"?), Docker will refuse to start, and ask you to either specify which graph-driver you want to use, or remove the directory of the graph-driver you're no longer using.

If the graphdriver you used previously is no longer working on your system (which may be the result of, e.g., upgrading your kernel, without installing the new dependencies for your graph-driver - people using aufs can run into this if linux-image-extra is not installed for the new kernel version), at least you know that it's not supported, so that something needs to be addressed before docker is started.

@linas

This comment has been minimized.

Copy link

linas commented Feb 22, 2016

@thaJeztah I guess that's a reasonable explanation. Let me mention my use case: every few months, I have a need to fiddle with Docker. I do nothing special to manage it -- basically, ignore it -- I installed it a few years ago, and have been doing nothing but apt-get upgrade ever since. Perhaps there have been new kernels, I don't recall. I am using a stock, default, mostly-unmodified version of ubuntu trusty and that's that. A few days ago, I had to dust off some old Docker images and was surprised by the error. Google search on the error string lead me here. I have no clue what a graph driver is, I just rm -r * 'ed the entire /var/lib/docker directory, and was back in business. No harm done.

So really, this was a 'me-too' +1 type post: sometimes, QA teams are interested in finding out how many users/customers are being bitten by some particular bug/issue/feature, so as to focus appropriate attention on it.

@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Feb 22, 2016

@linas thanks; in that case, it's plausible that during one of those upgrades, the requirements for the graph-driver ("storage driver") was missing, or not available until restart. If you're interested in learning what storage/graph-drivers are; this section of the docs explains them; https://docs.docker.com/engine/userguide/storagedriver/imagesandcontainers/

@saada

This comment has been minimized.

Copy link

saada commented Apr 21, 2016

@linas , you're a life saver! rm -r /var/lib/docker did the trick to get us back in business!

@avbentem

This comment has been minimized.

Copy link

avbentem commented May 1, 2016

For me, on a Raspberry Pi using http://blog.hypriot.com/post/your-number-one-source-for-docker-on-arm/ the Error starting daemon: error initializing graphdriver: driver not supported error was indeed caused by a pending restart after an earlier sudo apt-get update and sudo apt-get dist-upgrade.

In other words: I restarted, and ran sudo apt-get install docker-hypriot=1.10.3-1 from that blog without any further problems.

@bogste

This comment has been minimized.

Copy link

bogste commented Feb 4, 2017

The answer at #14026 (comment) worked for me.

I just upgraded the Kernel to 4.9 and was getting:

[graphdriver] prior storage driver aufs failed: driver not supported

Moved the /var/lib/docker/aufs folder to my $HOME_DIR/Backups/docker (just in case) and was able to run service docker stop/start. Now it starts up as it should!

@lrbnew

This comment has been minimized.

Copy link

lrbnew commented Apr 5, 2017

I have met this problem when I change kernel and reboot my Centos7.2 server , but I solved it:

Just only remove the file in /var/lib/docker , then docker daemon will work
rm -rf /var/lib/docker

@nathanchere

This comment has been minimized.

Copy link

nathanchere commented Apr 9, 2017

Still an issue on a clean docker install so much later.
rm -r /var/lib/docker still fixes it, but odd to have it occur on a first time install on a clean machine?

@lordfolken

This comment has been minimized.

Copy link

lordfolken commented Apr 11, 2017

hit the same issue installing docker-ce on debian jessie today. rm -rfing the docker lib dir fixes it.

@cpuguy83

This comment has been minimized.

Copy link
Contributor

cpuguy83 commented Apr 11, 2017

rm -rf isn't fixing anything, it's just removing your old data dir and as such automatically selecting a new storage driver.
I suspect you were using some driver like AUFS and performed a kernel upgrade without also updating the AUFS kernel mod for the new kernel.

@metyl

This comment has been minimized.

Copy link

metyl commented Apr 27, 2017

I had the same problem on Ubuntu 16.10 and have to change driver from autf to overlay2 in /etc/systemd/system/docker.service.d/10-machine.conf.

@azappella

This comment has been minimized.

Copy link

azappella commented Sep 20, 2017

@metyl thank you for posting this. I had a similar issue on a Linode machine running Ubuntu 16.04 (https://docs.docker.com/engine/userguide/storagedriver/selectadriver/)

@jar3b

This comment has been minimized.

Copy link

jar3b commented Oct 27, 2017

@metyl Thank you! Your solutions works nice on Debian Stretch after upgrading kernel 4.5->4.9.

@ghost

This comment has been minimized.

Copy link

ghost commented Dec 2, 2017

DO NOT TRY TO REMOVE /var/lib/docker !!! Otherwise you may probably make trouble! https://stackoverflow.com/questions/47604630/docker-service-start-error

@asoltesz

This comment has been minimized.

Copy link

asoltesz commented Mar 2, 2018

I had this problem after updating to a newer Linux kernel and switching to overlay2 seems to have solved the issue (KDE Neon, Ubuntu 16.04).

I used this resource: https://docs.docker.com/storage/storagedriver/overlayfs-driver/

@gbrayut

This comment has been minimized.

Copy link

gbrayut commented Jun 23, 2018

I got the same error initializing graphdriver: driver not supported message after trying to use docker-machine to connect to a docker instance in an lxd container. Looks like docker-machine creates a /etc/systemd/system/docker.service.d/10-machine.conf file with --storage-driver aufs. Neither aufs or overlay2 are suppored in lxd containers, so you have to change it to use --storage-driver vfs instead. Then systemctl daemon-reload && systemctl start docker should start the daemon again.

@maniankara

This comment has been minimized.

Copy link

maniankara commented Jul 17, 2018

thanks @asoltesz !

@darkn3rd

This comment has been minimized.

Copy link

darkn3rd commented Aug 10, 2018

Reproduces 100% with Gentoo:

vagrant init emerge generic/gentoo && vagrant up
vagrant ssh
sudo su -
emerge app-emulation/docker
/etc/init.d/docker start
cat /var/log/docker.log
@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Aug 10, 2018

@darkn3rd Gentoo provides their own packages for Docker, so it may be worth opening a ticket there. Having said that, if you report the issue, make sure to include relevant logs if possible; the issue that's reported in this ticket is not really a bug, but a configuration issue (e.g., a missing dependency on the system, or the underlying filesystem not supported for the selected storage driver).

@xueerfei

This comment has been minimized.

Copy link

xueerfei commented Oct 23, 2018

i got the same error, when i catch the log ,i find those : " Error starting daemon: Error initializing network controller: list bridge addresses failed: no available network"

run ifconfig it really didn't have docker0 device.
so use this can solve the problem:

sudo ip link add name docker0 type bridge
sudo ip addr add dev docker0 172.17.0.1/16

in fact, i find the virtual bridge docker0 will be create auto when install docker in some machine, but not in auto install in other ,may be it has relationship with OS kernel

@kvdv

This comment has been minimized.

Copy link

kvdv commented Nov 23, 2018

Same problem after updating Docker on Mac OS.
Solved by simply resetting Docker to factory settings.

@thaJeztah

This comment has been minimized.

Copy link
Member

thaJeztah commented Nov 23, 2018

@kvdv most likely, you were running with the aufs storage driver, which was deprecated in Docker for Mac 18.06, and has been removed in releases after that; see the release notes; https://docs.docker.com/docker-for-mac/release-notes/#docker-community-edition-18060-ce-mac70-2018-07-25

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment