summaryrefslogtreecommitdiff
path: root/doc/src/sgml/ref/gtm_ctl.sgml
blob: e78d62e21dcc0014e95080882bd16f5762c43fff (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
<refentry id="APP-GTM-CTL">
 <indexterm zone="app-gtm-ctl">
  <primary>gtm_proxy</primary>
 </indexterm>

 <refmeta>
  <refentrytitle>gtm_ctl</refentrytitle>
  <manvolnum>1</manvolnum>
  <refmiscinfo>Application</refmiscinfo>
 </refmeta>

 <refnamediv>
  <refname>gtm_ctl</refname>
  <refpurpose>
   <productname>Postgres-XL</productname> GTM operation module
  </refpurpose>
 </refnamediv>

 <refsynopsisdiv>
  <cmdsynopsis>
   <command>gtm_proxy</command>
   <arg rep="repeat"><replaceable>option</></arg>
  </cmdsynopsis>
 </refsynopsisdiv>

 <refsect1 id="R1-APP-GTM-CTL-1">
  <title>
   Description
  </title>
  <para>
   <command>gtm_ctl</command> starts/stops <command>gtm</command>
   or <command>gtm_proxy</command>. The options specify the GTM
   configuration.
  </para>

 </refsect1>

 <refsect1>
  <title>Options</title>

  <para>
   Options are specified with preceding '<literal>-</literal>', each
   option may be associated with a value.
  </para>

  <para>
   Options are as follows:
  </para>

  <para>
   <variablelist>
    <varlistentry>
     <term><option>D</option></term>
     <listitem>
      <para>
       Specify a directory which holds data
       for <command>gtm</command> or <command>gtm_proxy</command>
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>l</option></term>
     <listitem>
      <para>
       Specify a log file for <command>gtm_ctl</command>.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>m</option></term>
     <listitem>
      <para>
       Set mode.  Value can
       be <literal>smart</literal>, <literal>fast</literal>
       or <literal>immediate</literal>.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>o</option></term>
     <listitem>
      <para>
       Option method. This parameter will be passed down
       to <command>gtm</command> or <command>gtm_proxy</command>.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>p</option></term>
     <listitem>
      <para>
       Set up postgres bin repository.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>S</option></term>
     <listitem>
      <para>
       Specify which to start, gtm or gtm_proxy. The value can be
       specified as <literal>gtm</literal>
       or <literal>gtm_proxy</literal>.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>t</option></term>
     <listitem>
      <para>
       Specify the wait time in seconds.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>W</option> or <option>w</option></term>
     <listitem>
      <para>
       Wait option.
      </para>
     </listitem>
    </varlistentry>
   </variablelist>
  </para>

  <para>
   <command>gtm_ctl</command> issues the following keywords to select
   operations on <command>gtm</command>
   and <command>gtm_proxy</command>.
  </para>

  <para>
   <variablelist>

    <varlistentry>
     <term><option>start</option></term>
     <listitem>
      <para>
       Start a GTM/GTM proxy instance.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>restart</option></term>
     <listitem>
      <para>
       Restart a GTM/GTM proxy instance.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>stop</option></term>
     <listitem>
      <para>
       Stop a GTM/GTM proxy instance.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>status</option></term>
     <listitem>
      <para>
       Look at the status of GTM instance. If active, 1 is printed. If
       standby, 0 is printed.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>promote</option></term>
     <listitem>
      <para>
       Promote a GTM instance as active.
      </para>
     </listitem>
    </varlistentry>

    <varlistentry>
     <term><option>reconnect</option></term>
     <listitem>
      <para>
       Reconnect a GTM Proxy to another GTM instance.
      </para>
     </listitem>
    </varlistentry>

   </variablelist>
  </para>

  <para>
   Typically, you can issue the following command to start <command>gtm</command>/
<programlisting>
gtm_ctl start -Z gtm -D datafolder
</programlisting>
  </para>

  <para>
   Or <command>gtm_proxy</command>:
<programlisting>
gtm_ctl start -Z gtm_proxy -D datafolder_proxy
</programlisting>
  </para>

  <para>
   Promote a GTM as active:
<programlisting>
gtm_ctl promote -Z gtm -D datafolder
</programlisting>
  </para>

  <para>
   Reconnect a GTM proxy to another GTM instance:
<programlisting>
gtm_ctl reconnect -Z gtm_proxy -D datafolder_proxy -o '-s hostname -t port_number'
</programlisting>
  </para>

  <para>
   Look at the status of a GTM server:
<programlisting>
gtm_ctl status -Z gtm -D datafolder
</programlisting>
  </para>
 </refsect1>

</refentry>