fabric-samples
fabric-samples copied to clipboard
test-network channel creation error
ERROR
Run ./network.sh up createChannel
, then "peer" and "order" were found exited right now, which are supposed to be up all the time.
So "Error: Post "https://localhost:7053/participation/v1/channels": dial tcp 127.0.0.1:7053: connect: connection refused" appeared, and channel creation failed.
Env is followed:
ENV
-
remote server with ubuntu 18.04
-
docker engine version: 24.0.2
-
docker-compose version: 1.29.2
-
fabric image/binary version: 2.5.0
-
fabric-ca image/binary version: 1.5.6
-
fabric-samples repo version: main
-
compose file version: 3.7
Question
Surprisingly, test-network sample goes well in my local desktop with ubuntu 22.04 while the other configs of env are the same as those listed above! So how can I figure the error out in server with ubuntu 18.04?
Hope to see your reply soon! Thx!
Having exact same issue on Mac OS with Apple chip. I had been working without problems, I think it started failing after last macos upgrade but not sure. Tried several things, removing, reinstalling. Wasn't able to downgrade docker tho.
Error: Post "https://localhost:7053/participation/v1/channels": dial tcp [::1]:7053: connect: connection refused
I'm on Mac os Ventura 13.4 (22F66)
I was able to figure out my problem, new version of docker uses "docker compose", instead of "docker-compose". I manually edited network.sh on line 259 to remove the hyphen, and started working.
Online 32
from
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
to
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
I was able to figure out my problem, new version of docker uses "docker compose", instead of "docker-compose". I manually edited network.sh on line 259 to remove the hyphen, and started working.
Online 32 from
: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI}-compose"}
to: ${CONTAINER_CLI_COMPOSE:="${CONTAINER_CLI} compose"}
Thx a lot, I'll try it. BTW, I found that the error can be solved when I run test-network with root.
-
Verify Docker Containers:
docker ps -a
-
Check Docker Compose File: The Docker Compose file defines the services, networks, and volumes for your application. You'll need to locate the relevant file, such as
network.sh
, and review its contents to ensure the configurations are correct. -
Check Port Availability:
netstat -tuln | grep 7053
-
Firewall and Networking: Check the firewall status on your remote server and ensure the necessary ports are open. The commands can vary depending on your server's configuration. Here's an example using
ufw
:sudo ufw status sudo ufw allow 7053
-
Logs and Debugging:
docker logs <container_name>
-
Network Connectivity: Ensure that your remote server has a working network connection. You can test connectivity to external resources by using tools like
ping
orcurl
. For example:ping google.com curl https://www.example.com
-
Compare Local and Remote Configurations: Compare the configurations between your local machine and the remote server by reviewing the Docker versions, fabric versions, and any other relevant settings. You may need to access configuration files or use Docker commands to inspect specific details.