Skip to main content

Install a Collector

A Collector is a small program that runs on a machine inside your network and scans it for Network Discovery. It only makes outgoing HTTPS connections to Starhive, so no firewall needs opening towards it. Install one Collector in each network you want to scan.

What you can run it on​

PlatformHow it runs
Docker (Linux x86-64 or ARM64 hosts, Docker Desktop)A container that restarts with Docker. The image runs as a non-root user.
Linux x86-64 or ARM64 with systemdA service that starts with the machine, runs as its own system user and restarts if it stops.
Windows x86-64A Windows service that starts with the machine and restarts if it stops.
macOS on Apple siliconA program that runs while its terminal stays open. There is no service install on macOS.

The machine needs to reach Starhive over HTTPS, and to reach the addresses you want to scan.

1. Create the install command​

  1. Go to Settings → Discovery. Only workspace owners and admins see it.
  2. Under Collectors, click Add Collector.
  3. Give it a Name that tells you where it runs, for example Stockholm data center, and click Create install command.
  4. Choose how to install it:
    • Docker, then the shell you'll paste into: Linux, macOS or PowerShell, or Windows Command Prompt.
    • Download, then Linux, Windows or macOS.
  5. Click Copy commands.

The commands contain a one-time enrolment token. It's shown only once, works once, and expires after an hour. The Collector only appears in the list once it has enrolled, so if the token runs out before you use it, just add the Collector again.

2. Run the commands on the machine​

Run the copied commands on the machine the Collector will scan from. They do two things:

  1. Enrol the Collector with the token. It creates its own key pair, sends Starhive the public key, and keeps the private key on the machine. The credentials you later give it are encrypted for that key in your browser, so only this Collector can read them, and Starhive can't.
  2. Start it, so it waits for scans.

How to run them depends on the install method:

  • Docker: paste them into the shell you chose. The first command enrols the Collector in a new Docker volume. The second starts the container with that volume, so the enrolment survives restarts and updates. Each Collector needs a volume of its own.
  • Linux: run them as root (they use sudo) in the folder where you unpacked the download. They install the service starhive-collector, which runs as its own system user. Its logs are in journalctl -u starhive-collector.
  • Windows: run them in PowerShell or the Command Prompt opened as administrator, in the folder where you unpacked the download. They install the service StarhiveCollector. Its logs are in the Windows Event Viewer's Application log.
  • macOS: run them in Terminal. The Collector runs while that window stays open.

For a download, check it first: the Download tab shows where to get the Collector, SHA256SUMS and its signature, and the commands to check that the checksums were signed by Starhive's release.

Once enrolled, the Collector shows in the list with its machine's name and version, and Online.

The Collector's status​

Each Collector in the list shows:

  • Online while it's connected, Scanning while it runs a scan, and Offline when it hasn't been heard from for about a minute and a half. One that has enrolled but not checked in yet says Not connected yet.
  • Its machine's name, its version, and when it was last seen.
  • Update available when a newer release is out.

Update a Collector​

Collectors don't update themselves. When one shows Update available, open its Actions menu and choose How to update. The dialog gives the commands for the way it's installed:

  • Docker: a command that downloads the new image, then replaces the container with one that uses the same volume, and a second command that brings the old one back if the new one doesn't start. Options you added to its docker run yourself, such as a proxy or a network, have to be added again. Where Starhive doesn't know the container's name, the dialog gives the new image instead: remove the container and start it again from that image, with the same name, volume and options as before.
  • Service (Linux or Windows): run the service install again from the new release's folder. It replaces the program and restarts the service.
  • Otherwise, for example on macOS: stop the Collector, replace its program with the new one, and start it again as before.

Updating keeps the Collector enrolled, because its keys stay in its data folder (or its volume, in Docker). Update it while it isn't scanning, or the running scan is cut short.

Revoke a Collector​

To stop using a Collector, open its Actions menu and choose Revoke. It's disconnected at once and can't scan again. The credentials encrypted for it are dropped, and its scan profiles stop running until you move them to another Collector.

Revoking doesn't remove the program from the machine. Remove the container and its volume, or uninstall the service and delete its data folder.

Keep the data folder

The Collector's data folder, or its Docker volume, holds its enrolment and private key. If it's lost, the Collector has to be added again, and its credentials entered again.