Overview
The host agent runs on a Linux machine and reads the kernel’s own CPU and memory accounting for every unit on the box. CostOptix prices that usage against what the machine costs you, so you can see what each application actually costs to run. It works on any Linux machine: a cloud VM, a dedicated server you rent, or hardware you own.Cost per application
systemd services, Docker containers, pm2 and supervisord apps, and Kubernetes pods, each priced separately.
Team bills
Claim units for teams. Each month closes into a sealed bill.
Dependency map
Which units call which, and what stops working if one goes down.
Right size
Whether the machine fits its workload, and what it would cost on a different one.
Requirements
The installer checks all of this first and stops with a clear message if something is missing. On an older kernel that still uses cgroup v1, boot with
systemd.unified_cgroup_hierarchy=1 and run it again.
Connect a machine
Open Hosts in CostOptix and follow the guided steps.1
Name the machine and tell us what it costs
Give the machine a name you will recognise. Then pick how it is billed. Without a cost, the agent can measure usage but nothing can be priced. See Tell CostOptix what it costs.
2
Create an agent key
Click Create agent key. The key can only report host metrics, so it is safe to leave on the machine. It is valid for one year. Copy it now, it is shown only once.
3
Run the installer
SSH into the machine and run the generated command. It installs the agent as a systemd service that starts on boot and restarts on failure. The page watches for the first report and shows the machine as soon as it arrives.
/etc/cost-optix/host-agent.env (readable only by root), creates the cost-optix-host-agent service, starts it and confirms it booted.
Prefer to install it yourself?
Prefer to install it yourself?
Put these values in The guided setup shows the exact file for your machine under the manual option.
/etc/cost-optix/host-agent.env with mode 600, install the binary at /usr/local/bin/cost-optix-host-agent, then run sudo systemctl enable --now cost-optix-host-agent.Check the agent
Tell CostOptix what it costs
Open the machine in Hosts and click Cost basis. Changes apply from today forward.
You can also set the currency, and Billed through: the connected cloud account that pays for this machine, if any. When you pick one, the Overview counts this machine inside that cloud bill instead of adding it again. Pick Not a connected cloud account for on-prem machines or other providers.
Machines that are Kubernetes nodes
If the machine is also a node in a cluster that runs the CostOptix Kubernetes agent, choose how to split its cost:The Hosts page
Pick a machine at the top of the page. Each tab answers one question.Where the money goes
The agent groups everything it finds into three buckets:- Your workloads. What you deployed on purpose: containers, pods and apps.
- Machine overhead. What the machine needs to run itself, such as system services.
- Idle. Capacity you pay for that nothing is using.
Right size and what-if
The Machine tab looks at sustained daily peaks for processor and memory, over days the agent fully covered, and tells you whether the machine is too big, about right, or close to its limit. It needs at least a week of evidence before it suggests anything. You can also price the last 30 sealed days of usage on a different machine. Enter the cores, memory and, optionally, the price, and CostOptix shows whether the workload would fit and what it would cost.On a machine with a flat monthly cost, a smaller size saves nothing until you actually move to a cheaper machine. The page says so instead of showing a saving that would not appear on any bill.
Dependency map
The Dependencies tab draws which units on the machine called which, over the last 7 days, including calls to other machines and the internet. Select a unit to see what calls it and what it calls, so you know what would break without it. Busy maps can be grouped, filtered by team and opened full screen. The agent records which units were connected, never what the connections carry. To turn mapping off, setCOST_OPTIX_CONNECTIONS=off in the agent’s env file and restart it.
Team billing
On the Attribution tab, assign a whole machine to a team, or claim individual units. Unclaimed units stay Unclaimed and are never quietly spread across the teams that did claim. Each day seals once it is complete. At month end the month closes into a bill:- Direct cost is what a team’s own units used.
- Idle is split across claiming teams in proportion to their direct cost.
- If agents missed some hours, the bill says how much of the month was covered. A gap is missing measurement, not saved money.
Agent health and upgrades
The Machine tab has an agent health panel. It checks that the agent is reporting, whether a newer version is out, when the agent key expires, how much of today was covered, and whether a cost basis is set. When an upgrade is available it shows the command. To upgrade, run this on the machine. It keeps the existing key and machine name:Removing a host
On the machine:Security
The agent runs as root so it can read cgroup accounting for every unit. It reads usage counters, unit names, and which units connect to which. It never sends command lines or connection contents, and it makes no outbound connections other than reporting to CostOptix. The systemd unit runs withNoNewPrivileges, a read-only system and home directory, and a private /tmp.
See Security for the full platform model.