Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

User 'root' has exceeded the 'max_questions' resource

I receive this error:

ERROR 1226 (42000): User 'root' has exceeded the 'max_questions' resource (current value: 4)

I can't even change the value in database because of this error. any ideas?

like image 322
Zim3r Avatar asked Oct 26 '25 16:10

Zim3r


2 Answers

Change root user properties, e.g. -

GRANT USAGE ON *.* TO 'root'@<'host_name'> WITH MAX_QUERIES_PER_HOUR 100

Set 0 to reset limitation.

like image 195
Devart Avatar answered Oct 28 '25 06:10

Devart


Easy way to fix:

User 'root' has exceeded the 'max_questions' resource (current value: 100)

To Fix issue you have to wait 1 hour before you run any of these commands..because the problem is, the max questions are set to a certain number of request per HOUR. If you try to run these commands before the 1 hour is up, these commands will NOT work. So wait 1 Hour..

after that 1 hour has already passed then run the following in the terminal in exact order:

* mysql -u root -p

* use mysql

* select user, max_questions from user; 

* update user set max_questions = 0 where user = 'root';

* flush privileges;

* select user, max_questions from user; 

(If root max questions says '0' then you've fixed it..Now you're done)

like image 24
Jackie Santana Avatar answered Oct 28 '25 08:10

Jackie Santana