github.com/kardianos/nomad@v0.1.3-0.20151022182107-b13df73ee850/website/source/docs/commands/stop.html.md.erb (about) 1 --- 2 layout: "docs" 3 page_title: "Commands: stop" 4 sidebar_current: "docs-commands-stop" 5 description: > 6 The stop command is used to stop a running job. 7 --- 8 9 # Command: stop 10 11 The `stop` command is used to stop a running job and signals the scheduler 12 to cancel all of the running allocations. 13 14 ## Usage 15 16 ``` 17 nomad stop [options] <job> 18 ``` 19 20 The stop command requires a single argument, specifying the job ID to 21 cancel. 22 23 Upon successful deregistraion, an interactive monitor session will start to 24 display log lines as the job unwinds its allocations and completes shutting 25 down. The monitor will exit once all allocations are stopped and the job has 26 reached a terminal state. It is safe to exit the monitor early using ctrl+c. 27 28 ## General Options 29 30 <%= general_options_usage %> 31 32 ## Stop Options 33 34 * `-detach`: Return immediately instead of monitoring. A new evaluation ID 35 will be output, which can be used to call the monitor later using the 36 [eval-monitor](/docs/commands/eval-monitor.html) command. 37 38 ## Examples 39 40 Stop the job with ID "job1": 41 42 ``` 43 $ nomad stop job1 44 ==> Monitoring evaluation "43bfe672-e9a2-1cb8-457a-4c2dca5ce1c7" 45 Evaluation status changed: "pending" -> "complete" 46 ==> Evaluation "43bfe672-e9a2-1cb8-457a-4c2dca5ce1c7" finished with status "complete" 47 ``` 48 49 Stop the job with ID "job1" and return immediately: 50 51 ``` 52 $ nomad stop -detach job1 53 507d26cb-1d67-672c-da9d-f6053837bb70 54 ```