-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathapp-pgrecvlogical.html
More file actions
428 lines (424 loc) · 35.4 KB
/
app-pgrecvlogical.html
File metadata and controls
428 lines (424 loc) · 35.4 KB
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
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"><html xmlns="http://www.w3.org/1999/xhtml"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>pg_recvlogical</title><link rel="stylesheet" type="text/css" href="stylesheet.css" /><link rev="made" href="pgsql-docs@lists.postgresql.org" /><meta name="generator" content="DocBook XSL Stylesheets Vsnapshot" /><link rel="prev" href="app-pgreceivewal.html" title="pg_receivewal" /><link rel="next" href="app-pgrestore.html" title="pg_restore" /><meta name="viewport" content="width=device-width,initial-scale=1.0" /></head><body id="docContent" class="container-fluid col-10"><div class="other_version"><a href="https://www.postgresql.jp/document/">バージョンごとのドキュメント一覧</a></div><div class="navheader"><table width="100%" summary="Navigation header"><tr><th colspan="4" align="center"><a accesskey="h" href="index.html">PostgreSQL 18.3文書</a></th></tr><tr><td width="10%" align="left"></td><td width="10%" align="left"></td><td width="60%" align="center"><a href="reference-client.html" title="PostgreSQLクライアントアプリケーション">PostgreSQLクライアントアプリケーション</a></td><td width="20%" align="right"><div class="actions"><a class="issue" title="github" href="https://github.com/pgsql-jp/jpug-doc/issues/new?template=bug_report.yml&what-happened=version 18.3 : app-pgrecvlogical.html">誤訳等の報告
</a></div></td></tr><tr><td width="10%" align="left"><a accesskey="p" href="app-pgreceivewal.html" title="pg_receivewal">前へ</a> </td><td width="10%" align="left"><a accesskey="u" href="reference-client.html" title="PostgreSQLクライアントアプリケーション">上へ</a></td><td width="60%" align="center"><span class="application">pg_recvlogical</span></td><td width="20%" align="right"> <a accesskey="n" href="app-pgrestore.html" title="pg_restore">次へ</a></td></tr></table><hr /></div><div class="refentry" id="APP-PGRECVLOGICAL"><div class="titlepage"></div><a id="id-1.9.4.18.1" class="indexterm"></a><div class="refnamediv"><h2><span class="refentrytitle"><span class="application">pg_recvlogical</span></span></h2><p>pg_recvlogical<span class="original">
<refpurpose>control <productname>PostgreSQL</productname> logical decoding streams</refpurpose>
</span> — <span class="productname">PostgreSQL</span>のストリームのロジカルデコーディングを制御する</p></div><div class="refsynopsisdiv"><h2>概要</h2><div class="cmdsynopsis"><p id="id-1.9.4.18.4.1"><code class="command">pg_recvlogical</code> [<em class="replaceable"><code>option</code></em>...]</p></div></div><div class="refsect1" id="id-1.9.4.18.5"><h2>説明</h2><span class="original">
<title>Description</title>
</span><p>
<span class="original">
<command>pg_recvlogical</command> controls logical decoding replication
slots and streams data from such replication slots.
</span>
<code class="command">pg_recvlogical</code>はレプリケーションスロットのロジカルデコーディングを制御し、またレプリケーションスロットからデータを流します。
</p><p>
<span class="original">
It creates a replication-mode connection, so it is subject to the same
constraints as <xref linkend="app-pgreceivewal"/>, plus those for logical
replication (see <xref linkend="logicaldecoding"/>).
</span>
これはレプリケーションモードの接続をするため、<a class="xref" href="app-pgreceivewal.html" title="pg_receivewal"><span class="refentrytitle"><span class="application">pg_receivewal</span></span></a>と同じ制約に加えて、論理レプリケーション(<a class="xref" href="logicaldecoding.html" title="第47章 ロジカルデコーディング">第47章</a>を参照)と同じ制約も受けます。
</p><p>
<span class="original">
<command>pg_recvlogical</command> has no equivalent to the logical decoding
SQL interface's peek and get modes. It sends replay confirmations for
data lazily as it receives it and on clean exit. To examine pending data on
a slot without consuming it, use
<link linkend="functions-replication"><function>pg_logical_slot_peek_changes</function></link>.
</span>
<code class="command">pg_recvlogical</code>には、ロジカルデコーディングのSQLインタフェースのpeekとgetのモードに対応するものがありません。
データを受信する度、および終了時にダラダラとその再生確認を送信します。
スロット上の未処理のデータを処理せずに検査するには、<a class="link" href="functions-admin.html#FUNCTIONS-REPLICATION" title="9.28.6. レプリケーション管理関数"><code class="function">pg_logical_slot_peek_changes</code></a>を使用してください。
</p><p>
<span class="original">
In the absence of fatal errors, <application>pg_recvlogical</application>
will run until terminated by the <systemitem>SIGINT</systemitem>
(<keycombo action="simul"><keycap>Control</keycap><keycap>C</keycap></keycombo>)
or <systemitem>SIGTERM</systemitem> signal.
</span>
致命的なエラーが無い場合、<span class="application">pg_recvlogical</span>は<span class="systemitem">SIGINT</span>(<span class="keycap"><strong>Control</strong></span>+<span class="keycap"><strong>C</strong></span>)または<span class="systemitem">SIGTERM</span>シグナルで停止されるまで実行を続けます。
</p><p>
<span class="original">
When <application>pg_recvlogical</application> receives
a <systemitem>SIGHUP</systemitem> signal, it closes the current output file
and opens a new one using the filename specified by
the <option>&#45;-file</option> option. This allows us to rotate
the output file by first renaming the current file and then sending
a <systemitem>SIGHUP</systemitem> signal to
<application>pg_recvlogical</application>.
</span>
<span class="application">pg_recvlogical</span>は<span class="systemitem">SIGHUP</span>シグナルを受け取ると、現在の出力ファイルを閉じ、<code class="option">--file</code>オプションで指定されたファイル名を使用して新しいファイルを開きます。
これにより、まず現在の出力ファイルの名前を変更し、その後<span class="application">pg_recvlogical</span>に<span class="systemitem">SIGHUP</span>シグナルを送信することで、出力ファイルをローテーションすることができます。
</p></div><div class="refsect1" id="id-1.9.4.18.6"><h2>オプション</h2><span class="original">
<title>Options</title>
</span><p>
<span class="original">
At least one of the following options must be specified to select an action:
</span>
動作を選択するため、以下のオプションのうち少なくとも1つを指定しなければなりません。
</p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="option">--create-slot</code></span></dt><dd><p>
<span class="original">
Create a new logical replication slot with the name specified by
<option>&#45;-slot</option>, using the output plugin specified by
<option>&#45;-plugin</option>, for the database specified
by <option>&#45;-dbname</option>.
</span>
新しい論理レプリケーションスロットを<code class="option">--slot</code>で指定した名前で、<code class="option">--plugin</code>の出力プラグインを使い、<code class="option">--dbname</code>で指定したデータベースに対して作成します。
</p><p>
<span class="original">
The <option>&#45;-slot</option> and <option>&#45;-dbname</option> are required
for this action.
</span>
このアクションには、<code class="option">--slot</code>と<code class="option">--dbname</code>が必要です。
</p><p>
<span class="original">
The <option>&#45;-enable-two-phase</option> and <option>&#45;-enable-failover</option>
options can be specified with <option>&#45;-create-slot</option>.
</span>
<code class="option">--enable-two-phase</code>および<code class="option">--enable-failover</code>オプションは、<code class="option">--create-slot</code>で指定できます。
</p></dd><dt><span class="term"><code class="option">--drop-slot</code></span></dt><dd><p>
<span class="original">
Drop the replication slot with the name specified
by <option>&#45;-slot</option>, then exit.
</span>
<code class="option">--slot</code>で指定された名前のレプリケーションスロットを削除して、終了します。
</p><p>
<span class="original">
The <option>&#45;-slot</option> is required for this action.
</span>
このアクションには<code class="option">--slot</code>が必要です。
</p></dd><dt><span class="term"><code class="option">--start</code></span></dt><dd><p>
<span class="original">
Begin streaming changes from the logical replication slot specified
by <option>&#45;-slot</option>, continuing until terminated by a
signal. If the server side change stream ends with a server shutdown
or disconnect, retry in a loop unless
<option>&#45;-no-loop</option> is specified.
</span>
<code class="option">--slot</code>で指定した論理レプリケーションスロットからストリームの変更を開始し、シグナルを受けて終了するまで継続します。
サーバ側の変更ストリームがサーバのシャットダウンまたは接続断によって終了した場合は、<code class="option">--no-loop</code>が指定されていなければ、ループ内でリトライします。
</p><p>
<span class="original">
The <option>&#45;-slot</option> and <option>&#45;-dbname</option>,
<option>&#45;-file</option> are required for this action.
</span>
このアクションには、<code class="option">--slot</code>と<code class="option">--dbname</code>、<code class="option">--file</code>が必要です。
</p><p>
<span class="original">
The stream format is determined by the output plugin specified when
the slot was created.
</span>
ストリームのフォーマットは、スロットが作成された時に指定された出力プラグインによって決定されます。
</p><p>
<span class="original">
The connection must be to the same database used to create the slot.
</span>
接続はスロットの作成時に使用したのと同じデータベースに対してでなければなりません。
</p></dd></dl></div><p>
</p><p>
<span class="original">
<option>&#45;-create-slot</option> and <option>&#45;-start</option> can be
specified together. <option>&#45;-drop-slot</option> cannot be combined with
another action.
</span>
<code class="option">--create-slot</code>と<code class="option">--start</code>は同時に指定することができます。
<code class="option">--drop-slot</code>は他の動作と組み合わせることができません。
</p><p>
<span class="original">
The following command-line options control the location and format of the
output and other replication behavior:
</span>
以下のコマンドラインオプションは出力の場所とフォーマット、およびその他のレプリケーションの動作を制御します。
</p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="option">-E <em class="replaceable"><code>lsn</code></em></code><br /></span><span class="term"><code class="option">--endpos=<em class="replaceable"><code>lsn</code></em></code></span></dt><dd><p>
<span class="original">
In <option>&#45;-start</option> mode, automatically stop replication
and exit with normal exit status 0 when receiving reaches the
specified LSN. If specified when not in <option>&#45;-start</option>
mode, an error is raised.
</span>
<code class="option">--start</code>モードでは、自動的にレプリケーションを停止し、受信が指定のLSNに到達したら正常な終了ステータス0で終了します。
<code class="option">--start</code>以外のモードの時に指定された場合は、エラーが発生します。
</p><p>
<span class="original">
If there's a record with LSN exactly equal to <replaceable>lsn</replaceable>,
the record will be output.
</span>
LSNが<em class="replaceable"><code>lsn</code></em>と正確に一致するレコードがある場合、そのレコードは出力されます。
</p><p>
<span class="original">
The <option>&#45;-endpos</option> option is not aware of transaction
boundaries and may truncate output partway through a transaction.
Any partially output transaction will not be consumed and will be
replayed again when the slot is next read from. Individual messages
are never truncated.
</span>
<code class="option">--endpos</code>オプションはトランザクションの境界を意識しないため、トランザクションの途中で出力を切り捨てるかもしれません。
部分的に出力されたトランザクションはいずれも処理されず、スロットが次回、読み込まれた時に再び再生されます。
個々のメッセージが切り捨てられることはありません。
</p></dd><dt><span class="term"><code class="option">--enable-failover</code></span></dt><dd><p>
<span class="original">
Enables the slot to be synchronized to the standbys. This option may
only be specified with <option>&#45;-create-slot</option>.
</span>
スロットをスタンバイと同期できるようにします。
このオプションは<code class="option">--create-slot</code>でのみ指定できます。
</p></dd><dt><span class="term"><code class="option">-f <em class="replaceable"><code>filename</code></em></code><br /></span><span class="term"><code class="option">--file=<em class="replaceable"><code>filename</code></em></code></span></dt><dd><p>
<span class="original">
Write received and decoded transaction data into this
file. Use <literal>-</literal> for <systemitem>stdout</systemitem>.
</span>
受け取り、デコードしたトランザクションデータをこのファイルに書き込みます。
<span class="systemitem">stdout</span>に出力するには<code class="literal">-</code>を使います。
</p><p>
<span class="original">
This parameter is required for <option>&#45;-start</option>.
</span>
このパラメータは<code class="option">--start</code>に必要です。
</p></dd><dt><span class="term"><code class="option">-F <em class="replaceable"><code>interval_seconds</code></em></code><br /></span><span class="term"><code class="option">--fsync-interval=<em class="replaceable"><code>interval_seconds</code></em></code></span></dt><dd><p>
<span class="original">
Specifies how often <application>pg_recvlogical</application> should
issue <function>fsync()</function> calls to ensure the output file is
safely flushed to disk.
</span>
出力ファイルがディスクに安全にフラッシュされることを確実にするため、<span class="application">pg_recvlogical</span>が<code class="function">fsync()</code>の呼び出しを実行する頻度を指定します。
</p><p>
<span class="original">
The server will occasionally request the client to perform a flush and
report the flush position to the server. This setting is in addition
to that, to perform flushes more frequently.
</span>
サーバはクライアントに対して、フラッシュを実行し、またフラッシュ位置をサーバに報告するように、ときどき要求します。
この設定はそれに加えて、フラッシュをより高頻度で実行するものです。
</p><p>
<span class="original">
Specifying an interval of <literal>0</literal> disables
issuing <function>fsync()</function> calls altogether, while still
reporting progress to the server. In this case, data could be lost in
the event of a crash.
</span>
<code class="literal">0</code>という間隔を指定すると、<code class="function">fsync()</code>の呼び出しをまったく実行しなくなりますが、それでも状況をサーバに報告はします。
この場合、クラッシュするとデータが失われるかもしれません。
</p></dd><dt><span class="term"><code class="option">-I <em class="replaceable"><code>lsn</code></em></code><br /></span><span class="term"><code class="option">--startpos=<em class="replaceable"><code>lsn</code></em></code></span></dt><dd><p>
<span class="original">
In <option>&#45;-start</option> mode, start replication from the given
LSN. For details on the effect of this, see the documentation
in <xref linkend="logicaldecoding"/>
and <xref linkend="protocol-replication"/>. Ignored in other modes.
</span>
<code class="option">--start</code>モードでは、レプリケーションを指定のLSNから開始します。
この効果の詳細については<a class="xref" href="logicaldecoding.html" title="第47章 ロジカルデコーディング">第47章</a>および<a class="xref" href="protocol-replication.html" title="54.4. ストリーミングレプリケーションプロトコル">54.4</a>を参照してください。
その他のモードでは無視されます。
</p></dd><dt><span class="term"><code class="option">--if-not-exists</code></span></dt><dd><p>
<span class="original">
Do not error out when <option>&#45;-create-slot</option> is specified
and a slot with the specified name already exists.
</span>
<code class="option">--create-slot</code>が指定され、指定された名前のスロットが既に存在している場合に、エラーを発生させません。
</p></dd><dt><span class="term"><code class="option">-n</code><br /></span><span class="term"><code class="option">--no-loop</code></span></dt><dd><p>
<span class="original">
When the connection to the server is lost, do not retry in a loop, just exit.
</span>
サーバへの接続が失われたとき、ループ内でリトライせず、単に終了します。
</p></dd><dt><span class="term"><code class="option">-o <em class="replaceable"><code>name</code></em>[=<em class="replaceable"><code>value</code></em>]</code><br /></span><span class="term"><code class="option">--option=<em class="replaceable"><code>name</code></em>[=<em class="replaceable"><code>value</code></em>]</code></span></dt><dd><p>
<span class="original">
Pass the option <replaceable>name</replaceable> to the output plugin with,
if specified, the option value <replaceable>value</replaceable>. Which
options exist and their effects depends on the used output plugin.
</span>
オプション<em class="replaceable"><code>name</code></em>と(指定されていれば)オプション値<em class="replaceable"><code>value</code></em>を出力プラグインに渡します。
存在するオプションとその効果は、利用する出力プラグインに依存します。
</p></dd><dt><span class="term"><code class="option">-P <em class="replaceable"><code>plugin</code></em></code><br /></span><span class="term"><code class="option">--plugin=<em class="replaceable"><code>plugin</code></em></code></span></dt><dd><p>
<span class="original">
When creating a slot, use the specified logical decoding output
plugin. See <xref linkend="logicaldecoding"/>. This option has no
effect if the slot already exists.
</span>
スロットを作成するとき、指定されたロジカルデコーディングの出力プラグインを使います。
<a class="xref" href="logicaldecoding.html" title="第47章 ロジカルデコーディング">第47章</a>を参照してください。
このオプションは、スロットが既に存在する時は、何の効果もありません。
</p></dd><dt><span class="term"><code class="option">-s <em class="replaceable"><code>interval_seconds</code></em></code><br /></span><span class="term"><code class="option">--status-interval=<em class="replaceable"><code>interval_seconds</code></em></code></span></dt><dd><p>
<span class="original">
This option has the same effect as the option of the same name
in <xref linkend="app-pgreceivewal"/>. See the description there.
</span>
このオプションは<a class="xref" href="app-pgreceivewal.html" title="pg_receivewal"><span class="refentrytitle"><span class="application">pg_receivewal</span></span></a>の同じ名前のオプションと同じ効果があります。
そちらの説明を参照してください。
</p></dd><dt><span class="term"><code class="option">-S <em class="replaceable"><code>slot_name</code></em></code><br /></span><span class="term"><code class="option">--slot=<em class="replaceable"><code>slot_name</code></em></code></span></dt><dd><p>
<span class="original">
In <option>&#45;-start</option> mode, use the existing logical replication slot named
<replaceable>slot_name</replaceable>. In <option>&#45;-create-slot</option>
mode, create the slot with this name. In <option>&#45;-drop-slot</option>
mode, delete the slot with this name.
</span>
<code class="option">--start</code>モードでは、<em class="replaceable"><code>slot_name</code></em>という名前の既存の論理レプリケーションスロットを使います。
<code class="option">--create-slot</code>では、この名前のスロットを作成します。
<code class="option">--drop-slot</code>モードでは、この名前のスロットを削除します。
</p><p>
<span class="original">
This parameter is required for any of actions.
</span>
どのアクションにもこのパラメータが必要です。
</p></dd><dt><span class="term"><code class="option">-t</code><br /></span><span class="term"><code class="option">--enable-two-phase</code><br /></span><span class="term"><code class="option">--two-phase</code> (deprecated)</span></dt><dd><p>
<span class="original">
Enables decoding of prepared transactions. This option may only be specified with
<option>&#45;-create-slot</option>.
</span>
プリペアドトランザクションのデコードを有効にします。
このオプションは<code class="option">--create-slot</code>でのみ指定できます。
</p></dd><dt><span class="term"><code class="option">-v</code><br /></span><span class="term"><code class="option">--verbose</code></span></dt><dd><p>
<span class="original">
Enables verbose mode.
</span>
冗長モードを有効にします。
</p></dd></dl></div><p>
</p><p>
<span class="original">
The following command-line options control the database connection parameters.
</span>
以下のコマンドラインオプションはデータベース接続パラメータを制御します。
</p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="option">-d <em class="replaceable"><code>dbname</code></em></code><br /></span><span class="term"><code class="option">--dbname=<em class="replaceable"><code>dbname</code></em></code></span></dt><dd><p>
<span class="original">
The database to connect to. See the description
of the actions for what this means in detail.
The <replaceable>dbname</replaceable> can be a <link
linkend="libpq-connstring">connection string</link>. If so,
connection string parameters will override any conflicting
command line options.
</span>
接続するデータベースです。
この意味の詳細は動作の説明を参照してください。
<em class="replaceable"><code>dbname</code></em>は<a class="link" href="libpq-connect.html#LIBPQ-CONNSTRING" title="32.1.1. 接続文字列">接続文字列</a>でも構いません。
その場合、接続文字列パラメータは衝突するコマンドラインオプションよりも優先します。
</p><p>
<span class="original">
This parameter is required for <option>&#45;-create-slot</option>
and <option>&#45;-start</option>.
</span>
このパラメータは<code class="option">--create-slot</code>および<code class="option">--start</code>に必要です。
</p></dd><dt><span class="term"><code class="option">-h <em class="replaceable"><code>hostname-or-ip</code></em></code><br /></span><span class="term"><code class="option">--host=<em class="replaceable"><code>hostname-or-ip</code></em></code></span></dt><dd><p>
<span class="original">
Specifies the host name of the machine on which the server is
running. If the value begins with a slash, it is used as the
directory for the Unix domain socket. The default is taken
from the <envar>PGHOST</envar> environment variable, if set,
else a Unix domain socket connection is attempted.
</span>
サーバが稼働しているマシンのホスト名を指定します。
この値がスラッシュから始まる場合、Unixドメインソケット用のディレクトリとして使用されます。
デフォルトは、設定されていれば環境変数<code class="envar">PGHOST</code>から取得されます。
設定されていなければ、Unixドメインソケット接続とみなされます。
</p></dd><dt><span class="term"><code class="option">-p <em class="replaceable"><code>port</code></em></code><br /></span><span class="term"><code class="option">--port=<em class="replaceable"><code>port</code></em></code></span></dt><dd><p>
<span class="original">
Specifies the TCP port or local Unix domain socket file
extension on which the server is listening for connections.
Defaults to the <envar>PGPORT</envar> environment variable, if
set, or a compiled-in default.
</span>
サーバが接続を監視するTCPポートもしくはローカルUnixドメインソケットファイルの拡張子を指定します。
デフォルトは、設定されている場合、環境変数<code class="envar">PGPORT</code>の値となります。設定されていなければ、コンパイル時のデフォルト値となります。
</p></dd><dt><span class="term"><code class="option">-U <em class="replaceable"><code>user</code></em></code><br /></span><span class="term"><code class="option">--username=<em class="replaceable"><code>user</code></em></code></span></dt><dd><p>
<span class="original">
User name to connect as. Defaults to current operating system user
name.
</span>
接続で使用するユーザ名です。
デフォルトは現在のOSのユーザ名です。
</p></dd><dt><span class="term"><code class="option">-w</code><br /></span><span class="term"><code class="option">--no-password</code></span></dt><dd><p>
<span class="original">
Never issue a password prompt. If the server requires
password authentication and a password is not available by
other means such as a <filename>.pgpass</filename> file, the
connection attempt will fail. This option can be useful in
batch jobs and scripts where no user is present to enter a
password.
</span>
パスワードの入力を促しません。
サーバがパスワード認証を必要とし、かつ、<code class="filename">.pgpass</code>ファイルなどの他の方法が利用できない場合、接続試行は失敗します。
バッチジョブやスクリプトなどパスワードを入力するユーザが存在しない場合にこのオプションは有用かもしれません。
</p></dd><dt><span class="term"><code class="option">-W</code><br /></span><span class="term"><code class="option">--password</code></span></dt><dd><p>
<span class="original">
Force <application>pg_recvlogical</application> to prompt for a
password before connecting to a database.
</span>
<span class="application">pg_recvlogical</span>がデータベースに接続する前に、強制的にパスワード入力を促します。
</p><p>
<span class="original">
This option is never essential, since
<application>pg_recvlogical</application> will automatically prompt
for a password if the server demands password authentication.
However, <application>pg_recvlogical</application> will waste a
connection attempt finding out that the server wants a password.
In some cases it is worth typing <option>-W</option> to avoid the extra
connection attempt.
</span>
サーバがパスワード認証を要求する場合、<span class="application">pg_recvlogical</span>は自動的にパスワード入力を促しますから、このオプションは本質的ではありません。
しかし、サーバがパスワードを必要とすることを確認するために<span class="application">pg_recvlogical</span>が無駄な接続試行を行うことになります。
無駄な接続試行を避けるために<code class="option">-W</code>を指定するのが有効になる場合もあるでしょう。
</p></dd></dl></div><p>
</p><p>
<span class="original">
The following additional options are available:
</span>
この他に、以下のオプションが利用できます。
</p><div class="variablelist"><dl class="variablelist"><dt><span class="term"><code class="option">-V</code><br /></span><span class="term"><code class="option">--version</code></span></dt><dd><p>
<span class="original">
Print the <application>pg_recvlogical</application> version and exit.
</span>
<span class="application">pg_recvlogical</span>のバージョンを出力して、終了します。
</p></dd><dt><span class="term"><code class="option">-?</code><br /></span><span class="term"><code class="option">--help</code></span></dt><dd><p>
<span class="original">
Show help about <application>pg_recvlogical</application> command line
arguments, and exit.
</span>
<span class="application">pg_recvlogical</span>のコマンドライン引数に関するヘルプを表示して、終了します。
</p></dd></dl></div><p>
</p></div><div class="refsect1" id="id-1.9.4.18.7"><h2>終了ステータス</h2><span class="original">
<title>Exit Status</title>
</span><p>
<span class="original">
<application>pg_recvlogical</application> will exit with status 0 when
terminated by the <systemitem>SIGINT</systemitem> or
<systemitem>SIGTERM</systemitem> signal. (That is the
normal way to end it. Hence it is not an error.) For fatal errors or
other signals, the exit status will be nonzero.
</span>
<span class="application">pg_recvlogical</span>は<span class="systemitem">SIGINT</span>または<span class="systemitem">SIGTERM</span>シグナルで停止されたとき、ステータス0で終了します。
(これは止めるための通常の方法です。
そのためエラーではありません。)
致命的エラーや他のシグナルに対しては、終了ステータスは非ゼロになります。
</p></div><div class="refsect1" id="id-1.9.4.18.8"><h2>環境</h2><span class="original">
<title>Environment</title>
</span><p>
<span class="original">
This utility, like most other <productname>PostgreSQL</productname> utilities,
uses the environment variables supported by <application>libpq</application>
(see <xref linkend="libpq-envars"/>).
</span>
このユーティリティは、他のほとんどの<span class="productname">PostgreSQL</span>ユーティリティと同様、<span class="application">libpq</span>でサポートされる環境変数(<a class="xref" href="libpq-envars.html" title="32.15. 環境変数">32.15</a>参照)を使います。
</p><p>
<span class="original">
The environment variable <envar>PG_COLOR</envar> specifies whether to use
color in diagnostic messages. Possible values are
<literal>always</literal>, <literal>auto</literal> and
<literal>never</literal>.
</span>
環境変数<code class="envar">PG_COLOR</code>は診断メッセージで色を使うかどうかを指定します。
指定可能な値は<code class="literal">always</code>、<code class="literal">auto</code>、<code class="literal">never</code>です。
</p></div><div class="refsect1" id="id-1.9.4.18.9"><h2>注釈</h2><span class="original">
<title>Notes</title>
</span><p>
<span class="original">
<application>pg_recvlogical</application> will preserve group permissions on
the received WAL files if group permissions are enabled on the source
cluster.
</span>
<span class="application">pg_recvlogical</span>は、ソースクラスタでグループパーミッションが有効である場合、受け取ったWALファイルのグループパーミッションを維持します。
</p></div><div class="refsect1" id="id-1.9.4.18.10"><h2>例</h2><span class="original">
<title>Examples</title>
</span><p>
<span class="original">
See <xref linkend="logicaldecoding-example"/> for an example.
</span>
例については<a class="xref" href="logicaldecoding-example.html" title="47.1. ロジカルデコーディングの例">47.1</a>を参照してください。
</p></div><div class="refsect1" id="id-1.9.4.18.11"><h2>関連項目</h2><span class="original">
<title>See Also</title>
</span><span class="simplelist"><a class="xref" href="app-pgreceivewal.html" title="pg_receivewal"><span class="refentrytitle"><span class="application">pg_receivewal</span></span></a></span></div></div><div class="navfooter"><hr /><table width="100%" summary="Navigation footer"><tr><td width="40%" align="left"><a accesskey="p" href="app-pgreceivewal.html" title="pg_receivewal">前へ</a> </td><td width="20%" align="center"><a accesskey="u" href="reference-client.html" title="PostgreSQLクライアントアプリケーション">上へ</a></td><td width="40%" align="right"> <a accesskey="n" href="app-pgrestore.html" title="pg_restore">次へ</a></td></tr><tr><td width="40%" align="left" valign="top"><span class="application">pg_receivewal</span> </td><td width="20%" align="center"><a accesskey="h" href="index.html" title="PostgreSQL 18.3文書">ホーム</a></td><td width="40%" align="right" valign="top"> <span class="application">pg_restore</span></td></tr></table></div></body></html>