Files
nomad/website/content/docs/commands/job/eval.mdx
Aimee Ukasick dae496e427 Docs: SEO front matter description for search: commands section (#25175)
* Enhance front matter description for search

* acl section

* alloc section

* config section

* deployment section

* eval section

* job section

* license section

* namespace section

* node section

* node pool section

* operator section

* plugin section

* quota section

* recommendation section

* scaling section

* sentinel section

* server section

* service section

* setup section

* system section

* tls section

* var section

* volume section

* change reference to command reference

* Apply suggestions from code review

Co-authored-by: Jeff Boruszak <104028618+boruszak@users.noreply.github.com>

---------

Co-authored-by: Jeff Boruszak <104028618+boruszak@users.noreply.github.com>
2025-03-19 12:02:02 -05:00

79 lines
2.4 KiB
Plaintext

---
layout: docs
page_title: 'nomad job eval command reference'
description: |
The `nomad job eval` command forces an evaluation of a job. Optionally, force placement of failed allocations.
---
# `nomad job eval` command reference
The `job eval` command is used to force an evaluation of a job, given the job
ID.
## Usage
```plaintext
nomad job eval [options] <job_id>
```
The `job eval` command requires a single argument, specifying the job ID to
evaluate. If there is an exact match based on the provided job ID, then the job
will be evaluated, forcing a scheduler run.
When ACLs are enabled, this command requires a token with the `submit-job`
capability for the job's namespace. The `list-jobs` capability is required to
run the command with a job prefix instead of the exact job ID. The `read-job`
capability is required to monitor the resulting evaluation when `-detach` is
not used.
## General options
@include 'general_options.mdx'
## Eval options
- `-force-reschedule`: `force-reschedule` is used to force placement of failed
allocations. If this is set, failed allocations that are past their reschedule
limit, and those that are scheduled to be replaced at a future time are placed
immediately. This option only places failed allocations if the task group has
rescheduling enabled.
- `-detach`: Return immediately instead of monitoring. A new evaluation ID
will be output, which can be used to examine the evaluation using the
[eval status] command.
- `-verbose`: Show full information.
## Examples
Evaluate the job with ID "job1":
```shell-session
$ nomad job eval job1
==> Monitoring evaluation "0f3bc0f3"
Evaluation triggered by job "test"
Evaluation within deployment: "51baf5c8"
Evaluation status changed: "pending" -> "complete"
==> Evaluation "0f3bc0f3" finished with status "complete"
```
Evaluate the job with ID "job1" and return immediately:
```shell-session
$ nomad job eval -detach job1
Created eval ID: "4947e728"
```
Evaluate the job with ID "job1", and reschedule any eligible failed allocations:
```shell-session
$ nomad job eval -force-reschedule job1
==> Monitoring evaluation "0f3bc0f3"
Evaluation triggered by job "test"
Evaluation within deployment: "51baf5c8"
Evaluation status changed: "pending" -> "complete"
==> Evaluation "0f3bc0f3" finished with status "complete"
```
[eval status]: /nomad/docs/commands/eval/status