10.4. Preparing the Database for the Web

Open source databases play a major role in today's Web environments. Especially for complex Web applications, PostgreSQL is a good choice. To use PostgreSQL efficiently, the database should be configured to satisfy the demands of a modern IT environment. Depending on the kind of application you want to run, the best settings for your database might vary.

In this section a few basic rules will be presented.

10.4.1. Memory

Tuning PostgreSQL's memory management is an important task. The first thing is to find out if the applications you are going to run contain complex queries or a set of simple queries. If you run only a few complex queries, it won't be necessary to change the maximum number of connections ...

Get PHP and PostgreSQL: Advanced Web Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.