Commit 7bb3102
committed
Don't use _mdfd_getseg() in mdsyncfiletag().
_mdfd_getseg() opens all segments up to the requested one. That
causes problems for mdsyncfiletag(), if mdunlinkfork() has
already unlinked other segment files. Open the file we want
directly by name instead, if it's not already open.
The consequence of this bug was a rare panic in the checkpointer,
made more likely if you saturated the sync request queue so that
the SYNC_FORGET_REQUEST messages for a given relation were more
likely to be absorbed in separate cycles by the checkpointer.
Back-patch to 12. Defect in commit 3eb77eb.
Author: Thomas Munro
Reported-by: Justin Pryzby
Discussion: https://postgr.es/m/20191119115759.GI30362%40telsasoft.com1 parent a7ee7c8 commit 7bb3102
1 file changed
+40
-17
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1280 | 1280 | | |
1281 | 1281 | | |
1282 | 1282 | | |
1283 | | - | |
1284 | | - | |
| 1283 | + | |
| 1284 | + | |
| 1285 | + | |
| 1286 | + | |
1285 | 1287 | | |
1286 | | - | |
1287 | | - | |
1288 | | - | |
1289 | | - | |
| 1288 | + | |
| 1289 | + | |
| 1290 | + | |
| 1291 | + | |
| 1292 | + | |
| 1293 | + | |
| 1294 | + | |
| 1295 | + | |
| 1296 | + | |
| 1297 | + | |
| 1298 | + | |
| 1299 | + | |
| 1300 | + | |
| 1301 | + | |
| 1302 | + | |
| 1303 | + | |
| 1304 | + | |
| 1305 | + | |
| 1306 | + | |
| 1307 | + | |
| 1308 | + | |
| 1309 | + | |
| 1310 | + | |
| 1311 | + | |
| 1312 | + | |
| 1313 | + | |
| 1314 | + | |
| 1315 | + | |
| 1316 | + | |
| 1317 | + | |
| 1318 | + | |
| 1319 | + | |
| 1320 | + | |
| 1321 | + | |
| 1322 | + | |
1290 | 1323 | | |
1291 | | - | |
1292 | | - | |
1293 | | - | |
1294 | | - | |
1295 | | - | |
1296 | | - | |
1297 | | - | |
1298 | | - | |
1299 | | - | |
1300 | | - | |
1301 | | - | |
| 1324 | + | |
1302 | 1325 | | |
1303 | 1326 | | |
1304 | 1327 | | |
| |||
0 commit comments