Multi-Organization Fabric Network
This tutorial walks through deploying a Fabric network with multiple organizations — the most common enterprise scenario.
What You'll Build
A 3-organization network with:
- Org1MSP — 2 peers, ordering service
- Org2MSP — 1 peer
- Org3MSP — 1 peer
- A shared channel (
supply-chain) with all 3 orgs - Chaincode deployed and approved by all orgs
Prerequisites
- ChainLaunch running at
http://localhost:8100 - Docker running with at least 8 GB RAM available
Step 1: Create the Network with CLI
The fastest way to create a multi-org network:
chainlaunch testnet fabric \
--name supply-chain \
--org "Org1MSP,Org2MSP,Org3MSP" \
--peerOrgs "Org1MSP,Org2MSP,Org3MSP" \
--ordererOrgs "Org1MSP" \
--channels supply-chain \
--peerCounts "Org1MSP=2,Org2MSP=1,Org3MSP=1" \
--ordererCounts "Org1MSP=3"
This creates everything in one command: organizations, nodes, channel, and joins all peers to the channel.
Step 2: Create Step-by-Step via UI
If you prefer the UI, follow these steps:
2.1 Create Organizations
Go to Organizations and create each one:
- Click Add Organization
- Set MSP ID:
Org1MSP, Description:Manufacturing - Repeat for
Org2MSP(Logistics) andOrg3MSP(Retail)
2.2 Create Nodes
Go to Nodes > Bulk Create for each org:
| Organization | Peers | Orderers |
|---|---|---|
| Org1MSP | 2 | 3 |
| Org2MSP | 1 | 0 |
| Org3MSP | 1 | 0 |
2.3 Create the Channel
Go to Networks > Create Network > Fabric:
- Name:
supply-chain - Add Peer Organizations: Org1MSP, Org2MSP, Org3MSP
- Select peers for each org
- Add Orderer Organization: Org1MSP
- Select all 3 orderers
- Consensus:
etcdraft - Click Create
2.4 Verify
Check that all peers have joined the channel:
curl http://localhost:8100/api/v1/networks | jq '.[].name'
Step 3: Deploy Shared Chaincode
All organizations must approve the chaincode before it's committed to the channel.
Via CLI
The chainlaunch fabric install command runs the full Fabric chaincode lifecycle (install on peers → approve for each org → commit when threshold is met) in one shot. Pass one network-config file per organization (or one file for all) and one user per organization:
chainlaunch fabric install \
--chaincode mycc \
--channel supply-chain \
--policy "OR('Org1MSP.member','Org2MSP.member','Org3MSP.member')" \
--config ./network-config-org1.yaml \
--config ./network-config-org2.yaml \
--config ./network-config-org3.yaml \
--organizations Org1MSP \
--organizations Org2MSP \
--organizations Org3MSP \
--users admin \
--users admin \
--users admin \
--chaincodeAddress localhost:9999
The command also handles re-installs and version bumps — it queries the committed definition and increments the sequence automatically when the chaincode bytes or policy change.
Via API or Web UI
See Deploy Chaincode for the API flow and the web UI Chaincode wizard, both of which expose the same install→approve→commit lifecycle as discrete steps.
Step 4: Test Cross-Org Transactions
Once chaincode is committed, any org can submit transactions and all peers will validate:
# Org1 invokes
curl -X POST http://localhost:8100/api/v1/networks/{networkId}/chaincode/invoke \
-H "Content-Type: application/json" \
-d '{
"chaincodeName": "mycc",
"channelName": "supply-chain",
"function": "CreateAsset",
"args": ["asset1", "Manufacturing plant A", "100"],
"organizationId": "Org1MSP"
}'
Endorsement Policies
By default, Fabric requires a majority of organizations to endorse a transaction. Common policies:
| Policy | Meaning | Use case |
|---|---|---|
MAJORITY | >50% of orgs must endorse | Default, good for most cases |
AND('Org1MSP.peer', 'Org2MSP.peer') | Specific orgs required | When both parties must agree |
OR('Org1MSP.peer', 'Org2MSP.peer') | Any org can endorse | Low-trust requirements |
OutOf(2, 'Org1MSP.peer', 'Org2MSP.peer', 'Org3MSP.peer') | N-of-M orgs | Flexible quorum |
Set the policy during chaincode approval.
Adding a New Organization Later
To add a 4th organization to an existing network:
- Create the organization
- Create peer nodes for the new org
- Update the channel to include the new org
- Have the new org's peers join the channel
- Install and approve chaincode for the new org
Next Steps
- Update Channel to modify the org set or policies
- Deploy Chaincode for chaincode lifecycle details
- Analytics to monitor cross-org transaction flows