> For the complete documentation index, see [llms.txt](https://docs.postgresql.tw/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.postgresql.tw/19/server-administration/monitoring/monitoring-stats/monitoring-pg-stat-wal-receiver-view.md). Agents can also search and read this documentation through its [MCP server](https://docs.postgresql.tw/~gitbook/mcp).

# 27.2.6. pg\_stat\_wal\_receiver

## 27.2.6. `pg_stat_wal_receiver` [#](#monitoring-pg-stat-wal-receiver-view) <a href="#monitoring-pg-stat-wal-receiver-view" id="monitoring-pg-stat-wal-receiver-view"></a>

`pg_stat_wal_receiver` 檢視表僅會有 一筆資料列，顯示 WAL 接收程序從其所連線 伺服器接收 WAL 的相關統計資訊。

### 表 27.16. `pg_stat_wal_receiver` 檢視表 [#](#pg-stat-wal-receiver-view) <a href="#pg-stat-wal-receiver-view" id="pg-stat-wal-receiver-view"></a>

| <p>欄位類型</p><p>說明</p>                                                                                                                                                               |
| ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <p><code>pid</code> <code>integer</code></p><p>WAL 接收程序的程序 ID</p>                                                                                                                  |
| <p><code>status</code> <code>text</code></p><p>WAL 接收程序的活動狀態</p>                                                                                                                   |
| <p><code>receive\_start\_lsn</code> <code>pg\_lsn</code></p><p>啟動 WAL 接收程序時所使用的第一個預寫式日誌 位置</p>                                                                                     |
| <p><code>receive\_start\_tli</code> <code>integer</code></p><p>啟動 WAL 接收程序時所使用的第一個時間軸編號</p>                                                                                        |
| <p><code>written\_lsn</code> <code>pg\_lsn</code></p><p>已接收並寫入磁碟，但尚未刷寫的最後一個預寫式日誌位置。 此欄位不應用於資料完整性檢查。</p>                                                                            |
| <p><code>flushed\_lsn</code> <code>pg\_lsn</code></p><p>已接收並刷寫至磁碟的最後一個預寫式日誌位置，此欄位的 初始值為啟動 WAL 接收程序時所使用的第一個日誌位置</p>                                                                 |
| <p><code>received\_tli</code> <code>integer</code></p><p>已接收並刷寫至磁碟之最後一個預寫式日誌位置的時間軸 編號，此欄位的初始值為啟動 WAL 接收程序時所使用第一個日誌位置的 時間軸編號</p>                                                    |
| <p><code>last\_msg\_send\_time</code> <code>timestamp with time zone</code></p><p>從來源 WAL 傳送程序收到最後一則訊息的傳送時間</p>                                                                    |
| <p><code>last\_msg\_receipt\_time</code> <code>timestamp with time zone</code></p><p>從來源 WAL 傳送程序收到最後一則訊息的接收時間</p>                                                                 |
| <p><code>latest\_end\_lsn</code> <code>pg\_lsn</code></p><p>回報給來源 WAL 傳送程序的最後一個預寫式日誌位置</p>                                                                                         |
| <p><code>latest\_end\_time</code> <code>timestamp with time zone</code></p><p>回報給來源 WAL 傳送程序最後一個預寫式日誌位置的時間</p>                                                                     |
| <p><code>slot\_name</code> <code>text</code></p><p>此 WAL 接收程序所使用的複寫插槽名稱</p>                                                                                                        |
| <p><code>sender\_host</code> <code>text</code></p><p>此 WAL 接收程序所連線 PostgreSQL 執行個體的主機。 這可以是主機名稱、IP 位址，或者若透過 Unix socket 連線， 則為目錄路徑。（路徑的情況可以透過它必定是以 <code>/</code> 開頭的絕對路徑來辨別。）</p> |
| <p><code>sender\_port</code> <code>integer</code></p><p>此 WAL 接收程序所連線 PostgreSQL 執行個體的埠號。</p>                                                                                      |
| <p><code>conninfo</code> <code>text</code></p><p>此 WAL 接收程序所使用的連線字串， 其中具安全敏感性的欄位已被模糊化處理。</p>                                                                                       |

<br>

[返回 27.2. 累計統計系統](https://docs.postgresql.tw/19/server-administration/monitoring/monitoring-stats.md#monitoring-stats)

***

原文：[PostgreSQL 18.6 Documentation](https://www.postgresql.org/docs/18/monitoring-stats.html)（原文版本：18.6；核對日期：2026-10-23）


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.postgresql.tw/19/server-administration/monitoring/monitoring-stats/monitoring-pg-stat-wal-receiver-view.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
