PostgreSQL is out of control: high cpu load, high memory consumption [duplicate]
Solution 1:
Daniel's comment is probably right: it looks like someone abuses your system.
Some general Postgres performance/stability hints, for people that landed here through Google:
- In postgresql.conf, you can set memory reservation amounts for various functions. Study the file, and see whether you need to modify some values. I'm afraid I can't tell you exactly what to change; that depends on your system and application.
- Postgresql 9.2 is very old. There is a version 11. The newer releases usually have a better performance and stability.
- Log slow queries. Look in pg_log what the slow queries are and check whether there's a table that needs an extra index.