Why upgrade Hyperledger Fabric from v1.4 to v2.x and where to start
A v1.4 network has to move forward because the chaincode toolchain and runtime assumptions of that line are aging out, and the newer lines will not run it as it is. The short answer is that v2.x is the step between v1.4 and the current lines, and v2.5 is the long-term support release for production users. Fabric's documentation describes the move as a set of ordered steps covering chaincode, peers, orderers and channel settings, not as a single binary swap, so the plan should be built around those steps from the start.
Before anything else, confirm the exact direct upgrade path and the target release in the Fabric v2.5 upgrade documentation. Do not assume a direct jump from v1.4 to a later line is supported, and do not plan around a version number you have not checked against that page. Record the current binary versions of every peer and orderer, the chaincode languages in use, and whether any channel still relies on the legacy lifecycle.
Start with an inventory that answers three questions: which chaincode is written in Go or Node.js, which channels exist and how they were defined, and which ordering service each channel depends on. Go chaincode on v1.4 usually depends on a shim that v2.x no longer vendors automatically, so the Go shim question is the first engineering decision. Node.js chaincode built on v1.4 libraries will need a move to a v2.x library. Each of these changes affects the build pipeline, not only the running nodes.
Assign owners for each organization's peers, orderers and chaincode, and agree on a rollback point before any node changes. Your own team can run the inventory and the backups, while a partner may be useful for the chaincode rebuild and for testing the upgraded network. Ask any partner for the written scope, the list of channels and chaincode covered, and the test evidence they will return.
What changes between v1.4 and v2.x, and what each change breaks
This table compares each change in the v1.4 to v2.x move with the breakage it can cause and the action to take before peers are upgraded. Read it as a pre-upgrade checklist: work through the chaincode rows first, because they gate the peer binary upgrade. The exact API differences must be confirmed against the v2.x release notes and your own chaincode code.
| Change | Impact | Action needed |
|---|---|---|
| Go chaincode shim no longer vendored by ccenv | v2.x ccenv image does not vendor the Go chaincode shim automatically, so v1.4 Go chaincode may fail to build or run after peers move to v2.x | Vendor the Go chaincode shim in each v1.4 chaincode package before upgrading peers, then rebuild and test |
| Node.js chaincode libraries unsupported | v1.4 Node.js chaincode libraries are no longer supported and receive no updates, so security and compatibility fixes stop | Migrate each Node.js chaincode to a v2.x Node.js chaincode library and retest transaction behavior |
| Removed shim logger | Chaincode that calls the v1.4 shim logger may not compile or log as expected under the newer shim | Find every logger call in your chaincode, replace it with the supported logging approach, and confirm the API against the v2.x release notes |
| Init handling | Init function behavior in v1.4 chaincode may differ under v2.x, which can change ledger state at instantiation or upgrade | Review each Init function, confirm how v2.x invokes it, and test instantiation and upgrade paths on a non-production channel |
| Chaincode handling moves to v2.x lifecycle | v1.x chaincode lifecycle commands are not used for v2.x channels, and Fabric 3.0 removes the legacy lifecycle entirely | Move every channel to the v2.x lifecycle and approve chaincode definitions with the v2.x process before upgrading binaries |
How Go and Node.js chaincode each need to change before peers upgrade
The v2.x ccenv image no longer vendors the Go chaincode shim automatically. Chaincode built on v1.4 that relies on that implicit shim will fail to build or run once the peer moves to v2.x, so the shim has to live inside the chaincode package before any peer is upgraded. Fabric's upgrade guidance is to vendor the shim in v1.4 Go chaincode first, then rebuild the package and test it against the v2.x ccenv image in a non-production environment.
- Vendor the shim in the module: Confirm the chaincode directory contains the shim dependency under
vendor/and that the build uses it, not a copy pulled at build time. - Rebuild against the v2.x ccenv image: Build the package with the same image your v2.x peers will use, and record the image tag and the resulting package ID.
- Confirm the shim logger call sites: Search for uses of the removed shim logger and replace them with standard logging. Compile errors show some sites, but not all runtime paths are exercised by compilation.
- Review every Init call site: Check how
Initis invoked and what it writes, and confirm the behavior your application expects after the lifecycle change. - Run endorsement and query tests: Exercise each transaction function against a test channel on the target versions.
Verify in your own code that every import resolves to the vendored shim and that no transaction path depends on the removed logger or on implicit Init behavior.
The v1.4 Node.js chaincode libraries are not supported and receive no updates. Fabric advises moving to a v2.x Node.js chaincode library, which changes the package dependencies, the runtime expectations and the way the chaincode is packaged. Because the v1.4 libraries will not be patched, staying on them after the peer upgrade leaves the chaincode running on unmaintained code.
- Replace the v1.4 library: Move the dependency in
package.jsonto a v2.x Node.js chaincode library and update the entry point to match its API. - Check the Node.js runtime version: Confirm the runtime version your v2.x build and peer image expect, and pin it so builds are reproducible.
- Audit transitive dependencies: Lock dependency versions, review the lock file and remove packages that no longer receive maintenance.
- Retest endorsement and state logic: Confirm that read-write sets, key ranges, composite keys and error paths return the same results as before the migration.
- Repackage and retest the package: Build the new package, install it on test peers and rerun the transaction test suite.
Verify in your own code that endorsement policies, state key formats and error handling produce identical ledger writes before and after the migration.
Chaincode changes come before peer binaries because a peer upgrade changes the environment that chaincode runs in, and the team needs the new packages ready when that environment changes. Fabric's upgrade path moves the lifecycle and the build environment, so v1.4 chaincode that depends on behavior the v2.x peers no longer provide must already be replaced. Doing the chaincode work first means each peer upgrade can be tested against packages that are already known to work.
- Packages exist before the peers change: New chaincode packages are built and tested while the network still runs the old binaries.
- Failures surface early: Build and test failures are found in a test network rather than during a rolling peer upgrade.
- Rollback stays simple: If a package fails, the peer binaries have not moved, so the network remains on known-good components.
- Coordination with member organizations: Each organization that runs chaincode must confirm its packages before the network-wide sequence begins.
- Lifecycle migration follows: Moving channels to the v2.x lifecycle depends on the chaincode packages being ready.
Confirm with each organization that its chaincode owners have signed off on the rebuilt packages before anyone schedules a peer upgrade window.
What to back up and inventory before the first node is touched
Nothing in a v1.4 to v2.x move should start until the team knows what it is changing and how to recover it. The five items below connect backups, chaincode inventory, lifecycle state, configuration records and a rehearsal environment, and each has an owner that often sits in a different member organization.
Ledger and MSP backup
Back up each peer and orderer ledger and every MSP directory before any binary changes. The Fabric upgrade guide names this as the first step, and it is the only route back if a node fails mid-upgrade. Confirm with the platform team where each organization stores its backups, how long they are kept, and whether a restore has ever been tested on a copy. Each member organization usually owns its own peers and MSP material, so each one should sign off on its own backup.
Fabric upgrade guideChaincode package inventory
List every chaincode package deployed to the network, with its language, version, sequence number and whether its Go dependencies are vendored. Packages built against the v1.4 shim may not compile or run the same way once peers run the v2.x ccenv image, which no longer vendors the Go shim automatically. Each chaincode owner should confirm the build inputs for their package, since application teams often hold the source and the network operators hold only the installed package.
Legacy lifecycle channel list
Record which channels still rely on the legacy chaincode lifecycle and which already use the v2.x lifecycle. Channels still on the legacy lifecycle need to move before the network can reach the 3.x line, since Fabric v3.0 removed the v1.x lifecycle. Ask the channel administrators to confirm membership, the approval state of each chaincode definition, and any channel whose members have not agreed to the change.
Peer and orderer configuration and TLS records
Keep a dated copy of every peer and orderer YAML file, environment override, Docker or systemd definition, and the TLS certificates and keys they reference. Some v1.4 settings have changed names or defaults in v2.x, so the team needs the exact starting state to port them and to roll back. Confirm who holds the TLS material for each node and where it is stored, because a missing or mismatched key can block a rolling restart.
Test network that mirrors production
Build a test network with the same organizations, channel layout, consenter count, database backend and chaincode packages as production, then run the full upgrade there first. An illustrative test may use fewer peers, but it should keep the ordering type, TLS settings and every chaincode package that will be carried forward. Agree with each member organization who will run the test, which results count as a pass, and which findings block the production change.
How the v1.4 to v2.x upgrade runs, step by step, with rollback points
The sequence moves a v1.4 network to v2.x in an order that keeps the channel running, with a verified backup and a check at every stage so each change can be reversed until the capability step. Most of the work sits in chaincode and lifecycle preparation before any binary changes.
Back up the ledger and MSPs
Before any change, the network operator takes a backup of each peer and orderer ledger and of every MSP directory and TLS material, on every organization. The team restores one backup into a scratch environment and confirms the peer starts and reports the expected block height. This is the first rollback point: if the restore test fails, nothing in the network has changed and the upgrade stops here. Confirm the exact backup procedure for your version in the Fabric upgrade documentation before you start.
Vendor the Go chaincode shim
Each team that owns v1.4 Go chaincode vendors the chaincode shim into its module so the chaincode builds without relying on the shim that the v2.x ccenv image used to supply automatically. The team rebuilds the chaincode package and runs its unit and integration tests against a v1.4 test network. The check is a clean build and passing tests with the vendored shim. Rollback is simple at this stage because the change lives in source code and can be reverted in version control.
Migrate Node.js chaincode libraries
Teams running v1.4 Node.js chaincode move to a supported v2.x Node.js chaincode library, since the v1.4 libraries are no longer supported and receive no updates. The team updates the package manifest, adjusts any calls that changed, and tests the chaincode on a non-production channel. The check is that transaction invocations and queries return the same results as before on the test network. Rollback remains a source-level revert, so keep the v1.4 package available until production is verified.
Move channels to the v2.x lifecycle
Each channel's chaincode is redefined through the v2.x lifecycle, which replaces the v1.x approach, with approvals from the required organizations. The operator checks that the chaincode definition commits on each channel and that every organization reports the same committed definition. Confirm with the docs which v1.x lifecycle artifacts must be retired before the binary upgrades, because the lifecycle change is the last step that can be reverted by reverting chaincode definitions. Record the committed definitions as evidence for the change.
Upgrade orderer binaries one node at a time
The operator upgrades one orderer node at a time to the target v2.x binaries, restarts it, and waits until it rejoins the cluster and catches up to the current block height before moving to the next. The check per node is a successful restart, a healthy status from the operations endpoint, and matching block height with the other orderers. A node that fails can be rolled back to the previous binary because the capability level has not changed. Keep quorum in mind: a five node Raft cluster tolerates the loss of two nodes, so never take more than one node out at once.
Upgrade peer binaries one at a time
Once every orderer is on the new binaries, each organization upgrades its peers one at a time, following the same restart and catch-up check as the orderers. The operator confirms each peer reports the new version, joins its channels, and commits new blocks alongside the other peers. Peer binaries can still be reverted to the prior version at this point, provided the channel capability levels have not been changed. Track which peers are upgraded in your change record so a partial rollback is possible.
Update application channel capability levels
After every orderer and peer runs the new binaries, the channel's application capability levels are updated through a channel configuration update, approved by the organizations that the channel policy requires. The check is that the channel config block shows the new capability and that all peers keep committing blocks. This is the point of no return for simple rollback: once capabilities are enabled, reverting binaries alone is no longer a straightforward option. Confirm this behavior and the capability names in the Fabric upgrade documentation before you schedule this step.
How the phases and decision gates fit together
The upgrade starts with inventory and backup, then moves through chaincode preparation and lifecycle migration before any binary changes. A test network rehearsal sits between preparation and production, so problems surface before orderers and peers are touched. Each gate either advances to the next phase or routes back to the rollback point of the last completed phase, so the team always knows which state to restore.
Phases run left to right, with a rollback point behind each failed gate.
What makes a Fabric v1.4 upgrade take longer
This table lists the factors that lengthen a v1.4 to v2.x move and explains why each one adds work. Use the third column as a checklist when you request a quote, so the written scope reflects your actual estate. The main takeaway is that chaincode inventory, channel lifecycle state and rehearsal count usually matter more than the binary swap itself.
| Driver | Why it adds effort | What to ask for in a quote |
|---|---|---|
| Number and language mix of chaincode packages | Each Go chaincode package may need its shim vendored before peers move to v2.x, and each Node.js package needs its own review. Mixed languages mean mixed build and test paths. | A chaincode inventory listing each package, language, version and owning channel, with the work scoped per package. |
| Node.js code on unsupported libraries | The v1.4 Node.js chaincode libraries receive no updates, so code must move to a v2.x Node.js library and be retested against the new runtime. | Confirm which packages will be ported, which will be rewritten, and how behavior is compared before and after. |
| Channels still on the legacy lifecycle | Fabric v3.0 requires all channels on the v2.x lifecycle, so each channel needs its chaincode definitions reviewed and migrated in a planned order. | The list of channels to migrate, the chaincode definitions on each, and the approval steps each organization must complete. |
| Organizations that must coordinate | Every member organization must approve channel configuration changes and binary upgrades on its own peers and orderers, so one slow approver slows the whole network. | Who signs off at each stage, the coordination calendar, and how the client handles a member that cannot upgrade on time. |
| Ledger size | Backups, restore tests and rehearsal runs take longer as ledgers grow, and the upgrade guide begins with a backup of the ledger and MSPs. | Current ledger sizes per peer and orderer, the backup method, and a restore test included in the plan. |
| Custom images, HSM and PKI setups | Peers and orderers using PKCS#11 need custom images, since the prebuilt Docker images are not built with PKCS#11. HSM and CA changes add steps to every rolling restart. | Whether custom images must be rebuilt and retested, how HSM access is verified on each node, and which CA steps are in scope. |
| Environments that need a rehearsal | Each environment that differs from production, such as development, test, staging and disaster recovery, needs its own upgrade run before production. Gaps between them cause surprises. | The list of environments, the rehearsal steps for each, and the criteria that must pass before production is scheduled. |
What buyers ask before hiring help with a Fabric v1.4 upgrade
What drives the cost of a Fabric v1.4 upgrade and what should a written quote include?
The main cost driver is the amount of work the network needs before any binary changes: how many chaincodes use the Go or Node.js shims, how many channels and organizations exist, how many peers and orderers run in each organization, and how much of the current state is undocumented. Cost is mostly people time, split between discovery, code changes to chaincode, staging rehearsals, production change windows and handover. Some costs are one-time, such as the upgrade itself, while ongoing support or retainers recur only if you buy them. A written quote should list the systems in scope, the chaincode and channels covered, the environments used for rehearsal, the deliverables, the assumptions about your access and the change windows, and what is excluded. DeployOpen agrees scope and deliverables in writing before work starts, and the quote follows from that scope.
How long does a Fabric v1.4 upgrade take?
No duration is fixed for this work, so treat any single number as a claim to challenge. The timeline is set by the number of channels, the number of chaincodes that need vendored shims or Node.js library migration, the state of your backups, how many member organizations must approve each step, and how many staging rehearsals your change process requires. Rolling upgrades also run one node at a time, so the count of peers and orderers sets the length of each window. Ask the provider to show the planned sequence, the gating checks between phases and the approvals each organization must give, and confirm that the schedule accounts for rehearsal in a non-production copy of the network.
What must our team provide before an upgrade engagement starts?
Expect to supply the following before work begins:
- Source code for all chaincode, including any vendored dependencies and the Node.js package manifests
- A channel inventory listing each channel, its members, its chaincode definitions and its private data collections
- Access to peers, orderers, Fabric CA and their configuration files, with the ability to take backups
- Current backups of the ledger and MSP material, plus a tested restore path
- A named decision maker from each member organization who can approve changes and schedule change windows
Missing items usually show up as delays during discovery, so ask for this list in writing during scoping.
Can our team upgrade a v1.4 network alone, and when does a partner help?
Your team can do it alone if it has engineers who know the chaincode, the channel configuration and the operations of every node, and if it can rehearse the full sequence outside production. A partner usually helps where the gaps are: legacy chaincode that nobody maintains, unclear channel membership, Node.js chaincode that needs a new library, or a multi-organization change where coordination is the hard part. Many teams split the work, keeping chaincode ownership in-house and bringing in an outside team for planning, rehearsal and cutover. DeployOpen plans, implements, documents and supports self-hosted Fabric networks inside the client's own infrastructure, so the choice is about where the skills gap sits.
Can a v1.4 network go straight to v2.x, and what should we confirm in the docs?
Confirm the exact path in the official documentation for your target release before you plan, because the upgrade guidance is version specific. The Fabric v2.5 upgrade documentation recommends vendoring the Go chaincode shim in v1.4 chaincode before upgrading peers, because the v2.x ccenv image no longer vendors it automatically. It also states that v1.4 Node.js chaincode libraries are not supported and receive no updates, so Node.js chaincode should move to a v2.x library. Check the documentation for the release you plan to run, the order of binary upgrades, and any change to the chaincode lifecycle that affects existing definitions. Then rehearse the path on a copy of your network before you touch production.
How does rollback work if a node fails during the upgrade?
Rollback depends on taking a verified backup before the first change and on upgrading one node at a time. The Fabric upgrade guide starts with backing up the ledger and MSPs, then upgrades orderers in a rolling fashion and peers in a rolling fashion. Because each node is replaced in turn, a failed node can be stopped and returned to its previous binary while the rest of the network keeps running, provided enough ordering nodes remain available. A Raft cluster of five nodes tolerates the loss of two nodes, which sets the margin you have during a window. Ask the provider to document the rollback steps for each node type, the restore test used on the backup, and the criteria that stop the rollout, and confirm those steps in your staging network first.
Do we need to enable new channel capabilities as part of the upgrade?
Binary upgrades and capability changes are separate steps. The Fabric upgrade guide places capability level updates after every orderer and peer binary has been upgraded. Capabilities change channel behavior and generally cannot be undone once enabled, so they should be scheduled as their own decision with every member organization informed. Confirm the capability levels your target release supports in its documentation, and decide with your member organizations when to turn them on.
How DeployOpen scopes, delivers and supports a Fabric upgrade
DeployOpen plans, implements, hardens, documents and supports self-hosted open-source platforms inside the client's own infrastructure. For a v1.4 to v2.x Fabric upgrade, the work starts with a written scope that inventories chaincode, shim usage, peer and orderer versions and the lifecycle state of every channel before any binary changes.
How we scope
- Inventory every v1.4 chaincode package and record whether it is Go, Node.js or another language, and which shim version it imports.
- Confirm which channels still use the legacy lifecycle and agree the move to the v2.x lifecycle as a written deliverable.
- Agree in writing which peers, orderers, CAs and client applications are in scope, and who on the client side approves each change window.
How we build
- Vendor the Go chaincode shim in v1.4 code and test each chaincode package against a staging network before any peer is upgraded.
- Migrate Node.js chaincode off unsupported v1.4 libraries onto a v2.x library and run transaction regression tests against the ledger copy.
- Rehearse the backup, rolling upgrade order and rollback steps in a non-production copy of the network before the production window.
How we hand over
- Deliver a runbook with the exact upgrade sequence, backup evidence, chaincode inventory and the results of each regression test.
- Document the changed Init handling, the removed shim logger and the new lifecycle approval steps so the client team can repeat them.
- Walk through the handover with the operations team and record open items, including any capability changes the client still needs to decide.
How we support
- Engagements are fixed-scope, with deliverables and timelines agreed in writing before work starts.
- Ongoing support, upgrades and continuous testing are available as a retainer, which covers later patch releases on the chosen Fabric line.
- Ask any partner for the written scope, the named deliverables and the acceptance tests before signing, and confirm what the retainer excludes.

