Statistics
| Branch: | Tag: | Revision:

root / man / gnt-job.rst @ 81879d92

History | View | Annotate | Download (3.5 kB)

1 b3723c81 Iustin Pop
gnt-job(8) Ganeti | Version @GANETI_VERSION@
2 b3723c81 Iustin Pop
============================================
3 b3723c81 Iustin Pop
4 b3723c81 Iustin Pop
Name
5 b3723c81 Iustin Pop
----
6 b3723c81 Iustin Pop
7 b3723c81 Iustin Pop
gnt-job - Job commands
8 b3723c81 Iustin Pop
9 b3723c81 Iustin Pop
Synopsis
10 b3723c81 Iustin Pop
--------
11 b3723c81 Iustin Pop
12 b3723c81 Iustin Pop
**gnt-job** {command} [arguments...]
13 b3723c81 Iustin Pop
14 b3723c81 Iustin Pop
DESCRIPTION
15 b3723c81 Iustin Pop
-----------
16 b3723c81 Iustin Pop
17 b3723c81 Iustin Pop
The **gnt-job** is used for examining and manipulating the job
18 b3723c81 Iustin Pop
queue.
19 b3723c81 Iustin Pop
20 b3723c81 Iustin Pop
COMMANDS
21 b3723c81 Iustin Pop
--------
22 b3723c81 Iustin Pop
23 b3723c81 Iustin Pop
ARCHIVE
24 b3723c81 Iustin Pop
~~~~~~~
25 b3723c81 Iustin Pop
26 b3723c81 Iustin Pop
**archive** {id...}
27 b3723c81 Iustin Pop
28 b3723c81 Iustin Pop
This command can be used to archive job by their IDs. Only jobs
29 b3723c81 Iustin Pop
that have finished execution (i.e either *success*, *error* or
30 b3723c81 Iustin Pop
*canceled* jobs).
31 b3723c81 Iustin Pop
32 b3723c81 Iustin Pop
AUTOARCHIVE
33 b3723c81 Iustin Pop
~~~~~~~~~~~
34 b3723c81 Iustin Pop
35 b3723c81 Iustin Pop
**autoarchive** {*age* | ``all``}
36 b3723c81 Iustin Pop
37 b3723c81 Iustin Pop
Archive jobs by their age. This command can archive jobs older than
38 b3723c81 Iustin Pop
*age* seconds, or alternatively all finished jobs can be archived
39 b3723c81 Iustin Pop
if the string all is passed.
40 b3723c81 Iustin Pop
41 b3723c81 Iustin Pop
CANCEL
42 b3723c81 Iustin Pop
~~~~~~
43 b3723c81 Iustin Pop
44 e1c701e7 Michael Hanselmann
| **cancel**
45 0cbeecdf Klaus Aehlig
| {[\--force] {\--pending | \--queued | \--waiting} |
46 0cbeecdf Klaus Aehlig
|  *job-id* ...}
47 b3723c81 Iustin Pop
48 e1c701e7 Michael Hanselmann
Cancel the job(s) identified by the given *job id*. Only jobs that have
49 b3723c81 Iustin Pop
not yet started to run can be canceled; that is, jobs in either the
50 e1c701e7 Michael Hanselmann
*queued* or *waiting* state. To skip a confirmation, pass ``--force``.
51 e1c701e7 Michael Hanselmann
``--queued`` and ``waiting`` can be used to cancel all jobs in the
52 e1c701e7 Michael Hanselmann
respective state, ``--pending`` includes both.
53 b3723c81 Iustin Pop
54 e9e07c9c Michael Hanselmann
CHANGE-PRIORITY
55 e9e07c9c Michael Hanselmann
~~~~~~~~~~~~~~~
56 e9e07c9c Michael Hanselmann
57 67c15d8b Iustin Pop
| **change-priority** \--priority {low | normal | high}
58 0cbeecdf Klaus Aehlig
| {[\--force] {\--pending | \--queued | \--waiting} |
59 0cbeecdf Klaus Aehlig
|  *job-id* ...}
60 e9e07c9c Michael Hanselmann
61 e9e07c9c Michael Hanselmann
Changes the priority of one or multiple pending jobs. Jobs currently
62 e9e07c9c Michael Hanselmann
running have only the priority of remaining opcodes changed.
63 e9e07c9c Michael Hanselmann
``--priority`` must be specified. ``--queued`` and ``waiting`` can be
64 e9e07c9c Michael Hanselmann
used to re-prioritize all jobs in the respective state, ``--pending``
65 e9e07c9c Michael Hanselmann
includes both. To skip a confirmation, pass ``--force``.
66 e9e07c9c Michael Hanselmann
67 b3723c81 Iustin Pop
INFO
68 b3723c81 Iustin Pop
~~~~
69 b3723c81 Iustin Pop
70 b3723c81 Iustin Pop
**info** {*id*...}
71 b3723c81 Iustin Pop
72 b3723c81 Iustin Pop
Show detailed information about the given job id(s). If no job id
73 b3723c81 Iustin Pop
is given, all jobs are examined (warning, this is a lot of
74 b3723c81 Iustin Pop
information).
75 b3723c81 Iustin Pop
76 b3723c81 Iustin Pop
LIST
77 b3723c81 Iustin Pop
~~~~
78 b3723c81 Iustin Pop
79 72ef8df8 Michael Hanselmann
| **list** [\--no-headers] [\--separator=*SEPARATOR*]
80 72ef8df8 Michael Hanselmann
| [-o *[+]FIELD,...*] [\--filter] [job-id...]
81 b3723c81 Iustin Pop
82 b3723c81 Iustin Pop
Lists the jobs and their status. By default, the job id, job
83 b3723c81 Iustin Pop
status, and a small job description is listed, but additional
84 b3723c81 Iustin Pop
parameters can be selected.
85 b3723c81 Iustin Pop
86 b3723c81 Iustin Pop
The ``--no-headers`` option will skip the initial header line. The
87 b3723c81 Iustin Pop
``--separator`` option takes an argument which denotes what will be
88 b3723c81 Iustin Pop
used between the output fields. Both these options are to help
89 b3723c81 Iustin Pop
scripting.
90 b3723c81 Iustin Pop
91 b3723c81 Iustin Pop
The ``-o`` option takes a comma-separated list of output fields.
92 b3723c81 Iustin Pop
The available fields and their meaning are:
93 b3723c81 Iustin Pop
94 3086220e Michael Hanselmann
@QUERY_FIELDS_JOB@
95 b3723c81 Iustin Pop
96 3086220e Michael Hanselmann
If the value of the option starts with the character ``+``, the new
97 3086220e Michael Hanselmann
fields will be added to the default list. This allows one to quickly
98 3086220e Michael Hanselmann
see the default list plus a few other fields, instead of retyping
99 3086220e Michael Hanselmann
the entire list of fields.
100 b3723c81 Iustin Pop
101 43d51ef2 Michael Hanselmann
To include archived jobs in the list the ``--archived`` option can be
102 43d51ef2 Michael Hanselmann
used.
103 43d51ef2 Michael Hanselmann
104 72ef8df8 Michael Hanselmann
The following options can be used to show only specific jobs:
105 72ef8df8 Michael Hanselmann
106 72ef8df8 Michael Hanselmann
``--pending``
107 72ef8df8 Michael Hanselmann
  Show only jobs pending execution.
108 72ef8df8 Michael Hanselmann
``--running``
109 72ef8df8 Michael Hanselmann
  Show jobs currently running only.
110 72ef8df8 Michael Hanselmann
``--error``
111 72ef8df8 Michael Hanselmann
  Show failed jobs only.
112 72ef8df8 Michael Hanselmann
``--finished``
113 72ef8df8 Michael Hanselmann
  Show finished jobs only.
114 72ef8df8 Michael Hanselmann
115 72ef8df8 Michael Hanselmann
If exactly one argument is given and it appears to be a query filter
116 354c4f62 Michael Hanselmann
(see **ganeti**\(7)), the query result is filtered accordingly. For
117 72ef8df8 Michael Hanselmann
ambiguous cases (e.g. a single field name as a filter) the ``--filter``
118 72ef8df8 Michael Hanselmann
(``-F``) option forces the argument to be treated as a filter.
119 72ef8df8 Michael Hanselmann
120 b3723c81 Iustin Pop
121 3086220e Michael Hanselmann
LIST-FIELDS
122 3086220e Michael Hanselmann
~~~~~~~~~~~
123 b3723c81 Iustin Pop
124 3086220e Michael Hanselmann
**list-fields** [field...]
125 b3723c81 Iustin Pop
126 3086220e Michael Hanselmann
Lists available fields for jobs.
127 b3723c81 Iustin Pop
128 b3723c81 Iustin Pop
129 f5d13a77 Klaus Aehlig
WAIT
130 f5d13a77 Klaus Aehlig
~~~~~
131 f5d13a77 Klaus Aehlig
132 f5d13a77 Klaus Aehlig
**wait** {id}
133 f5d13a77 Klaus Aehlig
134 f5d13a77 Klaus Aehlig
Wait for the job by the given *id* to finish; do not produce
135 f5d13a77 Klaus Aehlig
any output.
136 f5d13a77 Klaus Aehlig
137 b3723c81 Iustin Pop
WATCH
138 b3723c81 Iustin Pop
~~~~~
139 b3723c81 Iustin Pop
140 b3723c81 Iustin Pop
**watch** {id}
141 b3723c81 Iustin Pop
142 b3723c81 Iustin Pop
This command follows the output of the job by the given *id* and
143 b3723c81 Iustin Pop
prints it.
144 9ff4f2c0 Michael Hanselmann
145 9ff4f2c0 Michael Hanselmann
.. vim: set textwidth=72 :
146 9ff4f2c0 Michael Hanselmann
.. Local Variables:
147 9ff4f2c0 Michael Hanselmann
.. mode: rst
148 9ff4f2c0 Michael Hanselmann
.. fill-column: 72
149 9ff4f2c0 Michael Hanselmann
.. End: