Skip to content

Install the agent on macOS ​

The macOS agent runs as a launchd daemon under LaunchDaemons, survives reboots and lid-close, and reconnects automatically after the Mac comes back from sleep. Installation is the same curl | sudo bash one-liner used for Linux.

Agent ingest host

This article uses ingest-eu.opsmerge.cloud throughout, the platform's agent ingest host. Always use the host shown in OpsMerge → Add agent, which is pre-filled with your tenant's correct value — don't hand-copy from this article.

Prerequisites ​

  • macOS 12 (Monterey) or later, on either Apple Silicon (M1/M2/M3/M4) or Intel.
  • The Mac must be able to reach ingest-eu.opsmerge.cloud on port 443 (binary download + registration) and on port 4222 (NATS).
  • A user account with sudo / admin rights.
  • A registration token from OpsMerge.

Managed Macs (Jamf, Mosyle, Kandji, Intune)

The same agent works under MDM-managed installs. Wrap the curl | sudo bash command in a pkg or a script payload from your MDM. The agent does not require an MDM profile to function — but it does need to be installed as root.

Step 1 — Generate a registration token ​

  1. Sign in to OpsMerge at app.opsmerge.cloud.
  2. Open Clients, pick the client this Mac belongs to, and click Add agent.
  3. Copy the macOS install command.

The dialog generates a token scoped to that one client. Tokens are single-use by default and expire after 24 hours.

Step 2 — Install ​

Open Terminal and paste the install command. It looks like this (your token will differ):

bash
curl -sL https://ingest-eu.opsmerge.cloud/scripts/install-agent.sh \
  | sudo bash -s -- \
      --server https://ingest-eu.opsmerge.cloud \
      --token YOUR-TOKEN-HERE

You'll be prompted for the local admin password. The script downloads the agent binary for the correct architecture (arm64 or x86_64), verifies its checksum, writes the agent config, installs the launchd plist at /Library/LaunchDaemons/cloud.opsmerge.agent.plist, registers with OpsMerge, and starts the daemon.

Expected runtime is about 10 seconds. You should see:

==> Registration successful
==> Service started

Do not use app.opsmerge.cloud for the install

Cloudflare's Bot Fight Mode returns an HTML challenge to curl, which then breaks bash. The installer host must be ingest-eu.opsmerge.cloud.

Step 3 — Verify ​

In OpsMerge: open Agents, filter by the client, and the new Mac should appear within 30 seconds with Online status, model name (e.g. MacBookPro18,3), and current macOS version.

On the Mac:

bash
sudo launchctl list | grep opsmerge

The agent should be listed with a PID and a 0 exit code (or no exit code at all — it's running).

To tail the log:

bash
tail -f /var/log/rmm-agent.log

Re-installing or repairing ​

Append --force to the install command. The script will stop the existing daemon, remove its plist and config, then install fresh.

bash
curl -sL https://ingest-eu.opsmerge.cloud/scripts/install-agent.sh \
  | sudo bash -s -- \
      --server https://ingest-eu.opsmerge.cloud \
      --token YOUR-TOKEN-HERE \
      --force

What the installer checks before removing anything ​

Before it touches the existing agent, the installer asks OpsMerge whether this device can register with your token. It stops, and leaves the existing agent running and unchanged, when:

  • Another OpsMerge tenant still manages the device. You'll see "This device is still managed by another OpsMerge tenant." Ask that tenant to delete the device from their console, or contact support@opsmerge.cloud, then run the installer again. See Moving a device to another tenant.
  • The device's agent is still online in your own console. Delete the agent from the console, then run the installer again.
  • The token is invalid, expired or used up. Generate a new token from Add agent.

If registration still fails after the old agent has been removed (for example, the network dropped part-way through), the installer says the device is now unmanaged. Fix the problem it reports, then run the installer again without --force.

Removing the agent ​

If you need to uninstall a Mac agent (e.g. before reassigning the device):

bash
sudo /usr/local/bin/rmm-agent uninstall

This stops the daemon, removes the plist, deletes /etc/rmm/, and clears the binary. The agent's history stays in OpsMerge — it just goes offline permanently.

Common installation issues ​

"This action requires the application to be allowed full disk access." macOS Privacy & Security blocks the launchd daemon from reading certain paths. Open System Settings → Privacy & Security → Full Disk Access and add /usr/local/bin/rmm-agent. This affects some collectors (e.g. mailbox-size telemetry) but doesn't block registration or core monitoring.

Agent registers but immediately goes offline. Check /var/log/rmm-agent.log for TLS handshake or permission denied errors. The most common cause is an outbound firewall (e.g. Little Snitch, an MDM-managed proxy, or a Cisco Umbrella roaming client) blocking port 4222.

Apple Silicon Mac installs the wrong architecture. Rare, but if you've forced Rosetta on your Terminal, the install script may see x86_64 and grab the wrong binary. Right-click Terminal in Finder → Get Info → uncheck Open using Rosetta, then re-run.

Next steps ​

Lovingly Created in the UK
OpsMerge is a product of Brindleford Technologies Ltd, company number 16871436, registered in England and Wales.