|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #29794 Doesn't execute fast enough
Submitted: 2004-08-22 22:00 UTC Modified: 2004-08-23 18:40 UTC
From: amailer at gmail dot com Assigned:
Status: Not a bug Package: *Directory/Filesystem functions
PHP Version: 5.0.1 OS: Windows
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If this is not your bug, you can add a comment by following this link.
If this is your bug, but you forgot your password, you can retrieve your password here.
Bug Type:
From: amailer at gmail dot com
New email:
PHP Version: OS:


 [2004-08-22 22:00 UTC] amailer at gmail dot com
Windows XP Pro [ test server ]
Apache 2
PHP 5 - FastCGI

I am creating a script that will, take the given folder path and ZIP it. It will also zip all it's subfolders and files.

I have got the script to create the subfolders correctly-- but when I try to add the files, it takes for ever and just dies (execution time error)
Fatal error: Maximum execution time of 30 seconds exceeded in www/test/dir/explorer.php on line 34

Now, i tried changing the ini settings of the max execution time to ini_set("max_execution_time", 1000);
1000 seconds, yet that doens't work.

The script works only with folders that have a small amount of files and provided that the file sizes are small also.

If i run this script to zip a folder with many files (20+) and some 1 mb or more, the script make php use up to 98 CPU usage and yet not work, the script then dies after some time leaving me with that error.

Shouldn't this be a bit more quicker in zipping files? I mean, it uses so much of the CPU usage it lags my test server so much  (even with manually zipping it's 10x faster then that)

Hope you guys can help,
Thank you

Reproduce code:
For the source code please visit:

I cannot provide a link to view the script in action because it lags up the server too much, sorry.

Expected result:
I want it to zip a folder with all it's subfolders and files, and save it.

Actual result:
Fatal error: Maximum execution time of 1000 seconds exceeded in C:\Program Files\Apache Group\Apache2\htdocs\termix\SUBDOMAIN\gfx-pro\Explorer\explorer.php on line 88


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2004-08-22 22:04 UTC] amailer at gmail dot com
no comment (spelling mistake)
 [2004-08-23 18:40 UTC]
Sorry, but your problem does not imply a bug in PHP itself.  For a
list of more appropriate places to ask for help using PHP, please
visit as this bug system is not the
appropriate forum for asking support questions. 

Thank you for your interest in PHP.

The simple answer is that you probably have a lot of files 
and the process of generating a zip file is rather slow. 
So, PHP terminates when the execution limit is reached. 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Thu Jul 18 07:01:28 2024 UTC