forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commit1ca64f6
Add GUC parameter "huge_pages_status"
This is useful to show the allocation state of huge pages when settingup a server with "huge_pages = try", where allocating huge pages wouldbe attempted but the server would continue its startup sequence even ifthe allocation fails. The effective status of huge pages is not easilyvisible without OS-level tools (or for instance, a lookup at/proc/N/smaps), and the environments where Postgres runs may notauthorize that. Like the other GUCs related to huge pages, this worksfor Linux and Windows.This GUC can report as values:- "on", if huge pages were allocated.- "off", if huge pages were not allocated.- "unknown", a special state that could only be seen when using forexample postgres -C because it is only possible to know if the sharedmemory allocation worked after we can check for the GUC values, even ifchecking a runtime-computed GUC. This value should never be seen whenquerying for the GUC on a running server. An assertion is added tocheck that.The discussion has also turned around having a new function to grab thisstatus, but this would have required more tricks for -DEXEC_BACKEND,something that GUCs already handle.Noriyoshi Shinoda has initiated the thread that has led to the result ofthis commit.Author: Justin PryzbyReviewed-by: Nathan Bossart, Kyotaro Horiguchi, Michael PaquierDiscussion:https://postgr.es/m/TU4PR8401MB1152EBB0D271F827E2E37A01EECC9@TU4PR8401MB1152.NAMPRD84.PROD.OUTLOOK.COM1 parent8c80bdd commit1ca64f6
File tree
8 files changed
+80
-3
lines changed- doc/src/sgml
- src
- backend
- port
- storage/ipc
- utils/misc
- include/storage
- test/authentication/t
8 files changed
+80
-3
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1727 | 1727 | | |
1728 | 1728 | | |
1729 | 1729 | | |
1730 | | - | |
| 1730 | + | |
| 1731 | + | |
| 1732 | + | |
1731 | 1733 | | |
1732 | 1734 | | |
1733 | 1735 | | |
| |||
10738 | 10740 | | |
10739 | 10741 | | |
10740 | 10742 | | |
| 10743 | + | |
| 10744 | + | |
| 10745 | + | |
| 10746 | + | |
| 10747 | + | |
| 10748 | + | |
| 10749 | + | |
| 10750 | + | |
| 10751 | + | |
| 10752 | + | |
| 10753 | + | |
| 10754 | + | |
| 10755 | + | |
| 10756 | + | |
| 10757 | + | |
| 10758 | + | |
| 10759 | + | |
| 10760 | + | |
| 10761 | + | |
10741 | 10762 | | |
10742 | 10763 | | |
10743 | 10764 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
627 | 627 | | |
628 | 628 | | |
629 | 629 | | |
| 630 | + | |
| 631 | + | |
| 632 | + | |
| 633 | + | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
630 | 638 | | |
631 | 639 | | |
632 | 640 | | |
| |||
737 | 745 | | |
738 | 746 | | |
739 | 747 | | |
| 748 | + | |
740 | 749 | | |
741 | 750 | | |
| 751 | + | |
| 752 | + | |
| 753 | + | |
| 754 | + | |
| 755 | + | |
742 | 756 | | |
743 | 757 | | |
744 | 758 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
401 | 401 | | |
402 | 402 | | |
403 | 403 | | |
| 404 | + | |
| 405 | + | |
| 406 | + | |
| 407 | + | |
| 408 | + | |
404 | 409 | | |
405 | 410 | | |
406 | 411 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
190 | 190 | | |
191 | 191 | | |
192 | 192 | | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
193 | 200 | | |
194 | 201 | | |
195 | 202 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
365 | 365 | | |
366 | 366 | | |
367 | 367 | | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
368 | 375 | | |
369 | 376 | | |
370 | 377 | | |
| |||
550 | 557 | | |
551 | 558 | | |
552 | 559 | | |
| 560 | + | |
553 | 561 | | |
554 | 562 | | |
555 | 563 | | |
| |||
4876 | 4884 | | |
4877 | 4885 | | |
4878 | 4886 | | |
| 4887 | + | |
| 4888 | + | |
| 4889 | + | |
| 4890 | + | |
| 4891 | + | |
| 4892 | + | |
| 4893 | + | |
| 4894 | + | |
| 4895 | + | |
| 4896 | + | |
| 4897 | + | |
4879 | 4898 | | |
4880 | 4899 | | |
4881 | 4900 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
46 | 46 | | |
47 | 47 | | |
48 | 48 | | |
49 | | - | |
| 49 | + | |
50 | 50 | | |
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
| 55 | + | |
55 | 56 | | |
56 | 57 | | |
57 | 58 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
100 | 100 | | |
101 | 101 | | |
102 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
103 | 109 | | |
104 | 110 | | |
105 | 111 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
21 | 21 | | |
22 | 22 | | |
23 | 23 | | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
24 | 28 | | |
25 | 29 | | |
26 | 30 | | |
| |||
0 commit comments
Comments
(0)