"By default, VACUUM skips the sort phase for any table where more than 95 percent of the table's rows are already sorted" Is there a reason why the default is 95 and not 100?
Is the performance increase of a 100% to 95% sorted table negligible?
VACUUM
is a very intensive operation. The performance benefits of having a 95% vs 100% sorted table is minimal. Therefore, it is saving a lot of wasted effort in the VACUUM
operation.
The VACUUM documentation says:
By default, VACUUM skips the sort phase for any table where more than 95 percent of the table's rows are already sorted. Skipping the sort phase can significantly improve VACUUM performance. To change the default sort or delete threshold for a single table, include the table name and the TO threshold PERCENT parameter when you run VACUUM.
Therefore, you can always force a 100% sort if desired.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.