Statistics
| Branch: | Tag: | Revision:

root / man / gnt-debug.rst @ 75561e6b

History | View | Annotate | Download (3.7 kB)

1 75561e6b Iustin Pop
gnt-debug(8) Ganeti | Version @GANETI_VERSION@
2 75561e6b Iustin Pop
==============================================
3 75561e6b Iustin Pop
4 75561e6b Iustin Pop
Name
5 75561e6b Iustin Pop
----
6 75561e6b Iustin Pop
7 75561e6b Iustin Pop
gnt-debug - Debug commands
8 75561e6b Iustin Pop
9 75561e6b Iustin Pop
Synopsis
10 75561e6b Iustin Pop
--------
11 75561e6b Iustin Pop
12 75561e6b Iustin Pop
**gnt-debug** {command} [arguments...]
13 75561e6b Iustin Pop
14 75561e6b Iustin Pop
DESCRIPTION
15 75561e6b Iustin Pop
-----------
16 75561e6b Iustin Pop
17 75561e6b Iustin Pop
The **gnt-debug** is used for debugging the Ganeti system.
18 75561e6b Iustin Pop
19 75561e6b Iustin Pop
COMMANDS
20 75561e6b Iustin Pop
--------
21 75561e6b Iustin Pop
22 75561e6b Iustin Pop
ALLOCATOR
23 75561e6b Iustin Pop
~~~~~~~~~
24 75561e6b Iustin Pop
25 75561e6b Iustin Pop
**allocator** [--debug] [--dir *DIRECTION*] {--algorithm
26 75561e6b Iustin Pop
*ALLOCATOR* } [--mode *MODE*] [--mem *MEMORY*] [--disks *DISKS*]
27 75561e6b Iustin Pop
[--disk-template *TEMPLATE*] [--nics *NICS*] [--os-type *OS*]
28 75561e6b Iustin Pop
[--vcpus *VCPUS*] [--tags *TAGS*] {*instance*}
29 75561e6b Iustin Pop
30 75561e6b Iustin Pop
Executes a test run of the *iallocator* framework.
31 75561e6b Iustin Pop
32 75561e6b Iustin Pop
The command will build input for a given iallocator script (named
33 75561e6b Iustin Pop
with the ``--algorithm`` option), and either show this input data
34 75561e6b Iustin Pop
(if *DIRECTION* is ``in``) or run the iallocator script and show its
35 75561e6b Iustin Pop
output (if *DIRECTION* is ``out``).
36 75561e6b Iustin Pop
37 75561e6b Iustin Pop
If the *MODE* is ``allocate``, then an instance definition is built
38 75561e6b Iustin Pop
from the other arguments and sent to the script, otherwise (*MODE* is
39 75561e6b Iustin Pop
``relocate``) an existing instance name must be passed as the first
40 75561e6b Iustin Pop
argument.
41 75561e6b Iustin Pop
42 75561e6b Iustin Pop
This build of Ganeti will look for iallocator scripts in the following
43 75561e6b Iustin Pop
directories: @CUSTOM_IALLOCATOR_SEARCH_PATH@; for more details about
44 75561e6b Iustin Pop
this framework, see the HTML or PDF documentation.
45 75561e6b Iustin Pop
46 75561e6b Iustin Pop
DELAY
47 75561e6b Iustin Pop
~~~~~
48 75561e6b Iustin Pop
49 75561e6b Iustin Pop
**delay** [--debug] [--no-master] [-n *NODE*...] {*duration*}
50 75561e6b Iustin Pop
51 75561e6b Iustin Pop
Run a test opcode (a sleep) on the master and on selected nodes
52 75561e6b Iustin Pop
(via an RPC call). This serves no other purpose but to execute a
53 75561e6b Iustin Pop
test operation.
54 75561e6b Iustin Pop
55 75561e6b Iustin Pop
The ``-n`` option can be given multiple times to select the nodes
56 75561e6b Iustin Pop
for the RPC call. By default, the delay will also be executed on
57 75561e6b Iustin Pop
the master, unless the ``--no-master`` option is passed.
58 75561e6b Iustin Pop
59 75561e6b Iustin Pop
The *delay* argument will be interpreted as a floating point
60 75561e6b Iustin Pop
number.
61 75561e6b Iustin Pop
62 75561e6b Iustin Pop
SUBMIT-JOB
63 75561e6b Iustin Pop
~~~~~~~~~~
64 75561e6b Iustin Pop
65 75561e6b Iustin Pop
**submit-job** [--verbose] [--timing-stats] [--job-repeat ``N``]
66 75561e6b Iustin Pop
[--op-repeat ``N``] {opcodes_file...}
67 75561e6b Iustin Pop
68 75561e6b Iustin Pop
This command builds a list of opcodes from files in JSON format and
69 75561e6b Iustin Pop
submits a job per file to the master daemon. It can be used to test
70 75561e6b Iustin Pop
options that are not available via command line.
71 75561e6b Iustin Pop
72 75561e6b Iustin Pop
The ``verbose`` option will additionally display the corresponding
73 75561e6b Iustin Pop
job IDs and the progress in waiting for the jobs; the
74 75561e6b Iustin Pop
``timing-stats`` option will show some overall statistics inluding
75 75561e6b Iustin Pop
the number of total opcodes, jobs submitted and time spent in each
76 75561e6b Iustin Pop
stage (submit, exec, total).
77 75561e6b Iustin Pop
78 75561e6b Iustin Pop
The ``job-repeat`` and ``op-repeat`` options allow to submit
79 75561e6b Iustin Pop
multiple copies of the passed arguments; job-repeat will cause N
80 75561e6b Iustin Pop
copies of each job (input file) to be submitted (equivalent to
81 75561e6b Iustin Pop
passing the arguments N times) while op-repeat will cause N copies
82 75561e6b Iustin Pop
of each of the opcodes in the file to be executed (equivalent to
83 75561e6b Iustin Pop
each file containing N copies of the opcodes).
84 75561e6b Iustin Pop
85 75561e6b Iustin Pop
TEST-JOBQUEUE
86 75561e6b Iustin Pop
~~~~~~~~~~~~~
87 75561e6b Iustin Pop
88 75561e6b Iustin Pop
**test-jobqueue**
89 75561e6b Iustin Pop
90 75561e6b Iustin Pop
Executes a few tests on the job queue. This command might generate
91 75561e6b Iustin Pop
failed jobs deliberately.
92 75561e6b Iustin Pop
93 75561e6b Iustin Pop
LOCKS
94 75561e6b Iustin Pop
~~~~~
95 75561e6b Iustin Pop
96 75561e6b Iustin Pop
| **locks** [--no-headers] [--separator=*SEPARATOR*]
97 75561e6b Iustin Pop
| [-o *[+]FIELD,...*] [--interval=*SECONDS*]
98 75561e6b Iustin Pop
99 75561e6b Iustin Pop
Shows a list of locks in the master daemon.
100 75561e6b Iustin Pop
101 75561e6b Iustin Pop
The ``--no-headers`` option will skip the initial header line. The
102 75561e6b Iustin Pop
``--separator`` option takes an argument which denotes what will be
103 75561e6b Iustin Pop
used between the output fields. Both these options are to help
104 75561e6b Iustin Pop
scripting.
105 75561e6b Iustin Pop
106 75561e6b Iustin Pop
The ``-o`` option takes a comma-separated list of output fields.
107 75561e6b Iustin Pop
The available fields and their meaning are:
108 75561e6b Iustin Pop
109 75561e6b Iustin Pop
name
110 75561e6b Iustin Pop
    Lock name
111 75561e6b Iustin Pop
112 75561e6b Iustin Pop
mode
113 75561e6b Iustin Pop
    Mode in which the lock is currently acquired (exclusive or shared)
114 75561e6b Iustin Pop
115 75561e6b Iustin Pop
owner
116 75561e6b Iustin Pop
    Current lock owner(s)
117 75561e6b Iustin Pop
118 75561e6b Iustin Pop
pending
119 75561e6b Iustin Pop
    Threads waiting for the lock
120 75561e6b Iustin Pop
121 75561e6b Iustin Pop
122 75561e6b Iustin Pop
If the value of the option starts with the character ``+``, the new
123 75561e6b Iustin Pop
fields will be added to the default list. This allows to quickly
124 75561e6b Iustin Pop
see the default list plus a few other fields, instead of retyping
125 75561e6b Iustin Pop
the entire list of fields.
126 75561e6b Iustin Pop
127 75561e6b Iustin Pop
Use ``--interval`` to repeat the listing. A delay specified by the
128 75561e6b Iustin Pop
option value in seconds is inserted.