当我运行命令./byfn.sh -m generate
时,一切都很好。
我正在尝试使用命令
打开网络./byfn.sh -m up
但是我收到了一个错误:
2018-03-28 08:47:19.896 UTC [main] main -> INFO 001 Exiting.....
LOCAL_VERSION=1.1.0
DOCKER_IMAGE_VERSION=1.1.0
orderer.example.com is up-to-date
Creating peer1.org2.example.com ...
Creating peer0.org2.example.com ...
Creating peer1.org1.example.com ... error
Creating peer0.org1.example.com ...
Creating peer1.org2.example.com ... error
ERROR: for peer1.org1.example.com Cannot create container for service peer1.org 1.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer1.org2.example.com Cannot create container for service peer1.org 2.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ Creating peer0.org1.example.com ... error
Creating peer0.org2.example.com ... error
1.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer0.org2.example.com Cannot create container for service peer0.org 2.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer1.org1.example.com Cannot create container for service peer1.org 1.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer1.org2.example.com Cannot create container for service peer1.org 2.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer0.org1.example.com Cannot create container for service peer0.org 1.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
ERROR: for peer0.org2.example.com Cannot create container for service peer0.org 2.example.com: b'Mount denied:\nThe source path "\\\\var\\\\run:/host/var/run/"\ nis not a valid Windows path'
Encountered errors while bringing up the project.
ERROR !!!! Unable to start network
我试图解决它,我认为docker有问题。特别是在我更新之后。
$ docker --version
Docker version 18.03.0-ce, build 0520e24
$ docker-compose --version
docker-compose version 1.20.1, build 5d8c71b2
答案 0 :(得分:9)
我遇到了同样的问题。 如果您在Windows上遇到此问题,请尝试此操作。 在 fabric-samples / first-network / 中打开 .env 文件 并添加此 的 COMPOSE_CONVERT_WINDOWS_PATHS = 1 强>
答案 1 :(得分:1)
通过以下步骤对我有用:
$ cd [to your working folder of Fabric]
$ curl -sSL https://raw.githubusercontent.com/hyperledger/fabric/master/scripts/bootstrap.sh | bash -s 1.1.0
$ cd fabric-examples/
$ export FABRIC_CFG_PATH=$PWD
$ cd first-network
$ vi .env
--and add COMPOSE_CONVERT_WINDOWS_PATHS=1
$ ./byfn.sh -m generate
$ ./byfn.sh -m up
特别感谢권하경