Why is my validator stuck?
Your validator is stuck if it was running a Splice version before 0.8.3 (Canton 3.5.18) when the LSU was announced. Those Canton versions didn’t recognize the LSU announcement and kept processing timestamps from the old synchronizer. This moved the node’s internal clocks past the clocks of the successor synchronizer. When the participant then tries to move over to the new synchronizer, it finds that the clock ticks overlap. Since this shouldn’t happen, it stops processing.Choose your path
- You have a database backup from before the freeze and from the last 30 days. Restore it, upgrade to the Splice version the network runs now, and let the node replay the events. Follow Restoring a validator from backups. This is the simplest and safest option. Use the rest of this page only if you don’t have such a backup.
- Your parties hold only Canton Coin (CC) and CNS entries (no other Daml applications or tokens, no wallet contracts such as transfer offers or minting delegations, no external parties, no multi-hosted parties). Run the pre-flight check to confirm it. Then run steps 1 to 3, 7, 8 and 15 to 17, and leave the validator app running after step 8 (skip the warning box in that step). About an hour after step 8, check the node as at the end of step 14. Other users of your wallet then onboard again. They keep their CC and CNS entries.
- Otherwise, follow the full procedure below.
What the procedure does
The procedure creates a new validator node that takes over the namespace keys and parties of the stuck node and connects to the successor synchronizer. The validator app moves your internal parties (the parties of your namespace that aren’t external) to the new node and imports their contracts that are shared with the DSO party (CC among them) from Scan. All other contracts come from exports that you take from the stuck node. External parties move in step 11, once their owners sign the new hosting, and multi-hosted parties of other namespaces in phase G. From step 8 on, the stuck node stays stopped. You only start it again, still disconnected, to export something you missed.What applies to you
Some instructions depend on your setup and are shown in tabs: Docker Compose or Helm, and Local keys or KMS (participant keys in an AWS or GCP KMS configured in Canton). Choose your setup in one of these tabs, and the other tabs on this page switch to it too.Limitations
Loss of update history
The new node is provisioned only with the active contracts of your parties, through ACS imports. The Ledger API update history up to the point where a party is onboarded on the new validator is lost, in particular:- archived contracts and non-consuming events
- creates where a party hosted on the node is an observer
- contracts where a party was only a non-stakeholder informee (that is, they were disclosed to the party)
- command completions
Ledger API client applications need to rebuild their state
The new node has a different Ledger API update lineage, most importantly with changed offsets. Additionally, Ledger API update and command completion history isn’t preserved. Client applications (wallet backends, PQS, custom indexers, etc.) MUST therefore rebuild their internal data storage from the new validator from scratch.New participant ID
The new node gets a new participant ID. Party IDs don’t change. Traffic belongs to the participant ID (PAR::...), not to a party. Traffic bought for the old participant ID stays with that ID, so the new participant needs its own, and anyone who buys traffic for your node (a traffic provider, your own scripts) must use the new ID from now on. Until it has some, every message it sends is throttled to the base rate. Step 8 explains how to buy it.
Contracts that changed after the LSU without your node
The exports of steps 4 and 5 contain your contracts as the stuck node saw them at the LSU upgrade time. Contracts your parties only observe may have been archived since then without your node, and importing them brings them back as active. Contracts created since then where your parties are only observers are missing from the exports. Both usually cause ACS commitment mismatches in step 13. Step 13 can’t detect them if they’re the only contracts your node shares with the other participant: then only one of the two participants sends a commitment, and the other one ignores it without logging anything. Steps 8, 10 and 11 avoid this for contracts shared with the DSO party by importing those from Scan. The same issue can happen between your own parties if an internal party changes a contract shared with an external party between steps 10 and 11. Then the import of step 11 stops withCannot add previously archived contract (see the error reference).
Multi-hosted parties
A multi-hosted party is hosted on more than one participant. This page covers a multi-hosted party only if it has exactly two hosts and threshold 1, the owning node (below) hosts it withSubmission permission, and both hosts are stuck nodes that you recover with this page.
The node whose namespace the party belongs to is the owning node. The pre-flight check shows which one it is. Recover the nodes in this order:
- The other host: steps 1 to 17, without the party. Its step 8 removes the old node as a host of the party.
- The owning node: steps 1 to 17. Its steps 4 and 10 bring back the party’s contracts.
- The other host: phase G, which adds it back as a host.
Before you start
Nothing in this section changes the stuck node.Versions
- Stuck node: there’s no need to upgrade it. If you already upgraded it in place, carry on with that version.
- New node: run the Splice version that the network runs now.
Console setup
Enable repair and preview commands in the console configuration file of each console session:participant. If your console names it differently (for example participant2), start each console session with val participant = participant2. Run each snippet as a whole: later lines use values that earlier lines define.
The snippets write their files (party lists, exports, DARs, identities dump) to the console’s working directory, and later steps read them. Keep them on the host, not only inside a container that can be removed. Steps 9 to 11 read them in the console of the new node, so run that console from the same directory or copy the files there.
Decide before you start
- New participant identifier: a name that no participant in your namespace has used before, including earlier recovery attempts. You pass it in step 8 and on every later start of the new node.
- Traffic: who buys traffic for the new participant ID as soon as step 8 creates it (see Traffic for the new participant).
Pre-flight check
Run this read-only check in the console of the stuck participant. It changes nothing on the node. Replace the placeholder with the DSO party ID from<scan-url>/api/scan/v0/dso-party-id.
If you already ran participant.synchronizers.perform_manual_lsu, participant.repair.perform_late_lsu or the SQL statements of an earlier recovery runbook on the stuck node, first restore the database backup taken before them.
- The only registered synchronizer is the old one (see the table at the top). If it shows another one, someone ran
perform_manual_lsu,repair.perform_late_lsuor the SQL statements of an earlier recovery runbook on this node. Restore the database backup from before that. - Only with KMS: the KMS is configured in Canton, not through a KMS driver. Every key has a name, only the namespace key’s name contains
namespace, and every key showskms=true. - Every party with
external=falseand a single host showsown-namespace=true. - Every party with
external=truehas a single host, and its owner can sign a new hosting for it soon after step 10. Until then the party has no working host and can’t use its assets. - Every party with more than one host fits Multi-hosted parties. Compare the output of its two hosts: the party shows
own-namespace=trueon one of them. If it doesn’t on either, its owner is outside these nodes.
external=true and every party shows Contracts not shared with the DSO party ...: 0, you can take the CC-only path of Choose your path.
- Local keys
- KMS
Nothing more to do here. Step 1 gets the identities backup from the validator app.
Phase A. Prepare the stuck node
Step 1. Back up your validator
Take a full backup of your validator’s databases as described in Backups of postgres instances. Step 8 also needs a backup of the node identities. Get it now, because the validator app isn’t started again after step 2.- Local keys
- KMS
Fetch it from the validator app as described in Backup of Node Identities. If the validator app can’t provide it, create it with the console script in Obtaining an Identities Backup from a Participant Database Backup. Its output contains the private keys. If the stuck node runs Splice 0.10.0 or later, enable key downloads first, as that section describes.
keyId and a name (KMS) or hasKeyPair: true (local keys).
Step 2. Stop the validator app
Stop the validator app, and any other service that uses the participant’s Ledger API or Admin API (for example DAR upload or UI services). The validator app must never run again on the old node, so that it doesn’t reconnect the participant to the synchronizer. As a safety net, add an invalid entry to its configuration so that it fails to start if launched by accident.- Docker Compose
- Helm
The validator app has Then add the invalid entry to the
restart: always, so Docker would start it again after a reboot. Turn that off before you stop it:environment list of the validator service in compose.yaml. The unmatched brace can’t be parsed, so the validator app stops at startup:Step 3. Disconnect the participant from the synchronizer
Prevent the participant from reconnecting when it restarts:- Docker Compose
- Helm
Add this line to the Docker Compose reads it the next time the participant starts, so don’t restart the node for it now.
environment list of the participant service in compose.yaml:manualConnect = true flag set below also prevents reconnects on restarts.
Then, in the Canton console:
Phase B. Export from the stuck node
Step 4. Export the ACS of the internal parties
Export the contracts of all parties in your namespace that aren’t external, including multi-hosted parties that this node owns. The snippet also counts them for the check in step 10. Replace the placeholder with the DSO party ID:Step 5. Export the ACS of each external party
In the same console session as step 4, create one ACS export per external party:Step 6. Download all DARs
Step 7. Export the user management data
Optionally, read the user management and identity provider configuration of your old participant withUserManagementService.ListUsers, UserManagementService.ListUserRights and IdentityProviderConfigService.ListIdentityProviderConfigs on the Ledger API, and save the data. Step 17 restores it.
Phase C. Deploy the new node
Step 8. Deploy a new validator from the identities backup
This step follows Recovery from an identities backup. The validator app initializes the new participant from the identities backup, moves your internal parties to it and imports their DSO-shared contracts (CC among them) from Scan.Set up the new node
- Deployment files. Start from the Docker Compose files or Helm charts of the Splice version that the network runs now, and carry your customizations over as for an upgrade (for example KMS settings, an external database, a proxy or extra services). Keep a copy of the old compose directory or Helm values, in case you need to start the old node again to export from it.
- Settings. Compare the old and the new settings line by line (
.envandcompose.yaml, or the Helm values). Every setting that isn’t a database name, an identity or an image version must be in the new files too (exceptADDITIONAL_CONFIG_DO_NOT_STARTfrom step 2 andADDITIONAL_CONFIG_NO_RECONNECTfrom step 3), for example traffic top-up, authentication, wallet sweep or auto-accept settings. - New databases for the participant and the validator app. Keep the old databases until step 13 passes (CC-only path: until the check of Choose your path passes).
- Memory. The new participant needs the most memory when it first downloads the synchronizer’s topology state. Give the new node at least the memory of the old one, and see the hardware requirements.
- Docker Compose
- Helm
-
No participant bootstrap script. If the
participantservice mounts a script at/app/bootstrap.sc, remove that mount for good. A script that registers keys or initializes the node conflicts with the validator app, and the participant fails withExisting public key for ... is different than inserted key. -
New databases with your own Postgres server: create two new databases. Set their names in
CANTON_PARTICIPANT_POSTGRES_DBof theparticipantservice and indatabaseNameof the validator app’s storage configuration incompose.yaml. -
New databases with the
postgres-splicecontainer: give its volume a new name in the top-levelvolumessection ofcompose.yaml, so the container starts empty. Don’t change the compose project name, since other services would start empty too.
Start the new node
First stop the old participant. It stays stopped from now on, since the new participant uses the same namespace key. You only start it again, still disconnected, to export from it. Then start the new node with the identities backup and the new participant identifier.- Docker Compose
- Helm
Run
./stop.sh in the old node’s compose directory. Both directories use the compose project name splice-validator, so they share container names. To start the old node again, run ./stop.sh in the new node’s directory first, then ./start.sh with your old flags, without -w, in the old node’s directory. The ADDITIONAL_CONFIG_DO_NOT_START entry from step 2 keeps its validator app from starting. Afterwards, run ./stop.sh there and start the new node again with the same command. Until step 14, leave out -w when you start the new node (see the warning box below).To start the new node, use the flags you normally pass to start.sh, with the same -p <party hint> as before (the party IDs depend on it), plus -i and -P:-i needs an absolute path. Pass -P with the same identifier on every later start of the new node, or the validator app stops.- Validator app log:
Success: node is initialized with id PAR::<new participant identifier>::<your namespace>. Get traffic now, see Traffic for the new participant. - Participant log:
Progressed topology downloadlines, thenSuccessfully downloaded topology state. This can take 20 minutes or more. - Validator app log:
Vet packages. - Validator app log:
Migrating party data, and at the endACS import complete.
PACKAGE_SERVICE_CANNOT_AUTODETECT_SYNCHRONIZER errors until the participant is connected. These errors are harmless.
Don’t stop or restart the new node while step 8 runs, especially after Migrating party data: an interrupted Scan import can mean setting up the new participant again from scratch.
Traffic for the new participant
As soon as the validator app logsSuccess: node is initialized with id PAR::<new participant identifier>::<your namespace>, get traffic for that ID while step 8 continues:
- A traffic provider buys it for
PAR::<new participant identifier>::<your namespace>. - Or any wallet with CC buys it with a token standard transfer, with the memo
splice/memo:member-id=PAR::<new participant identifier>::<your namespace>&synchronizer-id=<synchronizer ID>&migration-id=<migration ID>(the linked section shows how to look up the last two). The CC is burnt even if the member ID or the migration ID is wrong, so check both and start with a small purchase.
Insufficient funds to buy configured traffic amount and buys nothing. Check the validator party’s balance before then, and send it more CC or lower the target throughput.
Check the new node
On the CC-only path, step 4 doesn’t run. Wherever this section namesinternal-parties.txt, use the Party: lines of the pre-flight output instead, and expect no Ignoring parties warning.
The validator app does not migrate external parties and multi-hosted parties, and it may unhost them from the stuck participant (see Parties not migrated automatically). They are handled in steps 11 and 12.
In the validator app log, two warnings are expected, but only for parties in external-parties.txt or multi-hosted-parties.txt:
Ignoring parties that we will likely not be able to migrate due to an unsupported namespaceIgnoring parties that we will not be able to migrate because they are multi-hosted
internal-parties.txt, stop and contact DA support.
In the console of the new participant:
internal-parties.txt is missing, stop and contact DA support.
The new participant is still connected at this point. That’s expected; step 9 disconnects it.
If step 8 fails or is interrupted
Save the logs before you stop anything (Docker Compose:docker logs of the participant and validator containers, since ./stop.sh removes them; Helm: kubectl logs of both pods).
- Before the validator app logged
Success: node is initialized with id ...: stop the new node and contact DA support. A retry needs new databases and a new participant identifier. - After that line (for example after a host restart): start the new node again with the same command or values on the same databases. The validator app continues where it stopped. Only the old node must stay stopped.
Phase D. Restore the contracts
If an import in this phase or in G6 fails, look up the error in the error reference before you run anything else. Don’t reconnect unless it says so.Step 9. Upload the exported DARs
splice-), so the old Splice versions stay unvetted. If you haven’t bought traffic, each DAR can take a minute or more (see SEQUENCER_NOT_ENOUGH_TRAFFIC_CREDIT in the error reference). If the snippet fails or you interrupt it, run it again.
Vetting the other DARs can also bring back versions that you unvetted on the old node, for example because they have bugs. Unvet again any DAR that you know should stay unvetted, by its main package ID (participant.dars.list() shows them):
Step 10. Import the ACS of the internal parties
This step requires step 8 to be complete (the parties are hosted on the new node and their CC contracts imported) and the validator app to be stopped. The import leaves out the contracts shared with the DSO party, since step 8 imported their current state from Scan, and the export of step 4 only has their state at the LSU upgrade time. The snippet also removes the old participant’s traffic top-up record, so that the validator app doesn’t keep buying traffic for the old participant ID. Replace the two placeholders. The validator party ID is the line ofinternal-parties.txt that starts with <your party hint>:::
println shows one line with the old participant ID if a top-up record was removed, or nothing. Running the val oldTopUpStates = ... line again should return List().
The participant log has a summary of the import: Contract import pipeline ... finished. Persisted: <N> new active contracts written. Skipped: ... Dropped: <M> foreign payloads ignored (synchronizer mismatch). Dropped should be 0. “Synchronizer mismatch” here isn’t an ACS commitment mismatch.
Then, in the same console session, compare the contracts with the count of step 4:
Splice.Wallet.TopUpState:ValidatorTopUpState: one fewer.Splice.Wallet.Install:WalletAppInstallandSplice.Amulet:ValidatorRight: one more each. The duplicates are harmless.- More contracts of other
Splice.templates.
Splice. differs.
After this step, you have recovered the other assets of your internal parties, including the multi-hosted parties that this node owns.
Step 11. Import the ACS of each external party
Skip this step ifexternal-parties.txt is empty.
An external party can only be hosted on the new node with a hosting signed by its own key, so its owner has to sign first. Run this step once for each party in external-parties.txt, with that party’s owner. Keep the validator app stopped, and run the three console snippets in the same console session: later snippets use values that earlier ones define.
The snippets follow Recover the Coin balance of an external party, with two differences. They keep the party’s signing keys in its new hosting: without them, Canton rejects the hosting even with the owner’s signature. And they disconnect the node before the party’s contracts are imported (see Why does step 11 disconnect right after loading the hosting?). Skip the setup-proposal flow at the end of that section, since the imports restore the party’s transfer preapproval and validator right.
First, in the console of the new node, prepare the new hosting. Replace the placeholder with the party ID:
TOPOLOGY_SERIAL_MISMATCH and the owner has to sign a new hash. If you lose the console session before loading, run the snippet again: while the hosting doesn’t change, it prints the same hash.
The snippet below assumes the owner signs with an Ed25519 key, as for every external party onboarded through Splice. If the party’s key is an ECDSA key (possible for parties onboarded with other tools), contact DA support: loading the hosting would fail.
Once the owner has signed, load the new hosting with both signatures. Replace the placeholder with the owner’s signature in hex, and paste the snippet as a whole:
validFrom time that the snippet printed:
Step 12. Multi-hosted parties of other namespaces
Skip this step ifmulti-hosted-parties.txt is empty. Otherwise finish steps 13 to 17, then add the parties back with phase G once their owning node has finished steps 1 to 17 (see Before you start phase G).
Phase E. Check the ACS commitments
Step 13. ACS checks
After the imports, check the ACS commitments of the new participant in its log. Wait until it has logged the matches for at least two 30-minute commitment periods that ended after the last reconnect in step 10 or 11 (see How long does step 13 take?). First check that commitments are being exchanged:- Docker Compose
- Helm
Commitment correct for sender ... lines from the super validators’ participants and All commitments up to ... have been sent successfully lines.
Then search the whole log for mismatches:
- Docker Compose
- Helm
toInclusive = ... in period = CommitmentPeriod(...)), not by the time of the log line. Mismatches for periods that end before the disconnect before the last import are expected (see Which ACS commitment mismatches are expected?). That disconnect is the one at the end of step 9 if step 10 was your last import, or the one right after load in step 11.
Step 13 has passed when the first check shows the expected lines and no mismatch has a period that ends after that disconnect.
Look up the other warnings and errors of the participant log in the error reference. If one isn’t there and names one of your parties or contracts, stop and contact DA support.
With a multi-hosted party, the other host, if already recovered, logs mismatches with the owning node while the owning node is between its steps 8 and 10. They must stop once the owning node has passed its step 13.
If any other mismatch has a period that ends after the disconnect before the last import, stop and contact DA support. Send:
- the mismatch log lines, with the sending participant and the period of each
- the import summaries of steps 10 and 11 from the participant log
- the output of the comparison in step 10
Phase F. Go live
Step 14. Re-enable auto-connect and start the validator app
Remove theADDITIONAL_CONFIG_NO_RECONNECT override of step 3 from the new node, and run:
- Docker Compose
- Helm
Remove the
ADDITIONAL_CONFIG_DO_NOT_START entry of step 8 from the validator service in the new node’s compose.yaml. Then start the node with the same start.sh command as in step 8, including -P (-i can be left out. Before Splice 0.10, keep it if this node takes part in phase G: on those versions -i is what turns on the repair commands that phase G uses). Then turn the validator app’s restart policy back on, since start.sh doesn’t:Step 15. Rebuild the Ledger API app data
The Ledger API state on the new validator starts fresh at the point where the ACSes are imported and the node is connected to the new synchronizer. Offsets are also re-initialized, so Ledger API clients must rebuild their state from the new participant, starting with an ACS snapshot. They need their Ledger API users on the new node first: do the first paragraph of step 17 before you restart them. If your application is built on top of PQS, drop its database and restart it against the new participant.Step 16. Checks and troubleshooting
See the error reference below and the troubleshooting guide for recovering a node from its keys.Step 17. Import the Ledger API users and back up the new node
Set up Ledger API identity providers and user management with the Ledger APIUserManagementService and IdentityProviderConfigService, using the data from step 7. The validator app grants its own ledger user the rights on the hosted parties when it starts in step 14, so you only need to recreate the users of your own applications. Wallet users are such users too: until you recreate them, they can log in to the wallet, but every action fails with User not found.
Then fetch a new identities backup of the new node from its validator app, as described in Backup of Node Identities (with local keys, enable key downloads first, as that section describes), and take a database backup of the new node, as in step 1. The step 1 backups describe the old participant, so they can’t restore the new node.
Once the new node runs as before, you can delete the old node and its databases. Keep the step 1 backup if you need the old history.
Phase G. Add a recovered node as a host of a multi-hosted party
This phase applies to each party listed inmulti-hosted-parties.txt in step 4: a party that this node hosted, but whose namespace belongs to another node (the owning node). See Multi-hosted parties for the scope and the order of the nodes.
This node can’t host such a party again on its own: the party’s hosting is signed with the owning node’s namespace key. So both nodes sign the new hosting. Then the owning node exports the party’s contracts and this node imports them, with the same repair commands as in steps 4 and 10.
This node disconnects before the new hosting takes effect, and the owning node exports the party’s contracts as of the moment it does. When this node reconnects, it receives everything that happened to the party after that moment. So the party can stay in use during this phase.
Before you start phase G
- This node (the target) has finished steps 1 to 17 without the party.
- The owning node has finished steps 1 to 17 and passed its step 13.
- Both nodes have the repair commands turned on. Splice 0.10 images have them on by default. Before Splice 0.10: on Docker Compose, the last
start.shincluded-i(see step 14); on Helm,enableRepairCommands: true.
<party ID>: the party frommulti-hosted-parties.txt.<target participant ID>: the new participant ID of this node, asparticipant.idprints it in its console (PAR::...).
G1. Target: stop the validator app and upload the DARs
Stop the validator app and the other services you stopped in step 2, as in the warning box of step 8. G7 starts them again as in step 14. Keep them stopped until G7, since the validator app connects the participant to the synchronizer whenever it starts. Copy thedars directory that the owning node downloaded in its step 6 to this node, and upload the DARs as in step 9. The participant is connected and must stay connected for G2, so run only the upload line:
G2. Target: propose to host the party, then disconnect
While connected:G3. Owning node: sign the new hosting
Run the first line once, before the first attempt:mustFullyAuthorize = true, the command fails if the owning node hasn’t received the target’s proposal yet. In that case wait a minute and run the last line again. If it keeps failing, stop and send DA support the error. Use the same permission as in G2.
G4. Owning node: wait for the new hosting and find its offset
G5. Owning node: export the party’s contracts at that offset
G6. Target: import the contracts and reconnect
Copyparty-acs.gz over, back up the participant database, then:
G7. Check
On either node, the mapping lists both new participants:Error reference
FAQ
Why does step 11 disconnect right after loading the hosting?
The node stays disconnected until the party’s contracts are imported. If a contract of the party changes meanwhile, the node processes the change when it reconnects, after the import. If the node were still connected when such a change happens, the import would fail withCannot add previously archived contract. That’s why the snippet disconnects straight after load, which returns once the hosting has taken effect. A change in the few milliseconds between the two lines would have the same effect.
Why do steps 10, 11 and G6 handle the topology offset error differently?
Canton 3.7 refuses a repair import while the node’s last event is a topology change, and fails withCannot apply a repair command as the last event is a topology offset. In step 10, reconnecting for a minute lets the node process newer events. In step 11 and G6, the last event is the party’s new hosting, which is rare. Reconnecting would make the node process the party’s transactions before it has the party’s contracts. So step 11 runs the import again with forceRepairWhenTopologyTransactionAtLedgerEnd = true, the same flag that the validator app sets for its import from Scan in step 8.