SHOW STATUS
功能描述
SHOW STATUS 显示系统当前统计状态所有值的数据。 该语句不需要任何特权。它仅需要连接到服务器的能力。
注意事项
N/A
语法格式
1. SHOW [GLOBAL | SESSION] STATUS
2. [LIKE 'pattern' | WHERE expr]
示例
1. openGauss=# show status;
2. Variable_name | Value
3. --------------------------------------+-------------------------------
4. apply_counter | 0
5. apply_total_dur | 0
6. avgiotim | 11
7. bg_commit_counter | 14
8. bg_resp_avg | 2380520
9. bg_resp_max | 7032370
10. bg_resp_min | 160
11. bg_resp_total | 33327281
12. bg_rollback_counter | 0
13. blk_read_time | 0
14. blks_hit | 475019
15. blks_read | 1296
16. blk_write_time | 0
17. buffers_alloc | 0
18. buffers_backend | 0
19. buffers_backend_fsync | 0
20. buffers_checkpoint | 0
21. buffers_clean | 0
22. checkpoints_req | 4
23. checkpoints_timed | 27
24. checkpoint_sync_time | 6376
25. checkpoint_write_time | 5
26. ckpt_clog_flush_num | 0
27. ckpt_csnlog_flush_num | 0
28. ckpt_multixact_flush_num | 0
29. ckpt_predicate_flush_num | 0
30. ckpt_redo_point | 0/28DDB58
31. ckpt_twophase_flush_num | 0
32. commit_counter | 5
33. confl_bufferpin | 0
34. confl_deadlock | 0
35. conflicts | 0
36. confl_lock | 0
37. confl_snapshot | 0
38. confl_tablespace | 0
39. curr_dwn | 0
40. current_xlog_insert_lsn | 0/28DDF28
41. curr_start_page | 1661
42. curr_time | 1
43. datid | 16384
44. datname | tt
45. dcl_count | 0
46. ddl_count | 0
47. deadlocks | 0
48. delete_count | 0
49. dml_count | 8
50. file_id | 0
51. file_reset_num | 0
52. file_trunc_num | 0
53. global_instance_time_count | 10
54. high_threshold_pages | 0
55. high_threshold_writes | 0
56. insert_count | 0
57. last_replayed_read_ptr | 0
58. local_max_ptr | 0
59. locks_count | 43
60. login_counter | 3
61. logout_counter | 2
62. low_threshold_pages | 17
63. low_threshold_writes | 2
64. lstiotim | 10
65. maxiowtm | 32
66. maxwritten_clean | 0
67. miniotim | 3
68. min_recovery_point | 0
69. node_name | single_node1
70. numbackends | 1
71. os_runtime_count | 19
72. os_threads_count | 23
73. p80 | 0
74. p95 | 0
75. pgwr_actual_flush_total_num | 7
76. pgwr_last_flush_num | 7
77. phyblkrd | 501
78. phyblkwrt | 7
79. phyblkwrt | 6
80. phyrds | 501
81. phywrts | 6
82. phywrts | 7
83. primary_flush_ptr | 42852136
84. process_pending_counter | 0
85. process_pending_total_dur | 0
86. queue_head_page_rec_lsn | 0/28DDB58
87. queue_rec_lsn | 0/28DDB58
88. read_data_io_counter | 0
89. read_data_io_total_dur | 0
90. read_ptr | 42851160
91. read_xlog_io_counter | 2
92. read_xlog_io_total_dur | 471
93. recovery_done_ptr | 0
94. redo_done_time | 0
95. redo_start_ptr | 42851160
96. redo_start_time | 732333220674305
97. remain_dirty_page_num | 3
98. resp_avg | 8090
99. resp_max | 35491
100. resp_min | 140
101. resp_total | 40449
102. rollback_counter | 0
103. select_count | 5
104. single_node1-backend_used_memory | 1
105. single_node1-cstore_used_memory | 0
106. single_node1-dynamic_peak_memory | 562
107. single_node1-dynamic_peak_shrctx | 180
108. single_node1-dynamic_used_memory | 561
109. single_node1-dynamic_used_shrctx | 180
110. single_node1-gpu_dynamic_peak_memory | 0
111. single_node1-gpu_dynamic_used_memory | 0
112. single_node1-gpu_max_dynamic_memory | 0
113. single_node1-max_backend_memory | 348
114. single_node1-max_cstore_memory | 512
115. single_node1-max_dynamic_memory | 8142
116. single_node1-max_process_memory | 12288
117. single_node1-max_sctpcomm_memory | 0
118. single_node1-max_shared_memory | 3285
119. single_node1-other_used_memory | 0
120. single_node1-pooler_conn_memory | 0
121. single_node1-pooler_freeconn_memory | 0
122. single_node1-process_used_memory | 800
123. single_node1-sctpcomm_peak_memory | 0
124. single_node1-sctpcomm_used_memory | 0
125. single_node1-shared_used_memory | 215
126. single_node1-storage_compress_memory | 0
127. single_node1-udf_reserved_memory | 0
128. speed | 0
129. stats_reset | 2023-03-16 17:34:43.424584+08
130. stats_reset | 2023-03-16 17:34:25.277803+08
131. summary_file_iostat_count | 62
132. temp_bytes | 0
133. temp_files | 0
134. total_pages | 17
135. total_writes | 2
136. tup_deleted | 61
137. tup_fetched | 64396
138. tup_inserted | 9906
139. tup_returned | 55952
140. tup_updated | 305
141. update_count | 0
142. user_id | 10
143. user_name | hlv
144. wait_events_count | 401
145. worker_info | no redo worker
146. workload | default_pool
147. write_data_io_counter | 0
148. write_data_io_total_dur | 0
149. writetim | 75
150. xact_commit | 1235
151. xact_rollback | 28
152. (148 rows)
154. openGauss=# show global status;
155. Variable_name | Value
156. --------------------------------------+-------------------------------
157. apply_counter | 0
158. apply_total_dur | 0
159. avgiotim | 10
160. bg_commit_counter | 168
161. bg_resp_avg | 53200083
162. bg_resp_max | 122185319
163. bg_resp_min | 79
164. bg_resp_total | 8937613869
165. bg_rollback_counter | 2
166. blk_read_time | 0
167. blks_hit | 504050
168. blks_read | 1444
169. blk_write_time | 0
170. buffers_alloc | 0
171. buffers_backend | 0
172. buffers_backend_fsync | 0
173. buffers_checkpoint | 0
174. buffers_clean | 0
175. checkpoints_req | 4
176. checkpoints_timed | 29
177. checkpoint_sync_time | 6794
178. checkpoint_write_time | 5
179. ckpt_clog_flush_num | 1
180. ckpt_csnlog_flush_num | 0
181. ckpt_multixact_flush_num | 1
182. ckpt_predicate_flush_num | 0
183. ckpt_redo_point | 0/28DE060
184. ckpt_twophase_flush_num | 0
185. commit_counter | 10
186. confl_bufferpin | 0
187. confl_deadlock | 0
188. conflicts | 0
189. confl_lock | 0
190. confl_snapshot | 0
191. confl_tablespace | 0
192. curr_dwn | 0
193. current_xlog_insert_lsn | 0/28DE180
194. curr_start_page | 1684
195. curr_time | 1
196. datid | 16384
197. datname | tt
198. dcl_count | 0
199. ddl_count | 0
200. deadlocks | 0
201. delete_count | 0
202. dml_count | 21
203. file_id | 0
204. file_reset_num | 0
205. file_trunc_num | 2
206. global_instance_time_count | 10
207. high_threshold_pages | 0
208. high_threshold_writes | 0
209. insert_count | 0
210. last_replayed_read_ptr | 0
211. local_max_ptr | 0
212. locks_count | 44
213. login_counter | 9
214. logout_counter | 8
215. low_threshold_pages | 27
216. low_threshold_writes | 4
217. lstiotim | 8
218. maxiowtm | 32
219. maxwritten_clean | 0
220. miniotim | 3
221. min_recovery_point | 0
222. node_name | single_node1
223. numbackends | 1
224. os_runtime_count | 19
225. os_threads_count | 23
226. p80 | 0
227. p95 | 0
228. pgwr_actual_flush_total_num | 10
229. pgwr_last_flush_num | 3
230. phyblkrd | 520
231. phyblkwrt | 10
232. phyblkwrt | 8
233. phyrds | 520
234. phywrts | 8
235. phywrts | 9
236. primary_flush_ptr | 42852736
237. process_pending_counter | 0
238. process_pending_total_dur | 0
239. queue_head_page_rec_lsn | 0/0
240. queue_rec_lsn | 0/28DE060
241. read_data_io_counter | 0
242. read_data_io_total_dur | 0
243. read_ptr | 42851160
244. read_xlog_io_counter | 2
245. read_xlog_io_total_dur | 471
246. recovery_done_ptr | 0
247. redo_done_time | 0
248. redo_start_ptr | 42851160
249. redo_start_time | 732333220674305
250. remain_dirty_page_num | 0
251. resp_avg | 47907
252. resp_max | 254914
253. resp_min | 116
254. resp_total | 479066
255. rollback_counter | 0
256. select_count | 15
257. single_node1-backend_used_memory | 1
258. single_node1-cstore_used_memory | 0
259. single_node1-dynamic_peak_memory | 571
260. single_node1-dynamic_peak_shrctx | 181
261. single_node1-dynamic_used_memory | 558
262. single_node1-dynamic_used_shrctx | 181
263. single_node1-gpu_dynamic_peak_memory | 0
264. single_node1-gpu_dynamic_used_memory | 0
265. single_node1-gpu_max_dynamic_memory | 0
266. single_node1-max_backend_memory | 348
267. single_node1-max_cstore_memory | 512
268. single_node1-max_dynamic_memory | 8142
269. single_node1-max_process_memory | 12288
270. single_node1-max_sctpcomm_memory | 0
271. single_node1-max_shared_memory | 3285
272. single_node1-other_used_memory | 0
273. single_node1-pooler_conn_memory | 0
274. single_node1-pooler_freeconn_memory | 0
275. single_node1-process_used_memory | 806
276. single_node1-sctpcomm_peak_memory | 0
277. single_node1-sctpcomm_used_memory | 0
278. single_node1-shared_used_memory | 220
279. single_node1-storage_compress_memory | 0
280. single_node1-udf_reserved_memory | 0
281. speed | 0
282. stats_reset | 2023-03-16 17:34:25.277803+08
283. stats_reset | 2023-03-16 17:34:43.424584+08
284. summary_file_iostat_count | 65
285. temp_bytes | 0
286. temp_files | 0
287. total_pages | 27
288. total_writes | 4
289. tup_deleted | 61
290. tup_fetched | 68794
291. tup_inserted | 9906
292. tup_returned | 59299
293. tup_updated | 305
294. update_count | 0
295. user_id | 10
296. user_name | hlv
297. wait_events_count | 401
298. worker_info | no redo worker
299. workload | default_pool
300. write_data_io_counter | 0
301. write_data_io_total_dur | 0
302. writetim | 93
303. xact_commit | 1324
304. xact_rollback | 30
305. (148 rows)
307. openGauss=# show session status;
308. Variable_name | Value
309. --------------------------------------+-------------------------------
310. apply_counter | 0
311. apply_total_dur | 0
312. avgiotim | 10
313. bg_commit_counter | 168
314. bg_resp_avg | 53200083
315. bg_resp_max | 122185319
316. bg_resp_min | 79
317. bg_resp_total | 8937613869
318. bg_rollback_counter | 2
319. blk_read_time | 0
320. blks_hit | 504050
321. blks_read | 1444
322. blk_write_time | 0
323. buffers_alloc | 0
324. buffers_backend | 0
325. buffers_backend_fsync | 0
326. buffers_checkpoint | 0
327. buffers_clean | 0
328. checkpoints_req | 4
329. checkpoints_timed | 29
330. checkpoint_sync_time | 6794
331. checkpoint_write_time | 5
332. ckpt_clog_flush_num | 1
333. ckpt_csnlog_flush_num | 0
334. ckpt_multixact_flush_num | 1
335. ckpt_predicate_flush_num | 0
336. ckpt_redo_point | 0/28DE060
337. ckpt_twophase_flush_num | 0
338. commit_counter | 10
339. confl_bufferpin | 0
340. confl_deadlock | 0
341. conflicts | 0
342. confl_lock | 0
343. confl_snapshot | 0
344. confl_tablespace | 0
345. curr_dwn | 0
346. current_xlog_insert_lsn | 0/28DE180
347. curr_start_page | 1684
348. curr_time | 1
349. datid | 16384
350. datname | tt
351. dcl_count | 0
352. ddl_count | 0
353. deadlocks | 0
354. delete_count | 0
355. dml_count | 21
356. file_id | 0
357. file_reset_num | 0
358. file_trunc_num | 2
359. global_instance_time_count | 10
360. high_threshold_pages | 0
361. high_threshold_writes | 0
362. insert_count | 0
363. last_replayed_read_ptr | 0
364. local_max_ptr | 0
365. locks_count | 44
366. login_counter | 9
367. logout_counter | 8
368. low_threshold_pages | 27
369. low_threshold_writes | 4
370. lstiotim | 8
371. maxiowtm | 32
372. maxwritten_clean | 0
373. miniotim | 3
374. min_recovery_point | 0
375. node_name | single_node1
376. numbackends | 1
377. os_runtime_count | 19
378. os_threads_count | 23
379. p80 | 0
380. p95 | 0
381. pgwr_actual_flush_total_num | 10
382. pgwr_last_flush_num | 3
383. phyblkrd | 520
384. phyblkwrt | 10
385. phyblkwrt | 8
386. phyrds | 520
387. phywrts | 8
388. phywrts | 9
389. primary_flush_ptr | 42852736
390. process_pending_counter | 0
391. process_pending_total_dur | 0
392. queue_head_page_rec_lsn | 0/0
393. queue_rec_lsn | 0/28DE060
394. read_data_io_counter | 0
395. read_data_io_total_dur | 0
396. read_ptr | 42851160
397. read_xlog_io_counter | 2
398. read_xlog_io_total_dur | 471
399. recovery_done_ptr | 0
400. redo_done_time | 0
401. redo_start_ptr | 42851160
402. redo_start_time | 732333220674305
403. remain_dirty_page_num | 0
404. resp_avg | 47907
405. resp_max | 254914
406. resp_min | 116
407. resp_total | 479066
408. rollback_counter | 0
409. select_count | 15
410. single_node1-backend_used_memory | 1
411. single_node1-cstore_used_memory | 0
412. single_node1-dynamic_peak_memory | 571
413. single_node1-dynamic_peak_shrctx | 181
414. single_node1-dynamic_used_memory | 558
415. single_node1-dynamic_used_shrctx | 181
416. single_node1-gpu_dynamic_peak_memory | 0
417. single_node1-gpu_dynamic_used_memory | 0
418. single_node1-gpu_max_dynamic_memory | 0
419. single_node1-max_backend_memory | 348
420. single_node1-max_cstore_memory | 512
421. single_node1-max_dynamic_memory | 8142
422. single_node1-max_process_memory | 12288
423. single_node1-max_sctpcomm_memory | 0
424. single_node1-max_shared_memory | 3285
425. single_node1-other_used_memory | 0
426. single_node1-pooler_conn_memory | 0
427. single_node1-pooler_freeconn_memory | 0
428. single_node1-process_used_memory | 806
429. single_node1-sctpcomm_peak_memory | 0
430. single_node1-sctpcomm_used_memory | 0
431. single_node1-shared_used_memory | 220
432. single_node1-storage_compress_memory | 0
433. single_node1-udf_reserved_memory | 0
434. speed | 0
435. stats_reset | 2023-03-16 17:34:25.277803+08
436. stats_reset | 2023-03-16 17:34:43.424584+08
437. summary_file_iostat_count | 65
438. temp_bytes | 0
439. temp_files | 0
440. total_pages | 27
441. total_writes | 4
442. tup_deleted | 61
443. tup_fetched | 68794
444. tup_inserted | 9906
445. tup_returned | 59299
446. tup_updated | 305
447. update_count | 0
448. user_id | 10
449. user_name | hlv
450. wait_events_count | 401
451. worker_info | no redo worker
452. workload | default_pool
453. write_data_io_counter | 0
454. write_data_io_total_dur | 0
455. writetim | 93
456. xact_commit | 1324
457. xact_rollback | 30
458. (148 rows)
460. openGauss=# show status like 'xact%';
461. Variable_name | Value
462. ---------------+-------
463. xact_commit | 1390
464. xact_rollback | 31
465. (2 rows)
467. openGauss=# show status where variable_name = 'ckpt_redo_point';
468. Variable_name | Value
469. -----------------+-----------
470. ckpt_redo_point | 0/28DE2A0
471. (1 row)
