Knowee
Questions
Features
Study Tools

While creating a channel in Hyperledger fabric, which of the following Docker commands will you use for updating the anchor peer for the Org2 organization?

Question

While creating a channel in Hyperledger fabric, which of the following Docker commands will you use for updating the anchor peer for the Org2 organization?

🧐 Not the exact question you are looking for?Go ask a question

Solution

To update the anchor peer for the Org2 organization while creating a channel in Hyperledger Fabric, you would use the following Docker command:

docker exec -e "CORE_PEER_LOCALMSPID=Org2MSP" -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/[email protected]/msp" peer0.org2.example.com peer channel update -o orderer.example.com:7050 -c $CHANNEL_NAME -f ./channel-artifacts/Org2MSPanchors.tx

Here's a step-by-step breakdown of the command:

  1. docker exec: This command is used to run a new command in a running container.

  2. -e "CORE_PEER_LOCALMSPID=Org2MSP": This sets the environment variable CORE_PEER_LOCALMSPID to Org2MSP. This is used to specify the MSP ID of the peer's organization.

  3. -e "CORE_PEER_MSPCONFIGPATH=/etc/hyperledger/msp/users/[email protected]/msp": This sets the environment variable CORE_PEER_MSPCONFIGPATH to the path of the MSP configuration for the admin user of Org2.

  4. peer0.org2.example.com: This is the name of the Docker container for the peer.

  5. peer channel update: This is the command to update the channel.

  6. -o orderer.example.com:7050: This specifies the orderer endpoint.

  7. -c $CHANNEL_NAME: This specifies the name of the channel.

  8. -f ./channel-artifacts/Org2MSPanchors.tx: This specifies the file that contains the configuration update for setting the anchor peer for Org2.

This problem has been solved

Similar Questions

In Hyperledger Fabric, which of the following files contain/define the policies governed by the orderer?configtx.yamlconfigsys.jscore.yamlchaincode.js

Which fabric segment does a fabric edge belong to?noneoverlay networkunderlay and overlay network segmentunderlay network

What is the default name of a Fabric file?FabricfileFabric.pyfabfile.pyDockerfile

Which command is used to create a new Docker image?(1 Point)docker builddocker pulldocker rundocker commit

Question 4What underlying architecture do containers leverage?1 pointA hypervisorGuest operating systemsThe host kernelA cloud control plane

1/1

Upgrade your grade with Knowee

Get personalized homework help. Review tough concepts in more detail, or go deeper into your topic by exploring other relevant questions.