Tokubackup is broken because the large file contract expected by applications that
use tokubackup is no longer exported by tokubackup. The contract was broken by commit
0ab06b5 made in early 2018.
The large file contract is supported by compiling with -D_LARGEFILE64_SOURCE and
-D_FILE_OFFSET_BITS=64 AND including the appropriate include files. When an
application is compiled with large file support, it has link time dependencies
to the large file API. For example, the compiler causes calls to pwrite
to refer to pwrite64.
The hot backup library MUST export pwrite64. The broken commit removes the include
of unistd.h, which removes the large file link time trickery. The result is that
the hot backup library exports pwrite instead of pwrite64.
The effect is that pwrite calls made by the application are NOT intercepted by tokubackup.
Therefore, the backup files are no longer consistent with each other when the backup