Link to home
Start Free TrialLog in
Avatar of claydough
claydoughFlag for United States of America

asked on

CFFILE UPLOAD - Files being truncated

I am using CF MX on Linux and I am having a problem.  When I use CFFILE to upload large files to the server (5mb) it looks as if it works fine, but the files are truncated at just over 2mb.  There is no consistancy to the file size each time, but it always seems to be just over 2mb.  Smaller files work with no problem.

Any ideas on this one?  Thanks!
ASKER CERTIFIED SOLUTION
Avatar of mrichmon
mrichmon

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
does your server have a file size limit?  (some do)
Avatar of mrichmon
mrichmon

Chances are that if there was a filesize limit then all the files would have been truncated at the same size - which is not what is happening...
Avatar of claydough

ASKER

I was just doing some more testing and took the really simple example from the O'Reilly Programming ColdFusion book (example 12-2,12-3).  It is just 1 form field (the file) and a results page.  About 30% of the time the file makes it up completed, but the other 70% is is anywhere between 2-3 megs.  Here is the result:

CFFILE Upload Results:
AttemptedServerFile POTATOE_BUG1.wmv
FileWasAppended NO
ClientDirectory C:\Documents and Settings\cjohnston\Desktop\POTATOE_BUG1.wmv
FileWasOverwritten YES
ClientFile POTATOE_BUG1.wmv
FileWasRenamed NO
ClientFileExt wmv
FileWasSaved NO
ClientFileName POTATOE_BUG1
OldFileSize 3522560
ContentSubType x-ms-wmv
ServerDirectory /usr/local/oasis/tools/contentattachments
ContentType video
ServerFile POTATOE_BUG1.wmv
DateLastAccessed {d '2004-04-28'}
ServerFileExt wmv
FileExisted YES
ServerFileName POTATOE_BUG1
FileSize 3522560
TimeCreated {ts '2004-04-28 12:08:24'}

the filesize in the above example should be 5062794
hmmm... so sometimes it makes it up correctly?

So it isn't always truncated at just over 2 megs, just most of the time...

Is there a different result based on whether or not the file was alredy on the server or not?

No, the result is the same.  I just had a chat with one of the developers of our content management system (we do web sites for TV stations around the US).  When he developed his video upload piece he used cfftp.  He allowed the person to click on an FTP link that popped up a window of an FTP directory that acts as a drop box of sorts....the user drags the video in...goes back to the parent window, reloads with a click and a cfdirectory shows a listing of the files in the drop box.  They select the file they want to use and it moves it to the correct location.  

Sounds like a huge pain for the user, but for large files, I'm not sure there is another solution.
Yeah that is what I was recommending in my first post.  At least with cfftp it is not too hard to set up - it just ins't as pretty as being able to use cffile.