Increase work_mem to 48MB for postgres.

The old size was too small for some installations.
(cherry picked from commit 698d512ef4e9c6f42604d1b741f08b1588127493)