我正在浏览一篇文章weave net driver并正在尝试我的双手。我能够使用默认的 weavemesh 驱动程序在单个主机上进行容器到容器的通信。当我尝试使用 weave
网络驱动程序插件创建多个网络时,问题就出现了。我收到以下错误。
[ankit@local-machine]$ docker network create -d weave netA
Error response from daemon: failed to parse pool request for address space "GlobalDefault" pool "" subpool "": cannot find address space GlobalDefault (most likely the backing datastore is not configured)
现在,据我从 docker 文档 Getting Started with Docker Multi-host Networking 中了解到,它需要配置一个键值存储。我想知道我的理解是否正确?有没有办法通过weave网络创建多个网络来实现网络隔离。我希望能够将一个容器的网络流量与同一机器上运行的另一个容器隔离。
有一个新的 weave 1.4 插件
docker networking without cluster store plugin最近的公告称,它支持 docker 网络,无需外部集群存储。它到底是如何工作的?目前还不清楚它是否可以用于通过 weave
创建多个网络。
最佳答案
Did you start the docker daemon with --cluster-store?
You need to pass peers ips to weave launch-router
$peers
when starting docker with--cluster-store
and--cluster-advertise
.
文档提到:
The Weave plugin actually provides two network drivers to Docker
- one named
weavemesh
that can operate without a cluster store and- one named
weave
that can only work with one (like Docker’s overlay driver).
因此需要Set up a key-value store首先。
如果您使用的是weave
插件,那么您的理解是正确的。
PR 1738详细介绍了新的 weave 1.4+ 无需 keystore 即可通过 weavemesh
驱动程序进行操作的功能。 Its doc does mention :
If you do create additional networks using the
weavemesh
driver, containers attached to them will be able to communicate with containers attached to weave; there is no isolation between those networks.
但是PR 1742仍然打开“允许用户为每个 docker 主机指定子网范围”。
关于networking - 使用docker的weave网络驱动插件配置多个网络时出错,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35008937/