AFAICT pgsql controls this with the random_page_cost and seq_page_cost variables [1], which are relative and seem to default to 4 and 1 respectively. It doesn&#x27;t look like these are automatically adjusted though based on the hardware.<p>Some searching and I found some blog posts suggesting lowering them both to closer to one on SSDs [2]. Indeed, the documentation says you can set them both to 1 if you are sure that the database will be fully cached in RAM.<p>[1] <a href="http:&#x2F;&#x2F;www.postgresql.org&#x2F;docs&#x2F;current&#x2F;static&#x2F;runtime-config-query.html" rel="nofollow">http:&#x2F;&#x2F;www.postgresql.org&#x2F;docs&#x2F;current&#x2F;static&#x2F;runtime-config...</a>
[2] <a href="http:&#x2F;&#x2F;www.cybertec.at&#x2F;2013&#x2F;01&#x2F;better-postgresql-performance-on-ssds&#x2F;" rel="nofollow">http:&#x2F;&#x2F;www.cybertec.at&#x2F;2013&#x2F;01&#x2F;better-postgresql-performance...</a>