Job Allocations
In Maand, when a job is assigned to a worker, it is referred to as an allocation. Allocations are determined based on the matching labels and selectors between jobs and worker.
Viewing Job Allocations
To see the current job allocations, use the command:
$ maand cat allocations
This displays which jobs are assigned to which workers, along with their statuses.
Example Output
worker_ip job disabled removed
------------- ------------- -------- -------
10.27.221.181 cassandra 0 0
10.27.221.144 cassandra 0 0
10.27.221.170 cassandra 0 0
10.27.221.181 node_exporter 0 0
10.27.221.144 node_exporter 0 0
10.27.221.170 node_exporter 0 0
10.27.221.181 opensearch 0 0
10.27.221.144 opensearch 0 0
10.27.221.170 opensearch 0 0
10.27.221.181 prometheus 0 0
Explanation of Columns
worker_ip
: The IP address of the worker to which the job is allocated.job
: The name of the allocated job.disabled
: A value of0
indicates that the job is enabled.removed
: A value of0
indicates that the job was allocated to that agent and later removed.
How Allocations Work
-
Build Configuration:
- Allocations are prepared during the
maand build
process.
- Allocations are prepared during the
-
Update Agents:
- Allocations are applied to agents during the
maand deploy
process.
- Allocations are applied to agents during the
By inspecting the allocations table, you can confirm which jobs are running/ will be on which workers.