Agent Lifecycle

Creating, starting, stopping, and removing an agent — and what changes once you install it as a service.

mur agent create coach --model llama3.2:3b   # create
mur agent start coach                        # start
mur agent stop coach                         # stop, and keep it stopped
mur agent restart coach                      # restart onto an upgraded runtime
mur agent remove coach                       # unregister (data survives)
mur agent remove coach --purge               # unregister and delete its data

To loosen one boot on purpose — --no-hitl, --net=unrestricted, --full-perms — see Startup Overrides.

Supervised vs unsupervised

By default mur agent start spawns the runtime as a detached process. It runs until something stops it — a crash, a logout, a reboot — and nothing brings it back.

mur agent install-service <name> writes a launchd (macOS) or systemd --user (Linux) unit, so the agent starts at login and restarts if it exits:

mur agent install-service coach
mur agent install-service coach --dry-run    # print the unit, write nothing

This changes what the other commands do:

unsupervisedwith a service installed
startdetached spawnloads/kickstarts the service
stopsignals the processunloads the service, then signals
restartrespawnlets the supervisor respawn it
removedeletes the runtime symlinkalso deletes the service descriptor

Why stop unloads it. The service sets KeepAlive, so the supervisor restarts the runtime the instant it exits. Signalling the process alone would only swap its pid — the agent would still be running a second later. stop therefore takes the agent out of the supervisor's hands first, and confirms nothing came back before reporting success.

The service descriptor stays on disk, so mur agent start brings the agent back and it returns at the next login.

Removing an agent

remove keeps the agent's data. ~/.mur/agents/<name>/ — its profile, identity keypair, skills, conversation history, companion inbox — is left in place, and the command prints where:

Removed agent 'coach' (data preserved at /Users/you/.mur/agents/coach)

Pass --purge to delete that directory as well. There is no undo.

Two guards run first:

  • Still running — removal refuses. Stop it first.
  • Unread companion messages — removal refuses so you don't lose them. Read them with mur agent companion inbox <name> --unread-only, or pass --force.

Editing an MCP server while the agent runs

Most edits to an existing MCP server in profile.yaml take effect on the agent's next turn, with no restart:

EditApplies
args, timeout_secsnext turn
network.allow_hosts, network.deny_hostsnext turn
/browser live with new hosts or a new --profilenext turn — the browser's open tab is closed and a new one opened
commandnext turn, only if the entry has a pin (binary_sha256) that verifies, a valid signature, and an exec path the sandbox already allows
adding or removing a serverrestart
url, auth, network.mode, a new filesystem or spawn grantrestart
any command or args change on an interpreter-launched server (node, python, npx, …)restart — the interpreter's pin says nothing about the code its args name (MCP Binary Pinning)

A hot edit restarts that one server with the new settings. A tool call still running on the old one finishes there, and the old one's egress token stops working once that call is done. If the edit adds or removes tools, that turn's reply names them.

An edit only a restart applies keeps the agent on the previous config, and the reply says so with the exact mur agent restart <name> command. In mur agent cli and the Hub the reply also carries a restart chip (Agent CLI, MUR Hub), once per notice rather than every turn. A refused edit — a pin that no longer verifies, say — gets no chip, because a restart would read the same config and fail the same way; mur agent doctor lists refused edits with the reason.

Checking state

mur agent list                          # every agent, with status, uptime, pid
mur agent status coach                  # one agent in detail
mur agent restart --stale --dry-run     # which agents run an older binary than their own symlink

restart --stale compares the build recorded in each agent's running.lock against the binary that agent's own ~/.local/bin/mur_agent_<name> symlink points to — not a single global runtime — because that symlink is what the service actually execs, and a dev checkout, an older keg, and mur update's copy can coexist. An agent is stale only when its own binary differs, so a mixed fleet is reported per agent instead of being dragged toward one baseline.

Agents with no lock file are reported, not skipped: a stopped agent appears as not examined (N not running), and one that has a service installed but isn't running gets a âš  warning to mur agent start it.

After upgrading MUR, mur update --restart-agents does the refresh and the restart together, and prints a per-agent summary with the build id on each side of the arrow.