forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitad8b674
committed
Shut down transaction tracking at startup process exit.
Maxim Orlov reported that the shutdown of standby server could result inthe following assertion failure. The cause of this issue was that,when the shutdown caused the startup process to exit, recovery-timetransaction tracking was not shut down even if it's already initialized,and some locks the tracked transactions were holding could not be released.At this situation, if other process was invoked and the PGPROC entry thatthe startup process used was assigned to it, it found such unreleased locksand caused the assertion failure, during the initialization of it. TRAP: FailedAssertion("SHMQueueEmpty(&(MyProc->myProcLocks[i]))"This commit fixes this issue by making the startup process shut downtransaction tracking and release all locks, at the exit of it.Back-patch to all supported branches.Reported-by: Maxim OrlovAuthor: Fujii MasaoReviewed-by: Maxim OrlovDiscussion:https://postgr.es/m/ad4ce692cc1d89a093b471ab1d969b0b@postgrespro.ru1 parent6734e80 commitad8b674
2 files changed
+34
-0
lines changedLines changed: 19 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
62 | 62 |
| |
63 | 63 |
| |
64 | 64 |
| |
| 65 | + | |
| 66 | + | |
| 67 | + | |
65 | 68 |
| |
66 | 69 |
| |
67 | 70 |
| |
| |||
183 | 186 |
| |
184 | 187 |
| |
185 | 188 |
| |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
186 | 202 |
| |
187 | 203 |
| |
188 | 204 |
| |
189 | 205 |
| |
190 | 206 |
| |
191 | 207 |
| |
192 | 208 |
| |
| 209 | + | |
| 210 | + | |
| 211 | + | |
193 | 212 |
| |
194 | 213 |
| |
195 | 214 |
| |
|
Lines changed: 15 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
127 | 127 |
| |
128 | 128 |
| |
129 | 129 |
| |
| 130 | + | |
| 131 | + | |
| 132 | + | |
| 133 | + | |
| 134 | + | |
| 135 | + | |
130 | 136 |
| |
131 | 137 |
| |
132 | 138 |
| |
133 | 139 |
| |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
134 | 149 |
| |
135 | 150 |
| |
136 | 151 |
| |
|
0 commit comments
Comments
(0)