When I upload a file which is less than 500MB on a server using PHP, then it uploads perfectly. But when I try to upload above 500MB (like 550MB or 700MB) then it shows error.
My php.ini settings are below
upload_max_filesize=2048M
post_max_size=2048M
max_execution_time=3000 (50 minutes)
memory_limit=1024M
I have tried debugging and I found out something
After the file upload I checked the temp path of the file with this function !file_exists($_FILES['fileToUpload']['tmp_name'])
and it returned true, and when I uploaded less than 500MB then returned false and file was uploaded successfully.
I'm using amazon web server it's specifications are
- 4GB RAM.
- 2 Processors.
I'm not sure where is the problem.