File And Disk Problems Often, a program neglects to check conditions when the disk becomes full, or fails. This is not common, but may happen, and we should at least avoid loosing data. Writing to a file when the disk is full (or disk quota exceeded) may cause the file to become truncated and all its contents lost. Writing over a file might cause loosing the old contents in case the system crashes (or is rebooted) during this write-up. Solution 1: verify read after write. If you read back the same data (or same amount of data) as you wrote - you're probably safe.