Server Writing Blank Files

user192618 asked:

I have an old desktop that sits on the side of my desk at my office. I use this as a web server to demo websites (it doesn’t host any “live” production sites). I’ve never had many issues with it until recently.

Out of the blue, the web server is no longer able to write files. For example, when trying to upload a file from a website on the server. The file will be created, but will be completely empty. This is what occurs in any instance where the server is trying to write a file.

I can successfully upload files myself through FTP, but any time the server is trying to write the file itself, I end up with a blank file.

I searched for an answer, but have not been able to find any reference to this sort of problem, let alone a solution.

My answer:

A file that’s created empty, when it was meant to contain data, usually means that the disk (or disk partition) is full and so the file could not be extended past zero bytes. Check the output of df -h to confirm it.

View the full question and any other answers on Server Fault.

Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.