如何在没有setns错误的情况下与docker共享网络接口?

时间:2015-04-23 14:11:26

标签: docker

我想在同一个界面上启动2个docker容器,所以我尝试了docker docs中的以下内容:

First container:
bash-4.1$ docker run -ti --name=target ubuntu /bin/bash
root@45edefd42404:/# 

Second container:
bash-4.1$  docker run -ti --rm --net=container:target ubuntu /bin/bash
setup networking failed to setns current network namespace: invalid argumentFATA[0002] Error response from daemon: Cannot start container ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461: setup networking failed to setns current network namespace: invalid argument 

我已经搜索了与setns相关的失败,但无法找到相关内容。有没有其他地方我可以调试这个?

我的docker守护程序日志包含与失败相关的内容(完整日志https://gist.github.com/paulweb515/990a1a9edeef1e73b752);

time="2015-04-23T09:17:59-04:00" level="error" msg="Warning: error unmounting device ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461: UnmountDevice: device not-mounted id ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461\n"
time="2015-04-23T09:17:59-04:00" level="info" msg="+job log(die, ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461, ubuntu:14.04)"
time="2015-04-23T09:17:59-04:00" level="info" msg="-job log(die, ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461, ubuntu:14.04) = OK (0)"
Cannot start container ba28e4f14f4b3c2d7b94aa4b0cca8f5b70e6b354842818fe77b31885acc77461: setup networking failed to setns current network namespace: invalid argument

0 个答案:

没有答案