as i know its rite
but the problem i can see here is either your machine is having very low space
or the server cluster is only capable of handling 128mb of data(134217728bytes)
Main Topics
Browse All TopicsI'm trying to download a file that is about 500MB big.
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 133693440 bytes)
I'm using the following code to download the file. How can I get this working?
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
What your code is doing is a simple move, but you read the file to RAM .
Perhaps this will be better (a simple move)
http://il.php.net/manual/e
Business Accounts
Answer for Membership
by: shanikawmPosted on 2009-06-03 at 04:33:29ID: 24535227
I think you have the solution here.
m/rx/777/s olve-php-f atal-error - allowed-m emory-size -of-838860 8-bytes-ex hausted-tr ied/
http://www.tech-recipes.co
change memory_limit parameter in php.ini or use ini_set to increase the memory limit that can be used by a script.