How to connect participant to a domain running on a remote machine?

Hi, i’m learning how to run daml on canton. and have been stuck at connecting to a remote domain.

the networks are all good, when i’m running
participant.domains.connect(“domain”, “http://remote-ip:14008”)
Below error occurred:
INFO c.d.c.p.d.g.GrpcSequencerConnectClient:participant=alice - Now retrying operation ‘verify active’.
INFO c.d.c.p.d.g.GrpcSequencerConnectClient:participant=alice - The operation ‘verify active’ was not successful. Retrying after 500 milliseconds. Result: Right(false).
GrpcClientError: INVALID_ARGUMENT/ParticipantIsNotActive(CN10032-4): The participant is not yet active; serverResponse=Participant PAR::participant1 is not active
Request: ConnectDomain(Domain ‘domain’)
Trailers: Metadata(content-type=application/grpc)

What configuration shall i do before connecting the remote domain?
Thanks for your help in advance.

Normally, this means the domain operator has not yet activated the participant or deactivated the participant.

https://www.canton.io/docs/stable/user-manual/usermanual/error_codes.html#CN10032

However, if you use default settings, every participant can connect to a domain without explicit activation.

If that does not solve it right away, could you please tell us more about your setup, in particular:

  • Configuration of the remote domain
  • Log files of participant and domain
  • Sequence of commands you run to initialize participant and domain

Looking forward to your response.

Thank for replying.

I just used the default settings and set storage as postgres database.

The problem is solved by removing the dirty data, by using a newly created postgres database.

Can you suggest how to do data clean up, so that i don’t have to remove and create the database back?

Thanks for getting back to me.

If to do a “full reset”, we typically also purge the database, as you did.

In the past, users have got into trouble by resetting the database only for a subset of nodes (e.g. only for the domain). So it is important to reset it for all nodes. It is also helpful to chose the same storage (in-memory, postgres, …) for all nodes, because otherwise only the in-memory nodes get reset if you restart the system.

That said, Canton really is (or at least should be) capable of restarting its nodes without purging the database. If you can provide me exact steps to reproduce and/or logfiles, I will try to tell you what went wrong.