php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #45218 PHAR archive built from directory limited by max open file handles
Submitted: 2008-06-09 16:35 UTC Modified: 2008-07-02 13:50 UTC
From: stevseea@php.net Assigned: cellog (profile)
Status: Closed Package: PHAR related
PHP Version: 5.3CVS-2008-06-09 (snap) OS: *
Private report: No CVE-ID: None
 [2008-06-09 16:35 UTC] stevseea@php.net
Description:
------------
When building a PHAR archive using the methods buildFromDirectory() or buildFromIterator(), a temporary file is opened for each file to be added to the archive. These temporary files remain open until the last stages of the archive creation (to prevent the files from being deleted), meaning that the number of files that can be added to the archive is limited by the maximum number of file handles that can be open at any one time (often 2048).


Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2008-06-13 12:24 UTC] stevseea@php.net
Great, that's now fixed. Thanks for the prompt response.

I'd like to use PHAR to create an uncompressed data archive of around 15,000 files (total size about 60MB), but I'm finding the time to create the archive can be measured in hours, whereas creating a zip of the same files takes less than 30 seconds. Though I appreciate that I may be using PHAR for a purpose that it was not designed for, are there any plans to improve performance for large amounts of files in the future?
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 26 19:01:29 2024 UTC