Discussion:
[rt.cpan.org #118094] Race condition exists when building cache for pp built executables
(too old to reply)
via RT
2016-09-26 20:31:26 UTC
Permalink
Mon Sep 26 16:31:25 2016: Request 118094 was acted upon.
Transaction: Ticket created by ***@sjm.com
Queue: PAR-Packer
Subject: Race condition exists when building cache for pp built executables
Broken in: 1.017, 1.032
Severity: Important
Owner: Nobody
Requestors: ***@sjm.com
Status: new
Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=118094 >


Perl version: 5.16.3
OS: RHEL 7.2

I receive errors similar to the following when running pp built executables.

Data/Dumper.pm did not return a true value at /usr/share/perl5/site_perl/CUSTOMMODULEA.pm line 23.

IO/Socket.pm did not return a true value at /usr/share/perl5/site_perl/CUSTOMMODULEB.pm line 63.

These errors only seem to occur when:
1. multiple instances of the executable is started simultaneously; the more instances started the more likely the problem is to occur.
2. The par cache for the executable has not been built yet (e.g. the executable has never been run or rm -rf /tmp/par-UNIQUEID)

PP Version: PAR Packager, version 1.017 (PAR version 1.010) [also tried PAR Packager, version 1.032-2]
PP Command: pp -c -f Bleach -F Bleach -o target src.pl

Note: I think the same problem would occur even if the script and modules weren't being "bleached".
Roderich Schupp via RT
2016-12-30 10:53:11 UTC
Permalink
Fri Dec 30 05:53:05 2016: Request 118094 was acted upon.
Transaction: Correspondence added by RSCHUPP
Queue: PAR-Packer
Subject: Race condition exists when building cache for pp built executables
Broken in: 1.017, 1.032
Severity: Important
Owner: Nobody
Requestors: ***@sjm.com
Status: new
Ticket <URL: https://rt.cpan.org/Ticket/Display.html?id=118094 >
Post by via RT
1. multiple instances of the executable is started simultaneously; the
more instances started the more likely the problem is to occur.
Yeah, during bootstrap (and later) files are extracted from the executable
and written to the cache area without any precaution that several concurrently
running processes might do the same.

Fixed in versions PAR 1.014 and PAR::Packer 1.036, just uploaded to CPAN.

Cheers, Roderich

Loading...