Machines and relays
A machine holds a small registry of the relays it knows about, and exactly one
of them is active at a time. Everything else — which machines you can see, which
console cmdop open reaches, where its join key applies — follows from which relay
is active.
Inspect and choose a relay
cmdop remotes list # every relay entry this machine knows
cmdop remotes show # the active one (or name one to inspect it)
cmdop remotes add <url> # register another relay
cmdop remotes use <name> # make it the active relay
cmdop remotes remove <name> # forget an entrycmdop remotes use is a real switch, not a bookmark change. It repoints the
active relay and reconnects a running agent in place — you do not restart
anything by hand. It then tells you which of four things happened:
| Outcome | What it means | What to do |
|---|---|---|
| Reconnected | The agent is connected to the new relay | Nothing |
| Join needed | This machine has no credential there yet | cmdop join <join-key> --server <url> |
| Unreachable | The switch was made, but the relay did not answer | Check the address and the network |
| Kept last session | Switched, previous session retained | Verify with cmdop status |
Joining a relay
Registering a relay is not the same as being allowed onto it. Membership comes from joining with that relay’s fleet join key:
cmdop join <join-key>
cmdop join <join-key> --server https://relay.example.comJoining is per relay. A machine can hold credentials for several and move
between them with cmdop remotes use; each keeps its own membership.
Connecting to a relay is not hosting one
Two different surfaces are easy to confuse:
cmdop remotesis the registry of relays this machine connects to.cmdop serverruns the relay this machine hosts, which other machines join.
Switching the active relay never changes the relay you may be hosting here, and turning your own relay off does not detach you from a relay you have joined.
What the machine list reflects
cmdop connect --list shows the machines of the active relay. If a machine
you expect is missing, confirm you are pointed at the right relay before
investigating the machine itself:
cmdop remotes show
cmdop statusCommon questions
What is the active relay in Cmdop?
The active relay is the relay this machine currently uses for roster, console, join, and connect operations.
Can one machine know several relays?
Yes. A machine can register several relays, but exactly one is active at a time. Each relay keeps its own membership.
Does switching relays change the relay I host?
No. cmdop remotes use changes the relay this machine connects to. It does not
start, stop, or reconfigure a relay hosted on the same machine.
Related
- Machines — listing, the picker, and attachability.
- Authentication and PINs
- Fleets