Bug #9947 | inaccurate error messages for exceeding user resource limits | ||
---|---|---|---|
Submitted: | 15 Apr 2005 23:49 | Modified: | 7 Aug 2005 1:15 |
Reporter: | Timothy Smith | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 4.0, 4.1, 5.0 | OS: | Any (all) |
Assigned to: | Jim Winstead | CPU Architecture: | Any |
[15 Apr 2005 23:49]
Timothy Smith
[28 Apr 2005 0:05]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/internals/24424
[28 Apr 2005 0:07]
Jim Winstead
1) Fixed by patch. 2) This is intentional. Although this is a per-user limit, it is not configurable per-user. It's not a typical user limit in that regard, so the special error message makes sense. 3) For the same reason as 2, this is handled differently. (Maybe it would make sense to open a feature request about allowing the connection limit per user, as opposed to the connection limit per hour per user, to be set as a user-specific limit.)
[2 May 2005 19:07]
Jim Winstead
Fixed in 4.1.12 and 5.0.6.
[18 May 2005 2:07]
Paul DuBois
Noted in 4.1.12, 5.0.6 changelogs.
[22 Jun 2005 17:09]
Denis Sokolov
Problem not solved Problem not only in "inaccurate error messages for exceeding user resource limits" but in inaccurate working of this limits! When using MAX CONNECTIONS PER HOUR problem appear. So, if MAX CONNECTIONS PER HOUR not null (we have max_connections_per_hour= 14400) after some working: User 'username' has exceeded the 'max_connections_per_hour' resource (current value: 40) We have global max_user_connections=40 So it seems, that problem is that instead of "max_connections_per_hour" mysql using global "max_connections" Configuration: bash-2.05b# /usr/local/libexec/mysqld -V /usr/local/libexec/mysqld Ver 4.1.12 for portbld-freebsd4.10 on i386 (FreeBSD port: mysql-server-4.1.12) bash-2.05b# How to repeat: 1) In /etc/my.cnf max_user_connections=2 2) GRANT USAGE ON * . * TO 'username'@ 'localhost' WITH MAX_QUERIES_PER_HOUR 14400 MAX_CONNECTIONS_PER_HOUR 14400 MAX_UPDATES_PER_HOUR 14400 ; 3)make 2 connections you will see: bash-2.05b# bash-2.05b# mysql -p -u username username Enter password: ERROR 1226 (42000): User 'username' has exceeded the 'max_connections_per_hour' resource (current value: 2) Sorry for bad English
[26 Jun 2005 21:14]
Timothy Smith
Re-opening due to new comment which requires verification.
[28 Jun 2005 1:01]
Bugs System
A patch for this bug has been committed. After review, it may be pushed to the relevant source trees for release in the next version. You can access the patch from: http://lists.mysql.com/internals/26465
[2 Aug 2005 2:23]
Jim Winstead
Fixed in 4.1.14 and 5.0.11.
[7 Aug 2005 1:04]
Mike Hillyer
Documented in 4.1.14 and 5.0.11 changelogs: <listitem><para> <literal>max_connections_per_hour</literal> setting was being capped by unrelated <literal>max_user_connections</literal> setting. (Bug #9947) </para></listitem>