Uploading file over 2mb throws error "Failed to write file to disk."
-
Hello. I’ve been trying to dig into this issue for hours with no avail, I’d love any help or pointers in the right direction!
If I upload a file >2mb in the media modal I’m getting: “Failed to write file to disk.”
If I upload it in Media -> New using the HTML uploader I get the error: “Error saving media attachment”.
It’s not a permissions issue because if I upload a small image everything works correctly.
I have in my nginx config:
http { client_max_body_size 200M; }
and php.ini:
post_max_size = 200M upload_max_filesize = 200M
Which is working because on the upload screen WordPress says: “Maximum upload file size: 200mb”
Also, I don’t believe it’s a space issue:
root@pluto:/# df -h Filesystem Size Used Avail Use% Mounted on /dev/xvda 95G 51G 43G 55% / devtmpfs 2.0G 4.0K 2.0G 1% /dev none 401M 168K 400M 1% /run none 5.0M 0 5.0M 0% /run/lock none 2.0G 0 2.0G 0% /run/shm overflow 1.0M 0 1.0M 0% /tmp
This is really stumping me – I appreciate any help!!
It was working before until I restarted my server, and something went wonky — it’s really difficult troubleshooting what exactly is going on.
When I turn on WP_DEBUG and the debug log I can’t find any trace of the error.
Thanks
-Ryan
- The topic ‘Uploading file over 2mb throws error "Failed to write file to disk."’ is closed to new replies.