|
1 | | -<!-- $PostgreSQL: pgsql/doc/src/sgml/monitoring.sgml,v 1.82 2010/08/08 16:27:03 tgl Exp $ --> |
| 1 | +<!-- $PostgreSQL: pgsql/doc/src/sgml/monitoring.sgml,v 1.83 2010/08/14 02:22:10 rhaas Exp $ --> |
2 | 2 |
|
3 | 3 | <chapter id="monitoring"> |
4 | 4 | <title>Monitoring Database Activity</title> |
@@ -1436,26 +1436,28 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS procpid, |
1436 | 1436 | </row> |
1437 | 1437 | <row> |
1438 | 1438 | <entry>buffer-read-start</entry> |
1439 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid,bool, bool)</entry> |
| 1439 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid,int, bool)</entry> |
1440 | 1440 | <entry>Probe that fires when a buffer read is started. |
1441 | 1441 | arg0 and arg1 contain the fork and block numbers of the page (but |
1442 | 1442 | arg1 will be -1 if this is a relation extension request). |
1443 | 1443 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1444 | 1444 | identifying the relation. |
1445 | | - arg5 is true for a local buffer, false for a shared buffer. |
| 1445 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1446 | + local buffer, or InvalidBackendId (-1) for a shared buffer. |
1446 | 1447 | arg6 is true for a relation extension request, false for normal |
1447 | 1448 | read.</entry> |
1448 | 1449 | </row> |
1449 | 1450 | <row> |
1450 | 1451 | <entry>buffer-read-done</entry> |
1451 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid,bool, bool, bool)</entry> |
| 1452 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid,int, bool, bool)</entry> |
1452 | 1453 | <entry>Probe that fires when a buffer read is complete. |
1453 | 1454 | arg0 and arg1 contain the fork and block numbers of the page (if this |
1454 | 1455 | is a relation extension request, arg1 now contains the block number |
1455 | 1456 | of the newly added block). |
1456 | 1457 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1457 | 1458 | identifying the relation. |
1458 | | - arg5 is true for a local buffer, false for a shared buffer. |
| 1459 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1460 | + local buffer, or InvalidBackendId (-1) for a shared buffer. |
1459 | 1461 | arg6 is true for a relation extension request, false for normal |
1460 | 1462 | read. |
1461 | 1463 | arg7 is true if the buffer was found in the pool, false if not.</entry> |
@@ -1521,38 +1523,46 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS procpid, |
1521 | 1523 | </row> |
1522 | 1524 | <row> |
1523 | 1525 | <entry>smgr-md-read-start</entry> |
1524 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid)</entry> |
| 1526 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int)</entry> |
1525 | 1527 | <entry>Probe that fires when beginning to read a block from a relation. |
1526 | 1528 | arg0 and arg1 contain the fork and block numbers of the page. |
1527 | 1529 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1528 | | - identifying the relation.</entry> |
| 1530 | + identifying the relation. |
| 1531 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1532 | + local buffer, or InvalidBackendId (-1) for a shared buffer.</entry> |
1529 | 1533 | </row> |
1530 | 1534 | <row> |
1531 | 1535 | <entry>smgr-md-read-done</entry> |
1532 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int)</entry> |
| 1536 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int, int)</entry> |
1533 | 1537 | <entry>Probe that fires when a block read is complete. |
1534 | 1538 | arg0 and arg1 contain the fork and block numbers of the page. |
1535 | 1539 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1536 | 1540 | identifying the relation. |
1537 | | - arg5 is the number of bytes actually read, while arg6 is the number |
| 1541 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1542 | + local buffer, or InvalidBackendId (-1) for a shared buffer. |
| 1543 | + arg6 is the number of bytes actually read, while arg7 is the number |
1538 | 1544 | requested (if these are different it indicates trouble).</entry> |
1539 | 1545 | </row> |
1540 | 1546 | <row> |
1541 | 1547 | <entry>smgr-md-write-start</entry> |
1542 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid)</entry> |
| 1548 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int)</entry> |
1543 | 1549 | <entry>Probe that fires when beginning to write a block to a relation. |
1544 | 1550 | arg0 and arg1 contain the fork and block numbers of the page. |
1545 | 1551 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1546 | | - identifying the relation.</entry> |
| 1552 | + identifying the relation. |
| 1553 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1554 | + local buffer, or InvalidBackendId (-1) for a shared buffer.</entry> |
1547 | 1555 | </row> |
1548 | 1556 | <row> |
1549 | 1557 | <entry>smgr-md-write-done</entry> |
1550 | | - <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int)</entry> |
| 1558 | + <entry>(ForkNumber, BlockNumber, Oid, Oid, Oid, int, int, int)</entry> |
1551 | 1559 | <entry>Probe that fires when a block write is complete. |
1552 | 1560 | arg0 and arg1 contain the fork and block numbers of the page. |
1553 | 1561 | arg2, arg3, and arg4 contain the tablespace, database, and relation OIDs |
1554 | 1562 | identifying the relation. |
1555 | | - arg5 is the number of bytes actually written, while arg6 is the number |
| 1563 | + arg5 is the ID of the backend which created the temporary relation for a |
| 1564 | + local buffer, or InvalidBackendId (-1) for a shared buffer. |
| 1565 | + arg6 is the number of bytes actually written, while arg7 is the number |
1556 | 1566 | requested (if these are different it indicates trouble).</entry> |
1557 | 1567 | </row> |
1558 | 1568 | <row> |
|