Bug #43859 64-bit Windows variables limited to different values than 64-bit Linux/Solaris
Submitted: 25 Mar 2009 15:08
Reporter: Harrison Fisk Email Updates:
Status: Verified Impact on me:
Category:MySQL Server: General Severity:S3 (Non-critical)
Version:5.0/5.1 OS:Microsoft Windows (64-bit)
Assigned to: CPU Architecture:Any

[25 Mar 2009 15:08] Harrison Fisk
Many variables in MySQL are defined to be limited to ULONG_MAX.  On 32-bit systems this is always a 32-bit int, so the limit is 2^32.  On most 64-bit systems this is a 64-bit size, so it the limit is 2^64.  However, Windows 64-bit still defines this as 32-bit, hence making the available values much smaller.

This causes the documentation to be wrong and also causes many variables to be limited when they might not need to be.

For example:

max_binlog_cache_size is defined at http://dev.mysql.com/doc/refman/5.0/en/replication-options-binary-log.html#sysvar_max_binl...

This says that it should be 16PB for 64-bit systems, however Windows 64-bit is still limited to 4GB.

How to repeat:
Try increase any of the variables to larger than 32-bit values on 64-bit Windows and Linux.  It works on Linux, but not on Windows.

max_binlog_cache_size = 16G

Suggested fix:
Switch to using ulonglong where you can or some other trickery.