On Wed, 2005-02-23 at 19:31 -0500, Tom Lane wrote: > Ron Mayer <rm_pg@xxxxxxxxxxxxxxxxxxxxxxx> writes: > > + if (needed > MaxFSMPages) > > + ereport(WARNING, > > + (errmsg("max_fsm_pages(%d) is smaller than total pages needed(%.0f)", > > + MaxFSMPages, needed))); > > An unconditional WARNING seems a bit strong to me for a case that is not > necessarily wrong. Depending on the needs of the installation, this > might be a perfectly acceptable situation --- for example if you have > lots of large read-mostly tables. The patch seems very useful to me. I had been thinking about doing something like that myself. VACUUM uses an INFO to provide the "total pages needed", so it should be a simple matter to change the ereport to an INFO rather than WARNING as well. It would be great to have both lines of INFO, so that VACUUM would produce output like this: patched=# vacuum; INFO: free space map: 77 relations, 470 pages stored INFO: max_fsm_pages(1601) is smaller than total pages needed(2832) DETAIL: Allocated FSM size: 100 relations + 1601 pages = 19 kB shared memory. VACUUM ...where the second info line was conditional...like this... + if (numRels == MaxFSMRelations) + ereport(WARNING, + (errmsg("max_fsm_relations(%d) may be set too low", + MaxFSMRelations))); + else + if (needed > MaxFSMPages) + ereport(INFO, + (errmsg("max_fsm_pages(%d) is smaller than total pages needed(%.0f)", + MaxFSMPages, needed))); ereport(elevel, (errmsg("free space map: %d relations, %d pages stored; %.0f total pages needed", Which goes more towards Tom's gripes. The manual could have a line added to explain that if max_fsm_relations is set too low, then max_fsm_pages may also inadvertently be too low, yet not be obvious that that is the case. Best Regards, Simon Riggs ---------------------------(end of broadcast)--------------------------- TIP 1: subscribe and unsubscribe commands go to majordomo@xxxxxxxxxxxxxx