Closed Pascal666 closed 8 years ago
Matching PerlIO::gzip bug: https://rt.cpan.org/Public/Bug/Display.html?id=114557
I could reproduce the problem with a single fork(), without Parallel::ForkManager
involved at all. So it seems to be an issue PerlIO::gzip
or zlib.
Not a P::FM problem per se, but I'll add a note in the module's troubleshooting section. Thanks for the head's up!
Please note that file reads are always done in the main thread below. Although other threads are created, nothing is actually done in them.
I've tried the below code on a couple different Linux boxes. They all seem to get data corruption reading the index. The below works fine if you un-rem the 'next' (disabling Parallel::ForkManager) or gunzip the index beforehand and remove the ':gzip' (disabling PerlIO::gzip). Number of concurrent threads does not appear to matter. The corruption appears to always start at about the same line number for each index, but at different line numbers for different indexes. Running the same thing multiple times will sometimes yield the same exact corruption and sometimes not. A couple indexes (100K each) you can test with: 2015-27 2015-48