Bug #36446 Attempt to set @@join_buffer_size to its minimum value produces spurious warning
Submitted: 1 May 2008 8:05 Modified: 27 Mar 2009 15:16
Reporter: Sergey Petrunya Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.0, 5.1 BK, 6.0-bk OS:Any
Assigned to: Tatiana Azundris Nuernberg CPU Architecture:Any

[1 May 2008 8:05] Sergey Petrunya
Description:
Attempt to set @@join_buffer_size to its minimum value produces spurious warning

How to repeat:
## First, set it to the minumum

mysql> set join_buffer_size=1;                      
Query OK, 0 rows affected, 1 warning (0.03 sec)

mysql> select @@join_buffer_size;
+--------------------+
| @@join_buffer_size |
+--------------------+
|               8228 | 
+--------------------+
1 row in set (0.01 sec)

## Save this value 
mysql> set @save_join_buffer_size=@@join_buffer_size;
Query OK, 0 rows affected (0.00 sec)

mysql> select @save_join_buffer_size;                   
+------------------------+
| @save_join_buffer_size |
+------------------------+
|                   8228 | 
+------------------------+
1 row in set (0.00 sec)

## Try to set it back. 

mysql> set join_buffer_size=@save_join_buffer_size;
Query OK, 0 rows affected, 1 warning (0.00 sec)

mysql> show warnings;
+---------+------+----------------------------------------------------+
| Level   | Code | Message                                            |
+---------+------+----------------------------------------------------+
| Warning | 1292 | Truncated incorrect join_buffer_size value: '8228' | 
+---------+------+----------------------------------------------------+
1 row in set (0.00 sec)

mysql> select @@join_buffer_size;
+--------------------+
| @@join_buffer_size |
+--------------------+
|               8228 | 
+--------------------+

## The last two outputs clearly don't add up. if 8228 is an incorrect value then join_buffer_size should not have it.
[1 May 2008 11:43] Sveta Smirnova
Thank you for the report.

Verified as described.

mysql-6.0-falcon-team and mysql-4.1 are not affected, other trees are
[2 Jun 2008 11:23] 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/commits/47309

2659 Tatiana A. Nurnberg	2008-06-02
      Bug#36446: Attempt to set @@join_buffer_size to its minimum value produces spurious warning
      
      If a sys-var has a base and a block-size>1, and then a
      user-supplied value >= minimum ended up below minimum
      thanks to block-size alignment, we threw a warning.
      This meant for instance that when getting, then setting
      the minimum, we'd see a warning. This was needlessly
      confusing.
[16 Mar 2009 18:46] 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/commits/69340

2835 Tatiana A. Nurnberg	2009-03-16
      Bug#36446: Attempt to set @@join_buffer_size to its minimum value produces spurious warning
      
      If a sys-var has a base and a block-size>1, and then a
      user-supplied value >= minimum ended up below minimum
      thanks to block-size alignment, we threw a warning.
      This meant for instance that when getting, then setting
      the minimum, we'd see a warning. This was needlessly
      confusing. (updated patch)
[17 Mar 2009 18:25] Tatiana Azundris Nuernberg
queued for 5.1.33, 6.0.11 in bugteam
[18 Mar 2009 13:20] Bugs System
Pushed into 6.0.11-alpha (revid:joro@sun.com-20090318122208-1b5kvg6zeb4hxwp9) (version source revid:joro@sun.com-20090317133112-41qn6aly7arljtlq) (merge vers: 6.0.11-alpha) (pib:6)
[19 Mar 2009 3:11] Paul Dubois
Noted in 6.0.11 changelog.

Setting the join_buffer_size variable to its minimum value produced
spurious warnings.  

Setting report to NDI pending push into 5.1.x.
[27 Mar 2009 14:58] Bugs System
Pushed into 5.1.34 (revid:joro@sun.com-20090327143448-wuuuycetc562ty6o) (version source revid:leonard@mysql.com-20090316090622-sr8lylqvsl1jrcnv) (merge vers: 5.1.34) (pib:6)
[27 Mar 2009 15:16] Paul Dubois
Noted in 5.1.34 changelog.
[9 May 2009 16:43] Bugs System
Pushed into 5.1.34-ndb-6.2.18 (revid:jonas@mysql.com-20090508185236-p9b3as7qyauybefl) (version source revid:jonas@mysql.com-20090508185236-p9b3as7qyauybefl) (merge vers: 5.1.34-ndb-6.2.18) (pib:6)
[9 May 2009 17:40] Bugs System
Pushed into 5.1.34-ndb-6.3.25 (revid:jonas@mysql.com-20090509063138-1u3q3v09wnn2txyt) (version source revid:jonas@mysql.com-20090509063138-1u3q3v09wnn2txyt) (merge vers: 5.1.34-ndb-6.3.25) (pib:6)
[9 May 2009 18:37] Bugs System
Pushed into 5.1.34-ndb-7.0.6 (revid:jonas@mysql.com-20090509154927-im9a7g846c6u1hzc) (version source revid:jonas@mysql.com-20090509154927-im9a7g846c6u1hzc) (merge vers: 5.1.34-ndb-7.0.6) (pib:6)