如何在Debian上启用AUFS? [英] How to enable AUFS on Debian?
问题描述
当我尝试通过以下方式安装Docker时
When I try to install docker via:
curl -sSL https://get.docker.com/ | sh
我收到消息:
警告:linux-image-extra-virtual软件包不支持当前内核.我们没有AUFS支持.考虑安装软件包linux-image-virtual内核和linux-image-extra-virtual以获得AUFS支持.
Warning: current kernel is not supported by the linux-image-extra-virtual package. We have no AUFS support. Consider installing the packages linux-image-virtual kernel and linux-image-extra-virtual for AUFS support.
但是,Debian Jessie上似乎都不存在这两个软件包:
However, neither package seems to exist on Debian Jessie:
# apt-get install linux-image-virtual linux-image-extra-virtual
Reading package lists... Done
Building dependency tree
Reading state information... Done
E: Unable to locate package linux-image-virtual
E: Unable to locate package linux-image-extra-virtual
我在这里想念什么?
推荐答案
aufs,因此您应该从aufs跳到overlayfs.只需使用以下选项重启您的docker守护进程:
aufs is not supported by modern kernels, so you should skip to overlayfs from aufs. Just restart your docker daemon with the option:
--storage-driver=overlay2
(或将此选项添加到/etc/default/docker)
(or add this option to /etc/default/docker)
在某些系统中,应通过创建包含以下内容的/etc/systemd/system/docker.service来添加文件/etc/default/docker的处理以启动过程:
In some systems you should add the processing of the file /etc/default/docker to start procedure by creating /etc/systemd/system/docker.service with content:
[Service]
EnvironmentFile=-/etc/default/docker
ExecStart=
ExecStart=/usr/bin/docker daemon -H fd:// $OPTIONS \
$DOCKER_STORAGE_OPTIONS \
$DOCKER_NETWORK_OPTIONS \
$BLOCK_REGISTRY \
$INSECURE_REGISTRY \
$DOCKER_OPTS
更多信息此处
执行
systemctl daemon-reload
以使更改生效.
警告!!所有图片都无法访问.如果要保留它们,只需保存并重新加载它们.您可以在此处
Caution! All your images become unreachable. If you want to keep them, just save and reload them. You can find the good description here
UPD.我已将 overlay
更改为 overlay2
,因为它解决的问题比描述的
UPD. I've changed overlay
to overlay2
because it solves a little bit more problem than described here
UDP .不相关,因为 overlay2
在现代版本的docker(18-06)中默认使用.
UDP. Not relevant, since overlay2
used by default in modern version of docker (18-06).
这篇关于如何在Debian上启用AUFS?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!