{"kind": "tool", "major": "18", "item": {"slug": "pg-amcheck", "name": "pg_amcheck", "name_zh": "", "category": "\u5ba2\u6237\u7aef\u7a0b\u5e8f", "summary": "pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5", "aliases": ["pg_amcheck"], "content_hash": "8d9dcb240785a3e3ce676aaf68455c8090f0e2fd361d7c7cc0c5e7a42f832604", "versions": {"14": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "14.24"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "35"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/14/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not tables."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not tables."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, not indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/14/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, not indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/14/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/14/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/14/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/14/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/14/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/14/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/14/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/14/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/14/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/14/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/14/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/14/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/14/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/14/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/14/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/14/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/14/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/14/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/14/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/14/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/14/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/14/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/14/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/14/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v14.24/postgresql-14.24.tar.bz2", "label": "14.24", "major": "14", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/14/postgresql-14-A4.pdf", "bytes": 14354704, "pages": 2944, "sha256": "8bc6b9dd7b246888bb77f0a5e8c39a2eae52e9926569832669c7d1600becb27c", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/14/postgresql-14-US.pdf", "bytes": 14242178, "pages": 3102, "sha256": "b7ecb5a5f62d8b9f73a69e25a7d26ba285373bc53168a553bff7b77955506db4", "built_at": "2026-09-26"}}, "tree": "14", "index": "index.html", "major": "14", "pages": 1158, "release": "14.24", "source_url": "https://ftp.postgresql.org/pub/source/v14.24/postgresql-14.24.tar.bz2", "svg_assets": 3, "source_mode": "en HTML verified against the pinned official archive", "source_sha256": "a7fa7ed3d558172355f51406097a7bd4f6b473be80f311ef7cda96bf383d8897"}, "revision": "588700d46356d8837c77c7c0a4e71e645fe6535983b8f1830aa8f2e4e41c40ae", "evidence_kind": "English manual and source declarations", "source_sha256": "a7fa7ed3d558172355f51406097a7bd4f6b473be80f311ef7cda96bf383d8897"}, "sources": [{"url": "https://pg.center/docs/14/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "14.24 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "0c62e3cd367862b7005551386ddfeabcd07a6e27092d2d92e7402edc1bfa31bf", "language": "en", "original_url": "/docs/14/app-pgamcheck.html"}, {"url": "https://pg.center/docs/14/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "5a13567a052954dfe494dfaab9f50919faa1ae56023930fdbb78d45e53feccde", "language": "en", "original_url": "/docs/14/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u8868\u5173\u7cfb\u548c B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/14/libpq.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/14/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/14/libpq.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/14/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/14/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "150d026c1c73aac7ee96d0ca22b3874ef871619f2e848ef528ff7bec884ba2ce", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[7]/h2[0]"]}], "language": "zh", "original_text": {"/versions/14/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/14/facts/0/label": "Documented executable", "/versions/14/facts/1/label": "Executable version", "/versions/14/facts/2/label": "Reference inventory", "/versions/14/facts/2/value": "Client applications", "/versions/14/facts/3/label": "Option definition groups", "/versions/14/tables/0/title": "Documented options", "/versions/14/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/14/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/14/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/14/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/14/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/14/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/14/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/14/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/14/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/14/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/14/tables/0/columns/0/label": "Option and arguments", "/versions/14/tables/0/columns/1/label": "Description", "/versions/14/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/14/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/14/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/14/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/14/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/14/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/14/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/14/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/14/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/14/tables/0/rows/19/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/14/tables/0/rows/20/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/14/tables/0/rows/21/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/14/tables/0/rows/22/summary": "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.", "/versions/14/tables/0/rows/23/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/14/tables/0/rows/24/summary": "User name to connect as.", "/versions/14/tables/0/rows/25/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/14/tables/0/rows/26/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/14/tables/0/rows/27/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/14/tables/0/rows/28/summary": "Echo to stdout all SQL sent to the server.", "/versions/14/tables/0/rows/29/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/14/tables/0/rows/30/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/14/tables/0/rows/31/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/14/tables/0/rows/32/summary": "Print the pg_amcheck version and exit.", "/versions/14/tables/0/rows/33/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/14/tables/0/rows/34/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "3d71c419fd1ff983baf9ab16c7575e88ccdcdf76fce215843fd7cf8c8240e5a2"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not tables."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not tables."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, not indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, not indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "361374d164971080489f57b64bd6a6e884d811351757814d8d269638d1e5222b", "manual_language": "zh"}, "15": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "15.19"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "35"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/15/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/15/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/15/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/15/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/15/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/15/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/15/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/15/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/15/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/15/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/15/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/15/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/15/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/15/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/15/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/15/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/15/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/15/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/15/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/15/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/15/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/15/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/15/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/15/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/15/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/15/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v15.19/postgresql-15.19.tar.bz2", "label": "15.19", "major": "15", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/15/postgresql-15-A4.pdf", "bytes": 14609140, "pages": 2987, "sha256": "66228564a4d16efb47d6a914085716ecfe22ca1566db56bc7c3d82f790646d72", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/15/postgresql-15-US.pdf", "bytes": 14495690, "pages": 3153, "sha256": "645a498c2390d47a6223ec74770631185807a19c484edb0fc5a295d9f460bc02", "built_at": "2026-09-26"}}, "tree": "15", "index": "index.html", "major": "15", "pages": 1168, "release": "15.19", "source_url": "https://ftp.postgresql.org/pub/source/v15.19/postgresql-15.19.tar.bz2", "svg_assets": 3, "source_mode": "en HTML verified against the pinned official archive", "source_sha256": "e1a64a87a46b825b88c082e4518161a47aab53c45694964f8ba1df28f7859f89"}, "revision": "6af958c6520151fc7697d56e0616b03fb00522c4568158674d452ae0644ba545", "evidence_kind": "English manual and source declarations", "source_sha256": "e1a64a87a46b825b88c082e4518161a47aab53c45694964f8ba1df28f7859f89"}, "sources": [{"url": "https://pg.center/docs/15/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "15.19 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "e4088bca51857c5e042b980ed116ea580a26fa1ba687ddd817ad892333d199de", "language": "en", "original_url": "/docs/15/app-pgamcheck.html"}, {"url": "https://pg.center/docs/15/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "015b2ea2bd205946a55a1b837e735570631bac831c92074a6bf58444f9a3cb98", "language": "en", "original_url": "/docs/15/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/15/libpq.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/15/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/15/libpq.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/15/amcheck.html\" title=\"F.2.\u00a0amcheck\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/15/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "212c1a9db7423e7c4d3a1f35ca502cdd56076fa0fdc605b64b7545cc1ec18e5f", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[7]/h2[0]"]}], "language": "zh", "original_text": {"/versions/15/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/15/facts/0/label": "Documented executable", "/versions/15/facts/1/label": "Executable version", "/versions/15/facts/2/label": "Reference inventory", "/versions/15/facts/2/value": "Client applications", "/versions/15/facts/3/label": "Option definition groups", "/versions/15/tables/0/title": "Documented options", "/versions/15/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/15/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/15/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/15/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/15/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/15/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/15/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/15/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/15/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/15/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/15/tables/0/columns/0/label": "Option and arguments", "/versions/15/tables/0/columns/1/label": "Description", "/versions/15/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/15/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/15/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/15/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/15/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/15/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/15/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/15/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/15/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/15/tables/0/rows/19/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/15/tables/0/rows/20/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/15/tables/0/rows/21/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/15/tables/0/rows/22/summary": "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.", "/versions/15/tables/0/rows/23/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/15/tables/0/rows/24/summary": "User name to connect as.", "/versions/15/tables/0/rows/25/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/15/tables/0/rows/26/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/15/tables/0/rows/27/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/15/tables/0/rows/28/summary": "Echo to stdout all SQL sent to the server.", "/versions/15/tables/0/rows/29/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/15/tables/0/rows/30/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/15/tables/0/rows/31/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/15/tables/0/rows/32/summary": "Print the pg_amcheck version and exit.", "/versions/15/tables/0/rows/33/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/15/tables/0/rows/34/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "6cb4500e4bb53f0d2bf5704abaf6d1af11f903c8682d1a5df97810f395caf4cf"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "27fb7b188a266efb8574a81e72c1b428521ad8791ecacdbdd7d7221e5e1cf058", "manual_language": "zh"}, "16": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "16.15"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "35"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/16/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/16/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/16/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/16/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/16/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/16/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/16/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/16/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/16/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/16/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/16/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/16/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/16/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/16/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/16/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/16/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/16/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/16/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/16/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/16/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/16/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/16/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/16/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/16/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/16/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/16/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v16.15/postgresql-16.15.tar.bz2", "label": "16.15", "major": "16", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/16/postgresql-16-A4.pdf", "bytes": 15282337, "pages": 3055, "sha256": "4bb6c1f63deedac98736d8c4c7bc0fad0ac24e85b07e21ee10411872f06afd06", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/16/postgresql-16-US.pdf", "bytes": 15164148, "pages": 3220, "sha256": "5b6b6166c89991199e144bb0ae34c17a5f29826251dbf19db1abc0df3a3e771b", "built_at": "2026-09-26"}}, "tree": "16", "index": "index.html", "major": "16", "pages": 1169, "release": "16.15", "source_url": "https://ftp.postgresql.org/pub/source/v16.15/postgresql-16.15.tar.bz2", "svg_assets": 3, "source_mode": "en HTML verified against the pinned official archive", "source_sha256": "c1575341fa7bd40f5274ea465b34390f4dc64cdd0770af327005caaeb9f6b7ed"}, "revision": "3c21e58b35318021716440e67bb8bafd392b6a2b965a244d90e9e33c99e0bdef", "evidence_kind": "English manual and source declarations", "source_sha256": "c1575341fa7bd40f5274ea465b34390f4dc64cdd0770af327005caaeb9f6b7ed"}, "sources": [{"url": "https://pg.center/docs/16/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "16.15 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "33a8078855a33639b6ba7d792447c2626332a9dcd47c6592ad824994b21dfbe7", "language": "en", "original_url": "/docs/16/app-pgamcheck.html"}, {"url": "https://pg.center/docs/16/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "a28c30c3c0f8783e16d56413a0b6fd39487e336da1683b29b60abf1c229cef26", "language": "en", "original_url": "/docs/16/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/16/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/16/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/16/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"34.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/16/amcheck.html\" title=\"F.2.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/16/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "bd575e2b9f38e32dfee023df5e31c4e1b2cb39351424dd3039af57db8b5c9e20", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[7]/h2[0]"]}], "language": "zh", "original_text": {"/versions/16/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/16/facts/0/label": "Documented executable", "/versions/16/facts/1/label": "Executable version", "/versions/16/facts/2/label": "Reference inventory", "/versions/16/facts/2/value": "Client applications", "/versions/16/facts/3/label": "Option definition groups", "/versions/16/tables/0/title": "Documented options", "/versions/16/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/16/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/16/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/16/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/16/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/16/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/16/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/16/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/16/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/16/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/16/tables/0/columns/0/label": "Option and arguments", "/versions/16/tables/0/columns/1/label": "Description", "/versions/16/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/16/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/16/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/16/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/16/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/16/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/16/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/16/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/16/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/16/tables/0/rows/19/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/16/tables/0/rows/20/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/16/tables/0/rows/21/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/16/tables/0/rows/22/summary": "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.", "/versions/16/tables/0/rows/23/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/16/tables/0/rows/24/summary": "User name to connect as.", "/versions/16/tables/0/rows/25/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/16/tables/0/rows/26/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/16/tables/0/rows/27/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/16/tables/0/rows/28/summary": "Echo to stdout all SQL sent to the server.", "/versions/16/tables/0/rows/29/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/16/tables/0/rows/30/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/16/tables/0/rows/31/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/16/tables/0/rows/32/summary": "Print the pg_amcheck version and exit.", "/versions/16/tables/0/rows/33/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/16/tables/0/rows/34/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "2ce1b032ac480e148175b8414e5f87a93baf12b88e80f61fef7b0b0ffc081fe7"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "27fb7b188a266efb8574a81e72c1b428521ad8791ecacdbdd7d7221e5e1cf058", "manual_language": "zh"}, "17": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "17.11"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "36"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 checkunique \u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--checkunique"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/17/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/17/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/17/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/17/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/17/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/17/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/17/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/17/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/17/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/17/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "signature": "--checkunique", "source_url": "/docs/17/app-pgamcheck.html", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/17/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/17/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/17/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/17/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/17/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/17/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/17/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/17/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/17/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/17/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/17/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/17/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/17/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/17/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/17/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/17/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v17.11/postgresql-17.11.tar.bz2", "label": "17.11", "major": "17", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/17/postgresql-17-A4.pdf", "bytes": 15521293, "pages": 3099, "sha256": "1991354df0dc89e70ec39328c28988ef8b19c6a93671dab3893650b63e9f4e36", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/17/postgresql-17-US.pdf", "bytes": 15398150, "pages": 3270, "sha256": "07696c8f38abf31babf22d2db337093936e7c472d2af36d050b000c49bbcf52c", "built_at": "2026-09-26"}}, "tree": "17", "index": "index.html", "major": "17", "pages": 1143, "release": "17.11", "source_url": "https://ftp.postgresql.org/pub/source/v17.11/postgresql-17.11.tar.bz2", "svg_assets": 3, "source_mode": "en SGML built with pinned official archive", "source_sha256": "dd27f2b3c59e73ed14aa3324901242bf69a032a6347805f274e6260322d42979"}, "revision": "58419c9b0dd42cb34c8d53695bb025a7e582edf55ccd4c5bcb1c2c7c71a37487", "evidence_kind": "English manual and source declarations", "source_sha256": "dd27f2b3c59e73ed14aa3324901242bf69a032a6347805f274e6260322d42979"}, "sources": [{"url": "https://pg.center/docs/17/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "17.11 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "7f6ac93be2812870a23b8686c1865278c1bb7d81bad638b2bc975b9b23ecb4ff", "language": "en", "original_url": "/docs/17/app-pgamcheck.html"}, {"url": "https://pg.center/docs/17/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "3194fc72ddad8e2fcba55f8e007f83413cb352146cb65aaa9457a18d0314ee1b", "language": "en", "original_url": "/docs/17/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/17/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/17/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--checkunique</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">checkunique</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/17/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u73af\u5883</h2>\n<p lang=\"zh\">\u4e0e\u5927\u591a\u6570\u5176\u4ed6<span class=\"productname\">PostgreSQL</span>\u5de5\u5177\u4e00\u6837\uff0c<code class=\"command\">pg_amcheck</code>\u4e5f\u4f7f\u7528<span class=\"application\">libpq</span>\u652f\u6301\u7684\u73af\u5883\u53d8\u91cf\uff08\u89c1<a class=\"xref\" href=\"/docs/17/libpq-envars.html\" title=\"32.15.\u00a0\u73af\u5883\u53d8\u91cf\">\u7b2c\u00a032.15\u00a0\u8282</a>\uff09\u3002</p>\n<p lang=\"zh\">\u73af\u5883\u53d8\u91cf<code class=\"envar\">PG_COLOR</code>\u6307\u5b9a\u662f\u5426\u5728\u8bca\u65ad\u6d88\u606f\u4e2d\u4f7f\u7528\u989c\u8272\u3002\u53ef\u80fd\u7684\u503c\u4e3a<code class=\"literal\">always</code>\u3001<code class=\"literal\">auto</code>\u548c<code class=\"literal\">never</code>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.9\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/17/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/17/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "366471b76a3d3c3c5fa670a5dbfae1efcf6045b9611ca6a76f51c3b178018651", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[6]/p[2]", "#APP-PGAMCHECK/div[7]/h2[0]", "#APP-PGAMCHECK/div[7]/p[1]", "#APP-PGAMCHECK/div[8]/h2[0]"]}], "language": "zh", "original_text": {"/versions/17/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/17/facts/0/label": "Documented executable", "/versions/17/facts/1/label": "Executable version", "/versions/17/facts/2/label": "Reference inventory", "/versions/17/facts/2/value": "Client applications", "/versions/17/facts/3/label": "Option definition groups", "/versions/17/tables/0/title": "Documented options", "/versions/17/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/17/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/17/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/17/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/17/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/17/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/17/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/17/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/17/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/17/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/17/tables/0/columns/0/label": "Option and arguments", "/versions/17/tables/0/columns/1/label": "Description", "/versions/17/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/17/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/17/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/17/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/17/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/17/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/17/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/17/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/17/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/17/tables/0/rows/19/summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "/versions/17/tables/0/rows/20/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/17/tables/0/rows/21/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/17/tables/0/rows/22/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/17/tables/0/rows/23/summary": "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.", "/versions/17/tables/0/rows/24/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/17/tables/0/rows/25/summary": "User name to connect as.", "/versions/17/tables/0/rows/26/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/17/tables/0/rows/27/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/17/tables/0/rows/28/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/17/tables/0/rows/29/summary": "Echo to stdout all SQL sent to the server.", "/versions/17/tables/0/rows/30/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/17/tables/0/rows/31/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/17/tables/0/rows/32/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/17/tables/0/rows/33/summary": "Print the pg_amcheck version and exit.", "/versions/17/tables/0/rows/34/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/17/tables/0/rows/35/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "f5a4f734695b6551e2f001a20dd45909ed6ceb2538060f07f324c478a9dcdcae"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "signature": "--checkunique", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "e007a3ce54383d588583bd426bfaa62aba42504ba26ff80ad24c0c65d13af539", "manual_language": "zh"}, "18": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "18.6"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "36"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 checkunique \u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--checkunique"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/18/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/18/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/18/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/18/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "signature": "--checkunique", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/18/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/18/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/18/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/18/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/18/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/18/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/18/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/18/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/18/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/18/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/18/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/18/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/18/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "label": "18.6", "major": "18", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/18/postgresql-18-A4.pdf", "bytes": 15865106, "pages": 3154, "sha256": "19512c405da53f9f7fcf0abba359223aa65f021be025bf3411381918f92e3190", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/18/postgresql-18-US.pdf", "bytes": 15748059, "pages": 3328, "sha256": "facbe6c229e598b872d3d98bef53308f46e06746006fa4590de9a7de9dd46319", "built_at": "2026-09-26"}}, "tree": "18", "index": "index.html", "major": "18", "pages": 1148, "release": "18.6", "source_url": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "svg_assets": 3, "source_mode": "en SGML built with pinned official archive", "source_sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}, "revision": "ee8d1a3612338fd9adf250730cb640fcc5233b5491337cc00a316a44e3a0b9f8", "evidence_kind": "English manual and source declarations", "source_sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}, "sources": [{"url": "https://pg.center/docs/18/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "18.6 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "e27a4203de24586f422047021fddd4cd69bbe0093c3949ac283091329050c9f5", "language": "en", "original_url": "/docs/18/app-pgamcheck.html"}, {"url": "https://pg.center/docs/18/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "68f726af77272fe73a827be2b7b5958d0f2239a6f8ed44264e9d42496bfa4fd0", "language": "en", "original_url": "/docs/18/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/18/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--checkunique</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">checkunique</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/18/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u73af\u5883</h2>\n<p lang=\"zh\">\u4e0e\u5927\u591a\u6570\u5176\u4ed6<span class=\"productname\">PostgreSQL</span>\u5de5\u5177\u4e00\u6837\uff0c<code class=\"command\">pg_amcheck</code>\u4e5f\u4f7f\u7528<span class=\"application\">libpq</span>\u652f\u6301\u7684\u73af\u5883\u53d8\u91cf\uff08\u89c1<a class=\"xref\" href=\"/docs/18/libpq-envars.html\" title=\"32.15.\u00a0\u73af\u5883\u53d8\u91cf\">\u7b2c\u00a032.15\u00a0\u8282</a>\uff09\u3002</p>\n<p lang=\"zh\">\u73af\u5883\u53d8\u91cf<code class=\"envar\">PG_COLOR</code>\u6307\u5b9a\u662f\u5426\u5728\u8bca\u65ad\u6d88\u606f\u4e2d\u4f7f\u7528\u989c\u8272\u3002\u53ef\u80fd\u7684\u503c\u4e3a<code class=\"literal\">always</code>\u3001<code class=\"literal\">auto</code>\u548c<code class=\"literal\">never</code>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.9\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/18/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "4ef0217b2d2d6a134807e864ad8a89f508a45f3dbe0fedc17672fe01f3e70c15", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[6]/p[2]", "#APP-PGAMCHECK/div[7]/h2[0]", "#APP-PGAMCHECK/div[7]/p[1]", "#APP-PGAMCHECK/div[8]/h2[0]"]}], "language": "zh", "original_text": {"/versions/18/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/18/facts/0/label": "Documented executable", "/versions/18/facts/1/label": "Executable version", "/versions/18/facts/2/label": "Reference inventory", "/versions/18/facts/2/value": "Client applications", "/versions/18/facts/3/label": "Option definition groups", "/versions/18/tables/0/title": "Documented options", "/versions/18/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/18/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/18/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/columns/0/label": "Option and arguments", "/versions/18/tables/0/columns/1/label": "Description", "/versions/18/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/18/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/18/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/18/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/18/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/18/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/18/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/18/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/18/tables/0/rows/19/summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "/versions/18/tables/0/rows/20/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/18/tables/0/rows/21/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/18/tables/0/rows/22/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/18/tables/0/rows/23/summary": "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.", "/versions/18/tables/0/rows/24/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/18/tables/0/rows/25/summary": "User name to connect as.", "/versions/18/tables/0/rows/26/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/18/tables/0/rows/27/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/18/tables/0/rows/28/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/18/tables/0/rows/29/summary": "Echo to stdout all SQL sent to the server.", "/versions/18/tables/0/rows/30/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/18/tables/0/rows/31/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/18/tables/0/rows/32/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/18/tables/0/rows/33/summary": "Print the pg_amcheck version and exit.", "/versions/18/tables/0/rows/34/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/18/tables/0/rows/35/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "a943e71dc285dd06caa6f3e90388eabc0d46350d861ded5ea35464934ef7c5d5"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "signature": "--checkunique", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "e007a3ce54383d588583bd426bfaa62aba42504ba26ff80ad24c0c65d13af539", "manual_language": "zh"}, "19": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "19beta4"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "36"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 checkunique \u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--checkunique"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/19/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/19/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/19/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/19/app-pgamcheck.html", "description": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/19/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/19/app-pgamcheck.html", "description": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/19/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/19/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/19/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/19/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "signature": "--checkunique", "source_url": "/docs/19/app-pgamcheck.html", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/19/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/19/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/19/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/19/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/19/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/19/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/19/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/19/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/19/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/19/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/19/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/19/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/19/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/19/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/19/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/19/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v19beta4/postgresql-19beta4.tar.bz2", "label": "19beta4", "major": "19", "channel": "preview", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/19/postgresql-19-A4.pdf", "bytes": 16064841, "pages": 3052, "sha256": "4dd099e4125c591128fc5f3ebd02178dc24781f9e5ae629f96d67c4c8547427b", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/19/postgresql-19-US.pdf", "bytes": 15974616, "pages": 3225, "sha256": "61971fa857f0956d47341a0388fa6af9ae10acf691d4b2fc009007d384b0342b", "built_at": "2026-09-26"}}, "tree": "19", "index": "index.html", "major": "19", "pages": 1155, "release": "19beta4", "source_url": "https://ftp.postgresql.org/pub/source/v19beta4/postgresql-19beta4.tar.bz2", "svg_assets": 5, "source_mode": "en SGML built with pinned official archive", "source_sha256": "83157ee9c599d03b2f7a3d73ef3a56ec24e0e79cc2b3501a64d1364f56398c86"}, "revision": "1bbbbf4133d426f0e4304010688d2984c30fb67df0cc3a61b3e37eb3f6f37833", "evidence_kind": "English manual and source declarations", "source_sha256": "83157ee9c599d03b2f7a3d73ef3a56ec24e0e79cc2b3501a64d1364f56398c86"}, "sources": [{"url": "https://pg.center/docs/19/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "19beta4 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "7badce507561ff8d1e103126b9c6be4c490212a82057791a74532e5e17345d89", "language": "en", "original_url": "/docs/19/app-pgamcheck.html"}, {"url": "https://pg.center/docs/19/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "c827f460db781b39da305303c88e73729a419cd2b2b9dedb126d8ad5cbf02c95", "language": "en", "original_url": "/docs/19/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/19/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/19/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"option\">--index</code>\u6216<code class=\"option\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"option\">--table</code>\u6216<code class=\"option\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--checkunique</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">checkunique</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/19/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u73af\u5883</h2>\n<p lang=\"zh\">\u4e0e\u5927\u591a\u6570\u5176\u4ed6<span class=\"productname\">PostgreSQL</span>\u5de5\u5177\u4e00\u6837\uff0c<code class=\"command\">pg_amcheck</code>\u4e5f\u4f7f\u7528<span class=\"application\">libpq</span>\u652f\u6301\u7684\u73af\u5883\u53d8\u91cf\uff08\u89c1<a class=\"xref\" href=\"/docs/19/libpq-envars.html\" title=\"32.15.\u00a0\u73af\u5883\u53d8\u91cf\">\u7b2c\u00a032.15\u00a0\u8282</a>\uff09\u3002</p>\n<p lang=\"zh\">\u73af\u5883\u53d8\u91cf<code class=\"envar\">PG_COLOR</code>\u6307\u5b9a\u662f\u5426\u5728\u8bca\u65ad\u6d88\u606f\u4e2d\u4f7f\u7528\u989c\u8272\u3002\u53ef\u80fd\u7684\u503c\u4e3a<code class=\"literal\">always</code>\u3001<code class=\"literal\">auto</code>\u548c<code class=\"literal\">never</code>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.9\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/19/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/19/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "d297e74f82474f4026e39e0f595f27013b2b2e1affeacb629ba873715943997b", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[6]/p[2]", "#APP-PGAMCHECK/div[7]/h2[0]", "#APP-PGAMCHECK/div[7]/p[1]", "#APP-PGAMCHECK/div[8]/h2[0]"]}], "language": "zh", "original_text": {"/versions/19/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/19/facts/0/label": "Documented executable", "/versions/19/facts/1/label": "Executable version", "/versions/19/facts/2/label": "Reference inventory", "/versions/19/facts/2/value": "Client applications", "/versions/19/facts/3/label": "Option definition groups", "/versions/19/tables/0/title": "Documented options", "/versions/19/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/19/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/19/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/19/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/19/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/19/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/19/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/19/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/19/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/19/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/19/tables/0/columns/0/label": "Option and arguments", "/versions/19/tables/0/columns/1/label": "Description", "/versions/19/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/19/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/19/tables/0/rows/12/summary": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/19/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/19/tables/0/rows/14/summary": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them.", "/versions/19/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/19/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/19/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/19/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/19/tables/0/rows/19/summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "/versions/19/tables/0/rows/20/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/19/tables/0/rows/21/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/19/tables/0/rows/22/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/19/tables/0/rows/23/summary": "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.", "/versions/19/tables/0/rows/24/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/19/tables/0/rows/25/summary": "User name to connect as.", "/versions/19/tables/0/rows/26/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/19/tables/0/rows/27/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/19/tables/0/rows/28/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/19/tables/0/rows/29/summary": "Echo to stdout all SQL sent to the server.", "/versions/19/tables/0/rows/30/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/19/tables/0/rows/31/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/19/tables/0/rows/32/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/19/tables/0/rows/33/summary": "Print the pg_amcheck version and exit.", "/versions/19/tables/0/rows/34/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/19/tables/0/rows/35/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "9bbb6349580fea82bcb8aafc597e05e9a656c88992e4397bc966323efe2d6688"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "signature": "--checkunique", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "1b5d8dc89b45637c0e8cd1b5f25a6ec2793afeadec9edeae24cdb512794aa018", "manual_language": "zh"}, "20": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "20devel"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "36"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 checkunique \u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--checkunique"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/devel/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/devel/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/devel/app-pgamcheck.html", "description": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/devel/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/devel/app-pgamcheck.html", "description": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/devel/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/devel/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/devel/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "signature": "--checkunique", "source_url": "/docs/devel/app-pgamcheck.html", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/devel/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/devel/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/devel/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/devel/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/devel/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/devel/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/snapshot/dev/postgresql-snapshot.tar.bz2", "label": "20devel", "major": "20", "channel": "devel", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/20/postgresql-20-A4.pdf", "bytes": 16030631, "pages": 3052, "sha256": "bd5d82c0ce38fc18f92a0447818a91a193a261776bca1c37564bf9a683e177d0", "built_at": "2026-09-28"}, "US": {"url": "/files/documentation/pdf/20/postgresql-20-US.pdf", "bytes": 15936613, "pages": 3223, "sha256": "d97d9e0db479a02f4234b175f50fcad70c3661619afc8d6df9b9437882e3c299", "built_at": "2026-09-28"}}, "tree": "0", "index": "index.html", "major": "20", "pages": 1156, "release": "20devel", "source_url": "https://ftp.postgresql.org/pub/snapshot/dev/postgresql-snapshot.tar.bz2", "svg_assets": 6, "source_mode": "en SGML built with pinned official archive", "source_sha256": "4d3346909b201ac1648232cf290462a7070c119326f56196f1f0253ed80fae41", "source_snapshot_utc": "26-Sep-2026 20:22"}, "revision": "2eba5e0fd4c3bffb2803247b6cd537878e9d6ee5a6dfbe3c50ece8b421b80918", "evidence_kind": "English manual and source declarations", "source_sha256": "4d3346909b201ac1648232cf290462a7070c119326f56196f1f0253ed80fae41"}, "sources": [{"url": "https://pg.center/docs/devel/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "20devel English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "d0a3048d2f2b5bc6372d4cb4117e971acfd47db75ef5e8b990e670f1a34856de", "language": "en", "original_url": "/docs/devel/app-pgamcheck.html"}, {"url": "https://pg.center/docs/devel/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "a6c7ba748fa1d9feac5bb7cde41d1d36a1f4c26d5963e07fb103d02918b2a8ca", "language": "en", "original_url": "/docs/devel/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/devel/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/devel/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"option\">--index</code>\u6216<code class=\"option\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"option\">--table</code>\u6216<code class=\"option\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--checkunique</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">checkunique</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/devel/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u73af\u5883</h2>\n<p lang=\"zh\">\u4e0e\u5927\u591a\u6570\u5176\u4ed6<span class=\"productname\">PostgreSQL</span>\u5de5\u5177\u4e00\u6837\uff0c<code class=\"command\">pg_amcheck</code>\u4e5f\u4f7f\u7528<span class=\"application\">libpq</span>\u652f\u6301\u7684\u73af\u5883\u53d8\u91cf\uff08\u89c1<a class=\"xref\" href=\"/docs/devel/libpq-envars.html\" title=\"32.14.\u00a0\u73af\u5883\u53d8\u91cf\">\u7b2c\u00a032.14\u00a0\u8282</a>\uff09\u3002</p>\n<p lang=\"zh\">\u73af\u5883\u53d8\u91cf<code class=\"envar\">PG_COLOR</code>\u6307\u5b9a\u662f\u5426\u5728\u8bca\u65ad\u6d88\u606f\u4e2d\u4f7f\u7528\u989c\u8272\u3002\u53ef\u80fd\u7684\u503c\u4e3a<code class=\"literal\">always</code>\u3001<code class=\"literal\">auto</code>\u548c<code class=\"literal\">never</code>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.9\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/devel/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/devel/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "5e77d77ced4c9bfc164e120c8988d02cc350c6ae3a40940f44686c6a872e74d5", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[6]/p[2]", "#APP-PGAMCHECK/div[7]/h2[0]", "#APP-PGAMCHECK/div[7]/p[1]", "#APP-PGAMCHECK/div[8]/h2[0]"]}], "language": "zh", "original_text": {"/summary": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/category": "Client applications", "/versions/20/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/20/facts/0/label": "Documented executable", "/versions/20/facts/1/label": "Executable version", "/versions/20/facts/2/label": "Reference inventory", "/versions/20/facts/2/value": "Client applications", "/versions/20/facts/3/label": "Option definition groups", "/versions/20/tables/0/title": "Documented options", "/versions/20/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/20/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/20/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/20/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/20/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/20/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/20/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/20/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/20/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/20/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/20/tables/0/columns/0/label": "Option and arguments", "/versions/20/tables/0/columns/1/label": "Description", "/versions/20/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/20/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/20/tables/0/rows/12/summary": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/20/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/20/tables/0/rows/14/summary": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them.", "/versions/20/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/20/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/20/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/20/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/20/tables/0/rows/19/summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "/versions/20/tables/0/rows/20/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/20/tables/0/rows/21/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/20/tables/0/rows/22/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/20/tables/0/rows/23/summary": "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.", "/versions/20/tables/0/rows/24/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/20/tables/0/rows/25/summary": "User name to connect as.", "/versions/20/tables/0/rows/26/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/20/tables/0/rows/27/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/20/tables/0/rows/28/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/20/tables/0/rows/29/summary": "Echo to stdout all SQL sent to the server.", "/versions/20/tables/0/rows/30/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/20/tables/0/rows/31/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/20/tables/0/rows/32/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/20/tables/0/rows/33/summary": "Print the pg_amcheck version and exit.", "/versions/20/tables/0/rows/34/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/20/tables/0/rows/35/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "24ed84f6294b1953763452b53c633405df2c4c25b1e9342454b4986d62d30284"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its TOAST table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a TOAST pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the TOAST table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a TOAST table are checked, this option will apply to both, but higher-numbered TOAST blocks may still be accessed while validating TOAST pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "signature": "--checkunique", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "1b5d8dc89b45637c0e8cd1b5f25a6ec2793afeadec9edeae24cdb512794aa018", "manual_language": "zh"}}}, "snapshot": {"facts": [{"label": "\u624b\u518c\u4e2d\u7684\u53ef\u6267\u884c\u7a0b\u5e8f", "value": "pg_amcheck"}, {"label": "\u7a0b\u5e8f\u7248\u672c", "value": "18.6"}, {"label": "\u53c2\u8003\u6e05\u5355", "value": "\u5ba2\u6237\u7aef\u7a0b\u5e8f"}, {"label": "\u9009\u9879\u5b9a\u4e49\u7ec4", "value": "36"}], "tables": [{"key": "options", "rows": [{"summary": "\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-a --all"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7 --exclude-database \u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-d pattern --database= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-D pattern --exclude-database= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-i pattern --index= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-I pattern --exclude-index= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-r pattern --relation= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-R pattern --exclude-relation= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-s pattern --schema= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-S pattern --exclude-schema= pattern"}}, {"summary": "\u68c0\u67e5\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-t pattern --table= pattern"}}, {"summary": "\u6392\u9664\u5339\u914d\u6307\u5b9a pattern \u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-T pattern --exclude-table= pattern"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7 --index \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-dependent-indexes"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7 --table \u6216 --relation \u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-dependent-toast"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c --database \u3001 --table \u3001 --index \u6216 --relation \u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--no-strict-names"}}, {"summary": "\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--exclude-toast-pointers"}}, {"summary": "\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--on-error-stop"}}, {"summary": "\u5982\u679c\u7ed9\u5b9a all-frozen \uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--skip= option"}}, {"summary": "\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1 --endblock \u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--startblock= block"}}, {"summary": "\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528 --exclude-toast-pointers \u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--endblock= block"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 checkunique \u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--checkunique"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 heapallindexed \u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--heapallindexed"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 bt_index_parent_check \u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--parent-check"}}, {"summary": "\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528 amcheck \u7684 rootdescend \u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--rootdescend"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-h hostname --host= hostname"}}, {"summary": "\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-p port --port= port"}}, {"summary": "\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-U --username= username"}}, {"summary": "\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7 .pgpass \u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-w --no-password"}}, {"summary": "\u5f3a\u5236 pg_amcheck \u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-W --password"}}, {"summary": "\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216 \u8fde\u63a5\u5b57\u7b26\u4e32 \uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528 --all \uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a postgres \uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a template1 \u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--maintenance-db= dbname"}}, {"summary": "\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-e --echo"}}, {"summary": "\u4f7f\u7528 num \u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-j num --jobs= num"}}, {"summary": "\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-P --progress"}}, {"summary": "\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-v --verbose"}}, {"summary": "\u6253\u5370 pg_amcheck \u7248\u672c\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-V --version"}}, {"summary": "\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684 schema \u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230 pg_catalog \u6a21\u5f0f\u4e2d\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "--install-missing --install-missing= schema"}}, {"summary": "\u663e\u793a pg_amcheck \u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002", "signature": {"url": "/docs/18/app-pgamcheck.html", "text": "-? --help"}}], "title": "\u624b\u518c\u4e2d\u7684\u9009\u9879", "columns": [{"key": "signature", "label": "\u9009\u9879\u4e0e\u53c2\u6570"}, {"key": "summary", "label": "\u8bf4\u660e"}]}], "options": [{"names": ["-a", "--all"], "summary": "Check all databases, except for any excluded via --exclude-database .", "signature": "-a --all", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "signature": "-d pattern --database= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "signature": "-D pattern --exclude-database= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-i pattern --index= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "signature": "-I pattern --exclude-index= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-r pattern --relation= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "signature": "-R pattern --exclude-relation= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-s pattern --schema= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "signature": "-S pattern --exclude-schema= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "signature": "-t pattern --table= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "signature": "-T pattern --exclude-table= pattern", "source_url": "/docs/18/app-pgamcheck.html", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "signature": "--no-dependent-indexes", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "signature": "--no-dependent-toast", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "signature": "--no-strict-names", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "signature": "--exclude-toast-pointers", "source_url": "/docs/18/app-pgamcheck.html", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "signature": "--on-error-stop", "source_url": "/docs/18/app-pgamcheck.html", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "signature": "--skip= option", "source_url": "/docs/18/app-pgamcheck.html", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "signature": "--startblock= block", "source_url": "/docs/18/app-pgamcheck.html", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "signature": "--endblock= block", "source_url": "/docs/18/app-pgamcheck.html", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "signature": "--checkunique", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "signature": "--heapallindexed", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "signature": "--parent-check", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "signature": "--rootdescend", "source_url": "/docs/18/app-pgamcheck.html", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "summary": "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.", "signature": "-h hostname --host= hostname", "source_url": "/docs/18/app-pgamcheck.html", "description": "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."}, {"names": ["-p port", "--port= port"], "summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "signature": "-p port --port= port", "source_url": "/docs/18/app-pgamcheck.html", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "summary": "User name to connect as.", "signature": "-U --username= username", "source_url": "/docs/18/app-pgamcheck.html", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "signature": "-w --no-password", "source_url": "/docs/18/app-pgamcheck.html", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "signature": "-W --password", "source_url": "/docs/18/app-pgamcheck.html", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "signature": "--maintenance-db= dbname", "source_url": "/docs/18/app-pgamcheck.html", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "summary": "Echo to stdout all SQL sent to the server.", "signature": "-e --echo", "source_url": "/docs/18/app-pgamcheck.html", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "signature": "-j num --jobs= num", "source_url": "/docs/18/app-pgamcheck.html", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "signature": "-P --progress", "source_url": "/docs/18/app-pgamcheck.html", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "signature": "-v --verbose", "source_url": "/docs/18/app-pgamcheck.html", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "summary": "Print the pg_amcheck version and exit.", "signature": "-V --version", "source_url": "/docs/18/app-pgamcheck.html", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "signature": "--install-missing --install-missing= schema", "source_url": "/docs/18/app-pgamcheck.html", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "summary": "Show help about pg_amcheck command line arguments, and exit.", "signature": "-? --help", "source_url": "/docs/18/app-pgamcheck.html", "description": "Show help about pg_amcheck command line arguments, and exit."}], "related": [], "release": {"ref": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "label": "18.6", "major": "18", "channel": "stable", "manifest": {"pdf": {"A4": {"url": "/files/documentation/pdf/18/postgresql-18-A4.pdf", "bytes": 15865106, "pages": 3154, "sha256": "19512c405da53f9f7fcf0abba359223aa65f021be025bf3411381918f92e3190", "built_at": "2026-09-26"}, "US": {"url": "/files/documentation/pdf/18/postgresql-18-US.pdf", "bytes": 15748059, "pages": 3328, "sha256": "facbe6c229e598b872d3d98bef53308f46e06746006fa4590de9a7de9dd46319", "built_at": "2026-09-26"}}, "tree": "18", "index": "index.html", "major": "18", "pages": 1148, "release": "18.6", "source_url": "https://ftp.postgresql.org/pub/source/v18.6/postgresql-18.6.tar.bz2", "svg_assets": 3, "source_mode": "en SGML built with pinned official archive", "source_sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}, "revision": "ee8d1a3612338fd9adf250730cb640fcc5233b5491337cc00a316a44e3a0b9f8", "evidence_kind": "English manual and source declarations", "source_sha256": "555610c24d53e4316da5b7d3fc25c279d96856d5e0e23ee308c328c5fa881d9f"}, "sources": [{"url": "https://pg.center/docs/18/app-pgamcheck.html", "file": "app-pgamcheck.html", "label": "18.6 English manual \u00b7 app-pgamcheck.html", "anchor": "", "sha256": "e27a4203de24586f422047021fddd4cd69bbe0093c3949ac283091329050c9f5", "language": "en", "original_url": "/docs/18/app-pgamcheck.html"}, {"url": "https://pg.center/docs/18/reference-client.html", "file": "reference-client.html", "label": "Client applications inventory", "anchor": "", "sha256": "68f726af77272fe73a827be2b7b5958d0f2239a6f8ed44264e9d42496bfa4fd0", "language": "en", "original_url": "/docs/18/reference-client.html"}], "sections": [], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "signature": "pg_amcheck [ option ...] [ dbname ]", "description": ["pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a PostgreSQL \u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5"], "environment": [], "manual_html": "<div><div class=\"refentry\" id=\"APP-PGAMCHECK\">\n<div class=\"titlepage\"></div>\n<div class=\"refnamediv\">\n<h2><span class=\"refentrytitle\"><span class=\"application\">pg_amcheck</span></span></h2>\n<p lang=\"zh\">pg_amcheck \u2014 \u68c0\u67e5\u4e00\u4e2a\u6216\u591a\u4e2a<span class=\"productname\">PostgreSQL</span>\u6570\u636e\u5e93\u4e2d\u7684\u635f\u574f\u60c5\u51b5</p>\n</div>\n<div class=\"refsynopsisdiv\">\n<h2 lang=\"zh\">\u5927\u7eb2</h2>\n<div class=\"cmdsynopsis\">\n<p id=\"id-1.9.4.9.4.1\"><code class=\"command\">pg_amcheck</code> [<em class=\"replaceable\"><code>option</code></em>...] [<em class=\"replaceable\"><code>dbname</code></em>]</p>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.5\">\n<h2 lang=\"zh\">\u8bf4\u660e</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u652f\u6301\u9488\u5bf9\u4e00\u4e2a\u6216\u591a\u4e2a\u6570\u636e\u5e93\u8fd0\u884c<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684\u635f\u574f\u68c0\u67e5\u51fd\u6570\uff0c\u5e76\u63d0\u4f9b\u9009\u9879\u6765\u9009\u62e9\u8981\u68c0\u67e5\u54ea\u4e9b\u6a21\u5f0f\u3001\u8868\u548c\u7d22\u5f15\uff0c\u6267\u884c\u54ea\u4e9b\u68c0\u67e5\uff0c\u4ee5\u53ca\u662f\u5426\u5e76\u884c\u6267\u884c\u8fd9\u4e9b\u68c0\u67e5\uff1b\u5982\u679c\u5e76\u884c\u6267\u884c\uff0c\u8fd8\u53ef\u6307\u5b9a\u8981\u5efa\u7acb\u5e76\u4f7f\u7528\u7684\u5e76\u884c\u8fde\u63a5\u6570\u3002</p>\n<p lang=\"zh\">\u5f53\u524d\u4ec5\u652f\u6301\u666e\u901a\u8868\u5173\u7cfb\u3001TOAST \u8868\u5173\u7cfb\u3001\u7269\u5316\u89c6\u56fe\u3001\u5e8f\u5217\u4ee5\u53ca B-\u6811\u7d22\u5f15\u3002\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u4f1a\u88ab\u9759\u9ed8\u8df3\u8fc7\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u6307\u5b9a\u4e86<code class=\"literal\">dbname</code>\uff0c\u5b83\u5e94\u662f\u8981\u68c0\u67e5\u7684\u5355\u4e2a\u6570\u636e\u5e93\u7684\u540d\u79f0\uff0c\u5e76\u4e14\u4e0d\u5e94\u518d\u51fa\u73b0\u5176\u4ed6\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002\u5426\u5219\uff0c\u5982\u679c\u5b58\u5728\u4efb\u4f55\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\uff0c\u5c31\u4f1a\u68c0\u67e5\u6240\u6709\u5339\u914d\u7684\u6570\u636e\u5e93\u3002\u5982\u679c\u4e0d\u5b58\u5728\u8fd9\u7c7b\u9009\u9879\uff0c\u5219\u68c0\u67e5\u9ed8\u8ba4\u6570\u636e\u5e93\u3002\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u5305\u62ec<code class=\"option\">--all</code>\u3001<code class=\"option\">--database</code>\u548c<code class=\"option\">--exclude-database</code>\u3002\u5b83\u4eec\u8fd8\u5305\u62ec<code class=\"option\">--relation</code>\u3001<code class=\"option\">--exclude-relation</code>\u3001<code class=\"option\">--table</code>\u3001<code class=\"option\">--exclude-table</code>\u3001<code class=\"option\">--index</code>\u548c<code class=\"option\">--exclude-index</code>\uff0c\u4f46\u4ec5\u9650\u4e8e\u8fd9\u4e9b\u9009\u9879\u4e0e\u4e09\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*.myrel*</code>\uff09\u3002\u6700\u540e\uff0c\u5f53<code class=\"option\">--schema</code>\u548c<code class=\"option\">--exclude-schema</code>\u4e0e\u4e24\u90e8\u5206\u6a21\u5f0f\u4e00\u8d77\u4f7f\u7528\u65f6\uff08\u4f8b\u5982 <code class=\"option\">mydb*.myschema*</code>\uff09\uff0c\u5b83\u4eec\u4e5f\u5c5e\u4e8e\u6570\u636e\u5e93\u9009\u62e9\u9009\u9879\u3002</p>\n<p lang=\"zh\"><em class=\"replaceable\"><code>dbname</code></em>\u4e5f\u53ef\u4ee5\u662f<a class=\"link\" href=\"/docs/18/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.6\">\n<h2 lang=\"zh\">\u9009\u9879</h2>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8981\u68c0\u67e5\u7684\u5185\u5bb9\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-a</code><br/></span><span class=\"term\"><code class=\"option\">--all</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u6240\u6709\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-d <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\uff0c\u4f46\u901a\u8fc7<code class=\"option\">--exclude-database</code>\u6392\u9664\u7684\u9664\u5916\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-D <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-database=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6570\u636e\u5e93\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-i <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-I <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-index=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u4e0d\u9002\u7528\u4e8e\u5176\u4ed6\u5173\u7cfb\u7c7b\u578b\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-r <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myrel*</code>\uff1b\u4e5f\u53ef\u4ee5\u662f\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u4f8b\u5982<code class=\"literal\">myschema*.myrel*</code>\uff1b\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\uff0c\u4f8b\u5982<code class=\"literal\">mydb*.myschema*.myrel*</code>\u3002\u6570\u636e\u5e93\u9650\u5b9a\u7684\u6a21\u5f0f\u4f1a\u628a\u5339\u914d\u7684\u6570\u636e\u5e93\u52a0\u5165\u5f85\u68c0\u67e5\u6570\u636e\u5e93\u5217\u8868\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-R <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-relation=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u5173\u7cfb\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--relation</code>\u4e00\u6837\uff0c<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u53ef\u4ee5\u662f\u672a\u7ecf\u9650\u5b9a\u7684\u3001\u6a21\u5f0f\u9650\u5b9a\u7684\uff0c\u6216\u8005\u540c\u65f6\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u548c\u6a21\u5f0f\u9650\u5b9a\u7684\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-s <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u82e5\u53ea\u60f3\u9009\u62e9\u540d\u79f0\u5339\u914d\u7279\u5b9a\u6a21\u5f0f\u7684\u90a3\u4e9b\u6a21\u5f0f\u4e2d\u7684\u8868\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--table=SCHEMAPAT.* --no-dependent-indexes</code>\u7684\u5199\u6cd5\u3002\u82e5\u53ea\u60f3\u9009\u62e9\u7d22\u5f15\uff0c\u53ef\u8003\u8651\u4f7f\u7528\u7c7b\u4f3c<code class=\"literal\">--index=SCHEMAPAT.*</code>\u7684\u5199\u6cd5\u3002</p>\n<p lang=\"zh\">\u6a21\u5f0f\u540d\u5339\u914d\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6709\u6570\u636e\u5e93\u9650\u5b9a\u3002\u4f8b\u5982\uff0c\u53ef\u4ee5\u4f7f\u7528 --schema=mydb*.myschema*\uff0c\u9009\u62e9\u540d\u79f0\u5339\u914d mydb* \u7684\u6570\u636e\u5e93\u4e2d\u540d\u79f0\u5339\u914d myschema* \u7684\u6a21\u5f0f\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-S <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-schema=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u6a21\u5f0f\u4e2d\u7684\u8868\u548c\u7d22\u5f15\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u4e0e<code class=\"option\">--schema</code>\u4e00\u6837\uff0c\u8be5\u6a21\u5f0f\u53ef\u4ee5\u5e26\u6570\u636e\u5e93\u9650\u5b9a\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-t <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u68c0\u67e5\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\uff0c\u9664\u975e\u53e6\u6709\u6392\u9664\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-T <em class=\"replaceable\"><code>pattern</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--exclude-table=<em class=\"replaceable\"><code>pattern</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u6392\u9664\u5339\u914d\u6307\u5b9a<a class=\"link\" href=\"/docs/18/app-psql.html#APP-PSQL-PATTERNS\" title=\"\u6a21\u5f0f\"><em class=\"replaceable\"><code>pattern</code></em></a>\u7684\u8868\u3002\u6b64\u9009\u9879\u53ef\u6307\u5b9a\u591a\u6b21\u3002</p>\n<p lang=\"zh\">\u8fd9\u4e0e<code class=\"option\">--exclude-relation</code>\u9009\u9879\u7c7b\u4f3c\uff0c\u4f46\u5b83\u53ea\u9002\u7528\u4e8e\u8868\u3001\u7269\u5316\u89c6\u56fe\u548c\u5e8f\u5217\uff0c\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-indexes</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u8be5\u8868\u4e0a\u7684\u4efb\u4f55 B-\u6811\u7d22\u5f15\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u5b83\u4eec\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-dependent-toast</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c\u68c0\u67e5\u67d0\u4e2a\u8868\uff0c\u5219\u5b83\u7684 TOAST \u8868\uff08\u5982\u679c\u6709\uff09\u4e5f\u4f1a\u4e00\u5e76\u68c0\u67e5\uff0c\u5373\u4f7f\u8be5 TOAST \u8868\u6ca1\u6709\u901a\u8fc7<code class=\"literal\">--table</code>\u6216<code class=\"literal\">--relation</code>\u7b49\u9009\u9879\u663e\u5f0f\u9009\u4e2d\u3002\u6b64\u9009\u9879\u4f1a\u7981\u6b62\u8fd9\u79cd\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--no-strict-names</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u5982\u679c<code class=\"literal\">--database</code>\u3001<code class=\"literal\">--table</code>\u3001<code class=\"literal\">--index</code>\u6216<code class=\"literal\">--relation</code>\u7684\u67d0\u4e2a\u53c2\u6570\u6ca1\u6709\u5339\u914d\u5230\u4efb\u4f55\u5bf9\u8c61\uff0c\u5c31\u4f1a\u62a5\u81f4\u547d\u9519\u8bef\u3002\u6b64\u9009\u9879\u4f1a\u5c06\u8be5\u9519\u8bef\u964d\u7ea7\u4e3a\u8b66\u544a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u8868\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--exclude-toast-pointers</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u9ed8\u8ba4\u60c5\u51b5\u4e0b\uff0c\u53ea\u8981\u5728\u8868\u4e2d\u9047\u5230 TOAST \u6307\u9488\uff0c\u5c31\u4f1a\u6267\u884c\u67e5\u627e\uff0c\u4ee5\u786e\u4fdd\u5b83\u5f15\u7528\u7684\u662f TOAST \u8868\u4e2d\u8868\u9762\u770b\u6765\u6709\u6548\u7684\u6761\u76ee\u3002\u8fd9\u4e9b\u68c0\u67e5\u53ef\u80fd\u76f8\u5f53\u6162\uff0c\u53ef\u7528\u6b64\u9009\u9879\u8df3\u8fc7\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--on-error-stop</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5728\u67d0\u4e2a\u8868\u4e2d\u53d1\u73b0\u635f\u574f\u540e\uff0c\u5728\u62a5\u544a\u5b8c\u8be5\u8868\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u9762\u4e0a\u7684\u5168\u90e8\u635f\u574f\u540e\uff0c\u505c\u6b62\u5904\u7406\u8be5\u8868\u5173\u7cfb\u5e76\u8f6c\u5230\u4e0b\u4e00\u4e2a\u8868\u6216\u7d22\u5f15\u3002</p>\n<p lang=\"zh\">\u6ce8\u610f\uff0c\u7d22\u5f15\u68c0\u67e5\u603b\u662f\u5728\u7b2c\u4e00\u4e2a\u635f\u574f\u9875\u540e\u505c\u6b62\u3002\u6b64\u9009\u9879\u53ea\u5bf9\u8868\u5173\u7cfb\u6709\u610f\u4e49\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--skip=<em class=\"replaceable\"><code>option</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-frozen</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u51bb\u7ed3\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u5982\u679c\u7ed9\u5b9a<code class=\"literal\">all-visible</code>\uff0c\u8868\u635f\u574f\u68c0\u67e5\u4f1a\u8df3\u8fc7\u6240\u6709\u8868\u4e2d\u6807\u8bb0\u4e3a\u5168\u53ef\u89c1\u7684\u9875\u9762\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4e0d\u8df3\u8fc7\u4efb\u4f55\u9875\u9762\u3002\u8fd9\u53ef\u4ee5\u663e\u5f0f\u6307\u5b9a\u4e3a<code class=\"literal\">none</code>\uff0c\u4f46\u56e0\u4e3a\u8fd9\u662f\u9ed8\u8ba4\u503c\uff0c\u901a\u5e38\u65e0\u9700\u5199\u51fa\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--startblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u4ece\u6307\u5b9a\u5757\u53f7\u5f00\u59cb\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u8fdb\u4e00\u6b65\u7684\u6ce8\u610f\u4e8b\u9879\u89c1<code class=\"literal\">--endblock</code>\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--endblock=<em class=\"replaceable\"><code>block</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5728\u6307\u5b9a\u5757\u53f7\u7ed3\u675f\u68c0\u67e5\u3002\u5982\u679c\u88ab\u68c0\u67e5\u7684\u8868\u5173\u7cfb\u5757\u6570\u5c11\u4e8e\u8fd9\u4e2a\u6570\u5b57\uff0c\u5c06\u53d1\u751f\u9519\u8bef\u3002\u6b64\u9009\u9879\u4e0d\u9002\u7528\u4e8e\u7d22\u5f15\uff0c\u800c\u4e14\u5927\u6982\u53ea\u5728\u68c0\u67e5\u5355\u4e2a\u8868\u5173\u7cfb\u65f6\u624d\u6709\u7528\u3002\u5982\u679c\u540c\u65f6\u68c0\u67e5\u666e\u901a\u8868\u548c TOAST \u8868\uff0c\u6b64\u9009\u9879\u4f1a\u540c\u65f6\u4f5c\u7528\u4e8e\u4e24\u8005\uff1b\u4f46\u5728\u9a8c\u8bc1 TOAST \u6307\u9488\u65f6\uff0c\u4ecd\u53ef\u80fd\u8bbf\u95ee\u66f4\u9ad8\u7f16\u53f7\u7684 TOAST \u5757\uff0c\u9664\u975e\u4f7f\u7528<code class=\"option\">--exclude-toast-pointers</code>\u6291\u5236\u8fd9\u4e00\u884c\u4e3a\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236 B-\u6811\u7d22\u5f15\u7684\u68c0\u67e5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">--checkunique</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u5e26\u552f\u4e00\u7ea6\u675f\u7684\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">checkunique</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u91cd\u590d\u6761\u76ee\u4e2d\u5728\u7d22\u5f15\u91cc\u53ef\u89c1\u7684\u9879\u4e0d\u8d85\u8fc7\u4e00\u4e2a\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--heapallindexed</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">heapallindexed</code>\u9009\u9879\uff0c\u9a8c\u8bc1\u6240\u6709\u5806\u5143\u7ec4\u90fd\u4ee5\u7d22\u5f15\u5143\u7ec4\u7684\u5f62\u5f0f\u51fa\u73b0\u5728\u8be5\u7d22\u5f15\u4e2d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--parent-check</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a B-\u6811\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"function\">bt_index_parent_check</code>\u51fd\u6570\uff0c\u8be5\u51fd\u6570\u4f1a\u5728\u7d22\u5f15\u68c0\u67e5\u671f\u95f4\u989d\u5916\u68c0\u67e5\u7236\u5b50\u5173\u7cfb\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528<span class=\"application\">amcheck</span>\u7684<code class=\"function\">bt_index_check</code>\u51fd\u6570\uff0c\u4f46\u8bf7\u6ce8\u610f\uff0c\u4f7f\u7528<code class=\"option\">--rootdescend</code>\u9009\u9879\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"function\">bt_index_parent_check</code>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--rootdescend</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5bf9\u4e8e\u68c0\u67e5\u7684\u6bcf\u4e2a\u7d22\u5f15\uff0c\u4f7f\u7528<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u7684<code class=\"option\">rootdescend</code>\u9009\u9879\uff0c\u4e3a\u6bcf\u4e2a\u5143\u7ec4\u4ece\u6839\u9875\u91cd\u65b0\u6267\u884c\u4e00\u6b21\u641c\u7d22\uff0c\u4ece\u800c\u5728\u53f6\u7ea7\u91cd\u65b0\u627e\u5230\u8fd9\u4e9b\u5143\u7ec4\u3002</p>\n<p lang=\"zh\">\u4f7f\u7528\u6b64\u9009\u9879\u4e5f\u4f1a\u9690\u5f0f\u9009\u62e9<code class=\"option\">--parent-check</code>\u9009\u9879\u3002</p>\n<p lang=\"zh\">\u8fd9\u79cd\u9a8c\u8bc1\u5f62\u5f0f\u6700\u521d\u662f\u4e3a\u534f\u52a9\u5f00\u53d1 B-\u6811\u7d22\u5f15\u7279\u6027\u800c\u7f16\u5199\u7684\u3002\u5b83\u5728\u5e2e\u52a9\u68c0\u6d4b\u5b9e\u9645\u53d1\u751f\u7684\u90a3\u7c7b\u635f\u574f\u65b9\u9762\u53ef\u80fd\u7528\u9014\u6709\u9650\uff0c\u751a\u81f3\u6beb\u65e0\u5e2e\u52a9\u3002\u5b83\u8fd8\u53ef\u80fd\u4f7f\u635f\u574f\u68c0\u67e5\u8017\u65f6\u663e\u8457\u589e\u52a0\uff0c\u5e76\u663e\u8457\u589e\u52a0\u670d\u52a1\u5668\u4e0a\u7684\u8d44\u6e90\u6d88\u8017\u3002</p>\n</dd>\n</dl>\n</div>\n<div class=\"warning\">\n<h3 class=\"title\" lang=\"zh\">\u8b66\u544a</h3>\n<p lang=\"zh\">\u5f53\u6307\u5b9a<code class=\"option\">--parent-check</code>\u6216<code class=\"option\">--rootdescend</code>\u65f6\uff0c\u5bf9 B-\u6811\u7d22\u5f15\u6267\u884c\u7684\u989d\u5916\u68c0\u67e5\u9700\u8981\u76f8\u5bf9\u8f83\u5f3a\u7684\u5173\u7cfb\u7ea7\u9501\u3002\u8fd9\u4e9b\u68c0\u67e5\u4e5f\u662f\u552f\u4e00\u4f1a\u963b\u585e<code class=\"command\">INSERT</code>\u3001<code class=\"command\">UPDATE</code>\u548c<code class=\"command\">DELETE</code>\u547d\u4ee4\u5e76\u53d1\u4fee\u6539\u6570\u636e\u7684\u68c0\u67e5\u3002</p>\n</div>\n<p lang=\"zh\">\u4e0b\u5217\u547d\u4ee4\u884c\u9009\u9879\u63a7\u5236\u4e0e\u670d\u52a1\u5668\u7684\u8fde\u63a5\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-h <em class=\"replaceable\"><code>hostname</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--host=<em class=\"replaceable\"><code>hostname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u6240\u5728\u673a\u5668\u7684\u4e3b\u673a\u540d\u3002\u5982\u679c\u8be5\u503c\u4ee5\u659c\u6760\u5f00\u5934\uff0c\u5219\u5c06\u5176\u7528\u4f5c Unix \u57df\u5957\u63a5\u5b57\u6240\u5728\u7684\u76ee\u5f55\u3002</p>\n</p>\n</dd>\n<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>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u670d\u52a1\u5668\u76d1\u542c\u8fde\u63a5\u7684 TCP \u7aef\u53e3\u6216\u672c\u5730 Unix \u57df\u5957\u63a5\u5b57\u6587\u4ef6\u6269\u5c55\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-U</code><br/></span><span class=\"term\"><code class=\"option\">--username=<em class=\"replaceable\"><code>username</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u8fde\u63a5\u65f6\u4f7f\u7528\u7684\u7528\u6237\u540d\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-w</code><br/></span><span class=\"term\"><code class=\"option\">--no-password</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6c38\u4e0d\u53d1\u51fa\u5bc6\u7801\u63d0\u793a\u3002\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c\u800c\u53c8\u65e0\u6cd5\u901a\u8fc7\u5176\u4ed6\u65b9\u5f0f\u83b7\u53d6\u5bc6\u7801\uff0c\u4f8b\u5982\u901a\u8fc7<code class=\"filename\">.pgpass</code>\u6587\u4ef6\uff0c\u5219\u8fde\u63a5\u5c1d\u8bd5\u4f1a\u5931\u8d25\u3002\u6b64\u9009\u9879\u53ef\u7528\u4e8e\u6ca1\u6709\u7528\u6237\u5728\u573a\u8f93\u5165\u5bc6\u7801\u7684\u6279\u5904\u7406\u4f5c\u4e1a\u548c\u811a\u672c\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-W</code><br/></span><span class=\"term\"><code class=\"option\">--password</code></span></dt>\n<dd>\n<p lang=\"zh\">\u5f3a\u5236<span class=\"application\">pg_amcheck</span>\u5728\u8fde\u63a5\u6570\u636e\u5e93\u524d\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002</p>\n<p lang=\"zh\">\u8be5\u9009\u9879\u5e76\u975e\u5fc5\u9700\uff0c\u56e0\u4e3a\u5982\u679c\u670d\u52a1\u5668\u8981\u6c42\u5bc6\u7801\u8ba4\u8bc1\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u81ea\u52a8\u63d0\u793a\u8f93\u5165\u5bc6\u7801\u3002\u4e0d\u8fc7\uff0c<span class=\"application\">pg_amcheck</span>\u4f1a\u5148\u6d6a\u8d39\u4e00\u6b21\u8fde\u63a5\u5c1d\u8bd5\uff0c\u624d\u80fd\u53d1\u73b0\u670d\u52a1\u5668\u9700\u8981\u5bc6\u7801\u3002\u5728\u67d0\u4e9b\u573a\u666f\u4e0b\uff0c\u503c\u5f97\u663e\u5f0f\u6307\u5b9a<code class=\"option\">-W</code>\uff0c\u4ee5\u907f\u514d\u8fd9\u6b21\u989d\u5916\u7684\u8fde\u63a5\u5c1d\u8bd5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--maintenance-db=<em class=\"replaceable\"><code>dbname</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6307\u5b9a\u4e00\u4e2a\u6570\u636e\u5e93\u6216<a class=\"link\" href=\"/docs/18/libpq-connect.html#LIBPQ-CONNSTRING\" title=\"32.1.1.\u00a0\u8fde\u63a5\u5b57\u7b26\u4e32\">\u8fde\u63a5\u5b57\u7b26\u4e32</a>\uff0c\u7528\u4e8e\u786e\u5b9a\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u5217\u8868\u3002\u5982\u679c\u65e2\u672a\u4f7f\u7528<code class=\"option\">--all</code>\uff0c\u4e5f\u672a\u4f7f\u7528\u4efb\u4f55\u5305\u542b\u6570\u636e\u5e93\u540d\u79f0\u5339\u914d\u6a21\u5f0f\u7684\u9009\u9879\uff0c\u5219\u4e0d\u9700\u8981\u8fd9\u6837\u7684\u8fde\u63a5\uff0c\u6b64\u9009\u9879\u4e5f\u4e0d\u8d77\u4f5c\u7528\u3002\u5426\u5219\uff0c\u6b64\u9009\u9879\u503c\u4e2d\u9664\u6570\u636e\u5e93\u540d\u4e4b\u5916\u7684\u4efb\u4f55\u8fde\u63a5\u5b57\u7b26\u4e32\u53c2\u6570\uff0c\u5728\u8fde\u63a5\u5f85\u68c0\u67e5\u7684\u6570\u636e\u5e93\u65f6\u4e5f\u4f1a\u4e00\u5e76\u4f7f\u7528\u3002\u5982\u679c\u7701\u7565\u6b64\u9009\u9879\uff0c\u9ed8\u8ba4\u503c\u4e3a<code class=\"literal\">postgres</code>\uff1b\u82e5\u5931\u8d25\uff0c\u5219\u4e3a<code class=\"literal\">template1</code>\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n<p lang=\"zh\">\u8fd8\u63d0\u4f9b\u4e0b\u5217\u5176\u4ed6\u9009\u9879\uff1a</p>\n<div class=\"variablelist\">\n<dl class=\"variablelist\">\n<dt><span class=\"term\"><code class=\"option\">-e</code><br/></span><span class=\"term\"><code class=\"option\">--echo</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u5c06\u53d1\u9001\u5230\u670d\u52a1\u5668\u7684\u6240\u6709 SQL \u56de\u663e\u5230\u6807\u51c6\u8f93\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-j <em class=\"replaceable\"><code>num</code></em></code><br/></span><span class=\"term\"><code class=\"option\">--jobs=<em class=\"replaceable\"><code>num</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u4f7f\u7528<em class=\"replaceable\"><code>num</code></em>\u4e2a\u5230\u670d\u52a1\u5668\u7684\u5e76\u53d1\u8fde\u63a5\uff0c\u6216\u8005\u4e3a\u6bcf\u4e2a\u5f85\u68c0\u67e5\u5bf9\u8c61\u4f7f\u7528\u4e00\u4e2a\u8fde\u63a5\uff0c\u4ee5\u8f83\u5c0f\u8005\u4e3a\u51c6\u3002</p>\n<p lang=\"zh\">\u9ed8\u8ba4\u4f7f\u7528\u5355\u4e2a\u8fde\u63a5\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-P</code><br/></span><span class=\"term\"><code class=\"option\">--progress</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a\u8fdb\u5ea6\u4fe1\u606f\u3002\u8fdb\u5ea6\u4fe1\u606f\u5305\u62ec\u5df2\u5b8c\u6210\u68c0\u67e5\u7684\u5173\u7cfb\u6570\u91cf\u53ca\u5176\u603b\u5927\u5c0f\uff0c\u4e5f\u5305\u62ec\u6700\u7ec8\u5c06\u8981\u68c0\u67e5\u7684\u5173\u7cfb\u603b\u6570\u53ca\u8fd9\u4e9b\u5173\u7cfb\u7684\u4f30\u8ba1\u5927\u5c0f\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-v</code><br/></span><span class=\"term\"><code class=\"option\">--verbose</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370\u66f4\u591a\u6d88\u606f\u3002\u7279\u522b\u662f\uff0c\u5b83\u4f1a\u4e3a\u6bcf\u4e2a\u6b63\u5728\u68c0\u67e5\u7684\u5173\u7cfb\u6253\u5370\u4e00\u6761\u6d88\u606f\uff0c\u5e76\u63d0\u9ad8\u670d\u52a1\u5668\u9519\u8bef\u663e\u793a\u7684\u8be6\u7ec6\u7a0b\u5ea6\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-V</code><br/></span><span class=\"term\"><code class=\"option\">--version</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u6253\u5370<span class=\"application\">pg_amcheck</span>\u7248\u672c\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">--install-missing</code><br/></span><span class=\"term\"><code class=\"option\">--install-missing=<em class=\"replaceable\"><code>schema</code></em></code></span></dt>\n<dd>\n<p lang=\"zh\">\u5b89\u88c5\u68c0\u67e5\u6570\u636e\u5e93\u6240\u9700\u7684\u4efb\u4f55\u7f3a\u5931\u6269\u5c55\u3002\u5982\u679c\u67d0\u4e2a\u6269\u5c55\u5c1a\u672a\u5b89\u88c5\uff0c\u5219\u5176\u5bf9\u8c61\u5c06\u5b89\u88c5\u5230\u7ed9\u5b9a\u7684<em class=\"replaceable\"><code>schema</code></em>\u4e2d\uff1b\u5982\u679c\u672a\u6307\u5b9a\uff0c\u5219\u5b89\u88c5\u5230<code class=\"literal\">pg_catalog</code>\u6a21\u5f0f\u4e2d\u3002</p>\n<p lang=\"zh\">\u76ee\u524d\uff0c\u552f\u4e00\u5fc5\u9700\u7684\u6269\u5c55\u662f<a class=\"xref\" href=\"/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 \u7528\u4e8e\u9a8c\u8bc1\u8868\u548c\u7d22\u5f15\u4e00\u81f4\u6027\u7684\u5de5\u5177\">amcheck</a>\u3002</p>\n</dd>\n<dt><span class=\"term\"><code class=\"option\">-?</code><br/></span><span class=\"term\"><code class=\"option\">--help</code></span></dt>\n<dd>\n<p lang=\"zh\">\n<p>\u663e\u793a<span class=\"application\">pg_amcheck</span>\u547d\u4ee4\u884c\u53c2\u6570\u7684\u5e2e\u52a9\u5e76\u9000\u51fa\u3002</p>\n</p>\n</dd>\n</dl>\n</div>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.7\">\n<h2 lang=\"zh\">\u73af\u5883</h2>\n<p lang=\"zh\">\u4e0e\u5927\u591a\u6570\u5176\u4ed6<span class=\"productname\">PostgreSQL</span>\u5de5\u5177\u4e00\u6837\uff0c<code class=\"command\">pg_amcheck</code>\u4e5f\u4f7f\u7528<span class=\"application\">libpq</span>\u652f\u6301\u7684\u73af\u5883\u53d8\u91cf\uff08\u89c1<a class=\"xref\" href=\"/docs/18/libpq-envars.html\" title=\"32.15.\u00a0\u73af\u5883\u53d8\u91cf\">\u7b2c\u00a032.15\u00a0\u8282</a>\uff09\u3002</p>\n<p lang=\"zh\">\u73af\u5883\u53d8\u91cf<code class=\"envar\">PG_COLOR</code>\u6307\u5b9a\u662f\u5426\u5728\u8bca\u65ad\u6d88\u606f\u4e2d\u4f7f\u7528\u989c\u8272\u3002\u53ef\u80fd\u7684\u503c\u4e3a<code class=\"literal\">always</code>\u3001<code class=\"literal\">auto</code>\u548c<code class=\"literal\">never</code>\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.8\">\n<h2 lang=\"zh\">\u6ce8\u89e3</h2>\n<p lang=\"zh\"><span class=\"application\">pg_amcheck</span>\u65e8\u5728\u4e0e<span class=\"productname\">PostgreSQL</span> 14.0 \u53ca\u4ee5\u540e\u7248\u672c\u914d\u5408\u4f7f\u7528\u3002</p>\n</div>\n<div class=\"refsect1\" id=\"id-1.9.4.9.9\">\n<h2 lang=\"zh\">\u53e6\u89c1</h2><span class=\"simplelist\"><a class=\"xref\" href=\"https://pg.center/docs/18/amcheck.html\" title=\"F.1.\u00a0amcheck \u2014 tools to verify table and index consistency\">amcheck</a></span>\n</div>\n</div></div>", "manual_path": "app-pgamcheck.html", "localization": {"status": "complete", "sources": [{"url": "/docs/18/app-pgamcheck.html", "method": "same-major semantic node", "sha256": "4ef0217b2d2d6a134807e864ad8a89f508a45f3dbe0fedc17672fe01f3e70c15", "language": "zh", "matched_nodes": ["#APP-PGAMCHECK/div[2]/p[1]", "#APP-PGAMCHECK/div[3]/h2[0]", "#APP-PGAMCHECK/div[4]/p[1]", "#APP-PGAMCHECK/div[4]/p[2]", "#APP-PGAMCHECK/div[4]/p[3]", "#APP-PGAMCHECK/div[4]/p[4]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[13]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[11]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[11]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[13]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[15]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[17]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[19]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[21]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[23]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[25]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[27]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[2]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[3]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[5]/p[2]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[4]/dl[0]/dd[9]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[5]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[0]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[6]/dl[0]/dd[7]/p[2]", "#APP-PGAMCHECK/div[5]/div[7]/h3[0]", "#APP-PGAMCHECK/div[5]/div[7]/p[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[11]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[1]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[3]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[5]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[7]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[0]", "#APP-PGAMCHECK/div[5]/div[9]/dl[0]/dd[9]/p[1]", "#APP-PGAMCHECK/div[5]/p[10]", "#APP-PGAMCHECK/div[5]/p[1]", "#APP-PGAMCHECK/div[5]/p[3]", "#APP-PGAMCHECK/div[5]/p[5]", "#APP-PGAMCHECK/div[5]/p[8]", "#APP-PGAMCHECK/div[6]/h2[0]", "#APP-PGAMCHECK/div[6]/p[1]", "#APP-PGAMCHECK/div[6]/p[2]", "#APP-PGAMCHECK/div[7]/h2[0]", "#APP-PGAMCHECK/div[7]/p[1]", "#APP-PGAMCHECK/div[8]/h2[0]"]}], "language": "zh", "original_text": {"/versions/18/description/0": "pg_amcheck \u2014 checks for corruption in one or more PostgreSQL databases", "/versions/18/facts/0/label": "Documented executable", "/versions/18/facts/1/label": "Executable version", "/versions/18/facts/2/label": "Reference inventory", "/versions/18/facts/2/value": "Client applications", "/versions/18/facts/3/label": "Option definition groups", "/versions/18/tables/0/title": "Documented options", "/versions/18/tables/0/rows/0/summary": "Check all databases, except for any excluded via --exclude-database .", "/versions/18/tables/0/rows/1/summary": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once.", "/versions/18/tables/0/rows/2/summary": "Exclude databases matching the given pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/3/summary": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/4/summary": "Exclude indexes matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/5/summary": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/6/summary": "Exclude relations matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/7/summary": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/rows/8/summary": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/9/summary": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once.", "/versions/18/tables/0/columns/0/label": "Option and arguments", "/versions/18/tables/0/columns/1/label": "Description", "/versions/18/tables/0/rows/10/summary": "Exclude tables matching the specified pattern . This option can be specified more than once.", "/versions/18/tables/0/rows/11/summary": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior.", "/versions/18/tables/0/rows/12/summary": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior.", "/versions/18/tables/0/rows/13/summary": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning.", "/versions/18/tables/0/rows/14/summary": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them.", "/versions/18/tables/0/rows/15/summary": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index.", "/versions/18/tables/0/rows/16/summary": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen.", "/versions/18/tables/0/rows/17/summary": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats.", "/versions/18/tables/0/rows/18/summary": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers .", "/versions/18/tables/0/rows/19/summary": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option.", "/versions/18/tables/0/rows/20/summary": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option.", "/versions/18/tables/0/rows/21/summary": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking.", "/versions/18/tables/0/rows/22/summary": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option.", "/versions/18/tables/0/rows/23/summary": "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.", "/versions/18/tables/0/rows/24/summary": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections.", "/versions/18/tables/0/rows/25/summary": "User name to connect as.", "/versions/18/tables/0/rows/26/summary": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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.", "/versions/18/tables/0/rows/27/summary": "Force pg_amcheck to prompt for a password before connecting to a database.", "/versions/18/tables/0/rows/28/summary": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 .", "/versions/18/tables/0/rows/29/summary": "Echo to stdout all SQL sent to the server.", "/versions/18/tables/0/rows/30/summary": "Use num concurrent connections to the server, or one per object to be checked, whichever is less.", "/versions/18/tables/0/rows/31/summary": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations.", "/versions/18/tables/0/rows/32/summary": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors.", "/versions/18/tables/0/rows/33/summary": "Print the pg_amcheck version and exit.", "/versions/18/tables/0/rows/34/summary": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog .", "/versions/18/tables/0/rows/35/summary": "Show help about pg_amcheck command line arguments, and exit."}, "fallback_fields": [], "source_language": "en", "original_snapshot_sha256": "a943e71dc285dd06caa6f3e90388eabc0d46350d861ded5ea35464934ef7c5d5"}, "comparison_data": {"options": [{"names": ["-a", "--all"], "signature": "-a --all", "description": "Check all databases, except for any excluded via --exclude-database ."}, {"names": ["-d pattern", "--database= pattern"], "signature": "-d pattern --database= pattern", "description": "Check databases matching the specified pattern , except for any excluded by --exclude-database . This option can be specified more than once."}, {"names": ["-D pattern", "--exclude-database= pattern"], "signature": "-D pattern --exclude-database= pattern", "description": "Exclude databases matching the given pattern . This option can be specified more than once."}, {"names": ["-i pattern", "--index= pattern"], "signature": "-i pattern --index= pattern", "description": "Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types."}, {"names": ["-I pattern", "--exclude-index= pattern"], "signature": "-I pattern --exclude-index= pattern", "description": "Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types."}, {"names": ["-r pattern", "--relation= pattern"], "signature": "-r pattern --relation= pattern", "description": "Check relations matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. Patterns may be unqualified, e.g. myrel* , or they may be schema-qualified, e.g. myschema*.myrel* or database-qualified and schema-qualified, e.g. mydb*.myschema*.myrel* . A database-qualified pattern will add matching databases to the list of databases to be checked."}, {"names": ["-R pattern", "--exclude-relation= pattern"], "signature": "-R pattern --exclude-relation= pattern", "description": "Exclude relations matching the specified pattern . This option can be specified more than once. As with --relation , the pattern may be unqualified, schema-qualified, or database- and schema-qualified."}, {"names": ["-s pattern", "--schema= pattern"], "signature": "-s pattern --schema= pattern", "description": "Check tables and indexes in schemas matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. To select only tables in schemas matching a particular pattern, consider using something like --table=SCHEMAPAT.* --no-dependent-indexes . To select only indexes, consider using something like --index=SCHEMAPAT.* . A schema pattern may be database-qualified. For example, you may write --schema=mydb*.myschema* to select schemas matching myschema* in databases matching mydb* ."}, {"names": ["-S pattern", "--exclude-schema= pattern"], "signature": "-S pattern --exclude-schema= pattern", "description": "Exclude tables and indexes in schemas matching the specified pattern . This option can be specified more than once. As with --schema , the pattern may be database-qualified."}, {"names": ["-t pattern", "--table= pattern"], "signature": "-t pattern --table= pattern", "description": "Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["-T pattern", "--exclude-table= pattern"], "signature": "-T pattern --exclude-table= pattern", "description": "Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes."}, {"names": ["--no-dependent-indexes"], "signature": "--no-dependent-indexes", "description": "By default, if a table is checked, any btree indexes of that table will also be checked, even if they are not explicitly selected by an option such as --index or --relation . This option suppresses that behavior."}, {"names": ["--no-dependent-toast"], "signature": "--no-dependent-toast", "description": "By default, if a table is checked, its toast table, if any, will also be checked, even if it is not explicitly selected by an option such as --table or --relation . This option suppresses that behavior."}, {"names": ["--no-strict-names"], "signature": "--no-strict-names", "description": "By default, if an argument to --database , --table , --index , or --relation matches no objects, it is a fatal error. This option downgrades that error to a warning."}, {"names": ["--exclude-toast-pointers"], "signature": "--exclude-toast-pointers", "description": "By default, whenever a toast pointer is encountered in a table, a lookup is performed to ensure that it references apparently-valid entries in the toast table. These checks can be quite slow, and this option can be used to skip them."}, {"names": ["--on-error-stop"], "signature": "--on-error-stop", "description": "After reporting all corruptions on the first page of a table where corruption is found, stop processing that table relation and move on to the next table or index. Note that index checking always stops after the first corrupt page. This option only has meaning relative to table relations."}, {"names": ["--skip= option"], "signature": "--skip= option", "description": "If all-frozen is given, table corruption checks will skip over pages in all tables that are marked as all frozen. If all-visible is given, table corruption checks will skip over pages in all tables that are marked as all visible. By default, no pages are skipped. This can be specified as none , but since this is the default, it need not be mentioned."}, {"names": ["--startblock= block"], "signature": "--startblock= block", "description": "Start checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. See --endblock for further caveats."}, {"names": ["--endblock= block"], "signature": "--endblock= block", "description": "End checking at the specified block number. An error will occur if the table relation being checked has fewer than this number of blocks. This option does not apply to indexes, and is probably only useful when checking a single table relation. If both a regular table and a toast table are checked, this option will apply to both, but higher-numbered toast blocks may still be accessed while validating toast pointers, unless that is suppressed using --exclude-toast-pointers ."}, {"names": ["--checkunique"], "signature": "--checkunique", "description": "For each index with unique constraint checked, verify that no more than one among duplicate entries is visible in the index using amcheck 's checkunique option."}, {"names": ["--heapallindexed"], "signature": "--heapallindexed", "description": "For each index checked, verify the presence of all heap tuples as index tuples in the index using amcheck 's heapallindexed option."}, {"names": ["--parent-check"], "signature": "--parent-check", "description": "For each btree index checked, use amcheck 's bt_index_parent_check function, which performs additional checks of parent/child relationships during index checking. The default is to use amcheck 's bt_index_check function, but note that use of the --rootdescend option implicitly selects bt_index_parent_check ."}, {"names": ["--rootdescend"], "signature": "--rootdescend", "description": "For each index checked, re-find tuples on the leaf level by performing a new search from the root page for each tuple using amcheck 's rootdescend option. Use of this option implicitly also selects the --parent-check option. This form of verification was originally written to help in the development of btree index features. It may be of limited use or even of no use in helping detect the kinds of corruption that occur in practice. It may also cause corruption checking to take considerably longer and consume considerably more resources on the server."}, {"names": ["-h hostname", "--host= hostname"], "signature": "-h hostname --host= hostname", "description": "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."}, {"names": ["-p port", "--port= port"], "signature": "-p port --port= port", "description": "Specifies the TCP port or local Unix domain socket file extension on which the server is listening for connections."}, {"names": ["-U", "--username= username"], "signature": "-U --username= username", "description": "User name to connect as."}, {"names": ["-w", "--no-password"], "signature": "-w --no-password", "description": "Never issue a password prompt. If the server requires password authentication and a password is not available by other means such as a .pgpass 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."}, {"names": ["-W", "--password"], "signature": "-W --password", "description": "Force pg_amcheck to prompt for a password before connecting to a database. This option is never essential, since pg_amcheck will automatically prompt for a password if the server demands password authentication. However, pg_amcheck will waste a connection attempt finding out that the server wants a password. In some cases it is worth typing -W to avoid the extra connection attempt."}, {"names": ["--maintenance-db= dbname"], "signature": "--maintenance-db= dbname", "description": "Specifies a database or connection string to be used to discover the list of databases to be checked. If neither --all nor any option including a database pattern is used, no such connection is required and this option does nothing. Otherwise, any connection string parameters other than the database name which are included in the value for this option will also be used when connecting to the databases being checked. If this option is omitted, the default is postgres or, if that fails, template1 ."}, {"names": ["-e", "--echo"], "signature": "-e --echo", "description": "Echo to stdout all SQL sent to the server."}, {"names": ["-j num", "--jobs= num"], "signature": "-j num --jobs= num", "description": "Use num concurrent connections to the server, or one per object to be checked, whichever is less. The default is to use a single connection."}, {"names": ["-P", "--progress"], "signature": "-P --progress", "description": "Show progress information. Progress information includes the number of relations for which checking has been completed, and the total size of those relations. It also includes the total number of relations that will eventually be checked, and the estimated size of those relations."}, {"names": ["-v", "--verbose"], "signature": "-v --verbose", "description": "Print more messages. In particular, this will print a message for each relation being checked, and will increase the level of detail shown for server errors."}, {"names": ["-V", "--version"], "signature": "-V --version", "description": "Print the pg_amcheck version and exit."}, {"names": ["--install-missing", "--install-missing= schema"], "signature": "--install-missing --install-missing= schema", "description": "Install any missing extensions that are required to check the database(s). If not yet installed, each extension's objects will be installed into the given schema , or if not specified into schema pg_catalog . At present, the only required extension is amcheck ."}, {"names": ["-?", "--help"], "signature": "-? --help", "description": "Show help about pg_amcheck command line arguments, and exit."}], "synopsis": ["pg_amcheck [ option ...] [ dbname ]"], "environment": []}, "comparison_hash": "e007a3ce54383d588583bd426bfaa62aba42504ba26ff80ad24c0c65d13af539", "manual_language": "zh"}, "comparison": {"left": "14", "right": "15", "status": "changed", "diff": "--- PostgreSQL 14\n+++ PostgreSQL 15\n@@ -26,7 +26,7 @@\n       \"signature\": \"-D pattern --exclude-database= pattern\"\n     },\n     {\n-      \"description\": \"Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not tables.\",\n+      \"description\": \"Check indexes matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to indexes, not to other relation types.\",\n       \"names\": [\n         \"-i pattern\",\n         \"--index= pattern\"\n@@ -34,7 +34,7 @@\n       \"signature\": \"-i pattern --index= pattern\"\n     },\n     {\n-      \"description\": \"Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not tables.\",\n+      \"description\": \"Exclude indexes matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to indexes, not other relation types.\",\n       \"names\": [\n         \"-I pattern\",\n         \"--exclude-index= pattern\"\n@@ -74,7 +74,7 @@\n       \"signature\": \"-S pattern --exclude-schema= pattern\"\n     },\n     {\n-      \"description\": \"Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, not indexes.\",\n+      \"description\": \"Check tables matching the specified pattern , unless they are otherwise excluded. This option can be specified more than once. This is similar to the --relation option, except that it applies only to tables, materialized views, and sequences, not to indexes.\",\n       \"names\": [\n         \"-t pattern\",\n         \"--table= pattern\"\n@@ -82,7 +82,7 @@\n       \"signature\": \"-t pattern --table= pattern\"\n     },\n     {\n-      \"description\": \"Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, not indexes.\",\n+      \"description\": \"Exclude tables matching the specified pattern . This option can be specified more than once. This is similar to the --exclude-relation option, except that it applies only to tables, materialized views, and sequences, not to indexes.\",\n       \"names\": [\n         \"-T pattern\",\n         \"--exclude-table= pattern\""}}