Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

error writing mime multipart body part to output stream

Tags:

I have code that does async file uploads which works fine on my dev vm but after I deployed it to the client system, I keep getting this error:

"error writing mime multipart body part to output stream"

I know this is the line that is throwing the error but I can't seem to figure out why:

//Read the form data and return an async task.
await Request.Content.ReadAsMultipartAsync(provider);

The file size was only 1MB and I even tried different file types with much smaller sizes. Why would this occur, I need ideas

like image 409
Mutu Yolbulan Avatar asked Jun 13 '14 01:06

Mutu Yolbulan


2 Answers

Since the error message is mentioning about an error while writing to output stream, can you check if the folder to where the response is being written out has necessary permissions for your application to write.

like image 172
Kiran Avatar answered Oct 05 '22 01:10

Kiran


You can also get this error if a file with the same name already exists in the destination folder.

like image 44
Brett Pennings Avatar answered Oct 05 '22 00:10

Brett Pennings