Sorry for delay,
>>I wonder if the prioritisation could be done=20
>>using nice - each backend is a separate=20
>>process, so why not to do 'nice(10)' for low=20
>>priority processes or something like that.
>
>Yes, to a limited degree you can prioritise=20
>queries using nice and ionice, but it's awkward because:
>
>- All queries run as `postgres' so you can't do per-user limiting very eas=
ily
>
>- The postmaster doesn't have a way to set the=20
>nice level and ionice level when it forks a=20
>backend, nor does the backend have any way to do=20
>it later. You can use your own user-defined C functions for this, though.
Postmaster hasn't a way to modify the system nice=20
or ionice, but it can send signals to child=20
process. Sending a user signal to sleep=20
completely the child (i/o and cpu) or before any=20
i/o call can do the trick. Perhaps it's time to=20
add a query scheduler or a more complete/complex one in postgres.
>--
>Craig Ringer
----------------------------------------------
Si la vida te da la espalda, =A1tocale el culo!=20=20