Limiting postgresql resources - Mailing list pgsql-general

From Joey K.
Subject Limiting postgresql resources
Date
Msg-id 467669b30804051610g69cf2612oa8dc26bc4570b929@mail.gmail.com
Whole thread Raw
Responses Re: Limiting postgresql resources  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
Hello,

Is it possible to limit cpu/memory resources to queries on postgres something akin to limits.conf on Linux?

We have a couple of databases (pg 8.2.7)  serving 500K - 1M records. For various reasons, users are allowed to run queries against the database via a web based query interface. These queries are mostly used to generate reports.

Some times users write inefficient queries that brings the entire database server (runs webserver as well) to it's knees affecting others users on the system.

So, is it possible to kill a query thats running for x minutes with 50%+ CPU load and using y MB of memory?

In a perfect world, we would address such issues in the application design/database design and/or hardware. But our application is in an imperfect world where such resources are unavailable.

Thanks in advance,
Joey


pgsql-general by date:

Previous
From: "Douglas McNaught"
Date:
Subject: Re: slow pgsql tables - need to vacuum?
Next
From: brian
Date:
Subject: Re: Numbering rows by date