diff options
author | Marko Mäkelä <marko.makela@mariadb.com> | 2017-02-20 17:58:42 +0200 |
---|---|---|
committer | Marko Mäkelä <marko.makela@mariadb.com> | 2017-02-21 16:45:03 +0200 |
commit | 978179a9d4933d3d8d2ac99028798e8a07095dd4 (patch) | |
tree | a4f21dbbd812e8c347413f7ead578b1677d08691 /mysql-test | |
parent | 2bfe83adec576a27aed2d87ff65cebddc3430d2e (diff) | |
download | mariadb-git-978179a9d4933d3d8d2ac99028798e8a07095dd4.tar.gz |
MDEV-11520 Extending an InnoDB data file unnecessarily allocates
a large memory buffer on Windows
fil_extend_space_to_desired_size(), os_file_set_size(): Use calloc()
for memory allocation, and handle failures. Properly check the return
status of posix_fallocate().
On Windows, instead of extending the file by at most 1 megabyte at a time,
write a zero-filled page at the end of the file.
According to the Microsoft blog post
https://blogs.msdn.microsoft.com/oldnewthing/20110922-00/?p=9573
this will physically extend the file by writing zero bytes.
(InnoDB never uses DeviceIoControl() to set the file sparse.)
For innodb_plugin, port the XtraDB fix for MySQL Bug#56433
(introducing fil_system->file_extend_mutex). The bug was
fixed differently in MySQL 5.6 (and MariaDB Server 10.0).
Diffstat (limited to 'mysql-test')
0 files changed, 0 insertions, 0 deletions