Large file uploading problem

Category: Server Usage

spskumar
Asked:
2013-06-19 9:48 am EST

Hits: 1,498
I have Elite Dedicated Server and i have a code which is done in php. When i am trying to upload less than 280MB file it works fine. if it is more than that i could not get it .
Please check http://www.rawcaster.com/vi/testmy_upload.php
http://www.rawcaster.com/vi/phpinfo.php
Before some months i got same problem then i have increased MAX_FILE_UPLOAD_SIZE then it was working fine upto last one month. now it is not working.

You must login before you can ask a follow up question.

You must login before you can submit an answer.

I have contacted your live chat agent, He tells me again and again it is code error you know that there is no code error because small files are uploading correctly
spskumar
8 Points
2013-06-19 09:52 am EST
i have nothing in my code only this 1.testmy_upload.php file content: "<form name="largeupload" method="post" enctype="multipart/form-data" action="send_upload.php" >
<input type="file" name="myfile" id="myfile" />
<input type="submit" name="Submit" id="submit" value="Submit" />
</form>" 2. send_upload.php file content: "<?php

if( move_uploaded_file($_FILES['myfile']['tmp_name'], 'uploads/' . $_FILES['myfile']['name']))
{
echo 'Uploaded Successfully';
}
else
{
echo 'Cant Upload Try Again!';
}
?>"
spskumar
8 Points
2013-06-19 09:55 am EST

OTHER ANSWERS

0

Scott
Staff
19,569 Points
2013-06-19 12:42 pm EST
Hello spskumar,

I tested your code on my own server. I am able to successfully upload smaller files, (100 - 200MB, etc) but when I attempt to upload larger files (mytest file is 540MB) it seems to sit there uploading and then forward to the send_upload.php URL. In my case, I get a connection reset. Is this the behavior you are seeing? Also, is this something you absolutely need? Php is not designed for transfer of larger files, whereas FTP is. You may want to consider creating a public FTP account if that is feasible for your situation.

Best Regards,
Scott M

You must login before you can post a comment about this answer.

Yes i am also think the connection resets because i am not getting anything in this($_FILES['myfile']) if it is larger file . I am giving facility to my users to upload their own videos to my site and sharing with their friends. I cannot give ftp-details to all my registered users for uploading video they need to upload on the same page by clicking upload button. so what can i do. it was working before a month i have uploaded around 1GB file. Please look at following link so that you can understand what i want to do
https://www.rawcaster.com/
https://www.rawcaster.com/friends/gtSxVr2/OTk5
Thank you very much
spskumar
8 Points
2013-06-20 12:24 am EST
Hello spskumar!

Sorry for all the trouble with your file uploads not working. You should be able to change the below settings in your php.ini file and your HTML form.

php.ini changes

Increase the upload_max_files
upload_max_filesize = 1024M
Increase the php memory limit
memory_limit = 1024M
Increase the max_post_size
post_max_size = 1024M

HTML form changes

Add the below hidden input into your form

<input type="hidden" name="MAX_FILE_SIZE" value="1024000" />

You will also need to make your php.ini recursive. Also, if you don't see your php.ini then you can restore it to your public_html folder.

Best regards,
James R
jamesr
5,889 Points
Staff
2013-06-20 12:12 pm EST
Like this Question?

Related Articles

It looks like there are no related articles.
Would you like to ask a question about this page? If so, click the button below!
Ask a Question

Need more Help?

Search

Ask the Community!

Get help with your questions from our community of like-minded hosting users and InMotion Hosting Staff.

Current Customers

Chat: Click to Chat Now E-mail: support@InMotionHosting.com
Call: 888-321-HOST (4678) Ticket: Submit a Support Ticket

Not a Customer?

Get web hosting from a company that is here to help. Sign up today!