当我运行命令./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
我遇到了同样的问题。如果您在Windows上遇到此问题,请尝试此操作。在fabric-samples / first-network /中打开.env文件并添加此COMPOSE_CONVERT_WINDOWS_PATHS = 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
特别感谢권하경