Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I would like to know how databases (like MySQL) are able to manage per user resources (like Oracle Database Resource Manager does) to be able to have users that may only get resources only when the database is mostly idle.
http://stackoverflow.com/questions/2418581/is-there-a-way-to-throttle-or-limit-resources-used-by-a-user-in-oracle

share|improve this question

2 Answers 2

MySQL, as far as I know, does not have a way to artificially limit resource usage by a user.

Usually you don't limit database access / queries directly, if you want to offer different service levels to customers you do that at another level (eg. you limit the number of processes answering web requests, this will indirectly limit resource usage on the whole backend infrastructure).

Users who do overuse a shared system to the point of creating problems to other users are usually detected by other means (eg. the system monitoring will alert you of an unresponsive system) and killed by hand. But that's not regular "scheduling" of normal operations, it's problem detection and response.

share|improve this answer

Depends.

Oracle has a Resource manager. SQL Server has one too (got one in 2008). Others (mySQL) dont.

how they work? Like every scheduler. Basically they measure performance counters and if one user / database goes over the allocated limit, his queries get slowed down (lower piority, normally) compared to the rest.

Note that "database is mostly idle" is REALLY a complicated question for databases. what you talk of? IO? CPU? Various queries have various bottlenecks.

share|improve this answer
    
If your users are doing heavy reads, opposed to heavy writes, then you can just add some read only replica's of your mysql database to your network. Adding an oracle cluster may set you back $$$$. You can scale with servers, rather then limit with software. Users get faster response times and read fault tollerance. Everyone is happy! Why limit (read) resources when you can scale. –  The Unix Janitor Mar 19 '10 at 8:48
    
Because of this thing called "money"? If you offer, for example, shared hosting - "scaling" is not a financial option. You have x resources and must share them between y websites. Point. Users using too much and killing the other users experience area a burden. –  TomTom May 10 '10 at 10:02

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.