Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

My Windows 7 locked up while I was on hacking some code on Notepad++ and after forcing a restart, I find the files I was working on last to be filled entirely with nulls.

I'm pretty sure this file was filled with what once could have been interpreted as PHP. Now it contains a bunch of nulls. Same with a few others.

File filled with nulls

I'd like to know what might have happened for the sake of learning and in order to prevent future problems. I don't really care for recovering the data, it's just I have no idea what happened here.

Extra data: running apps at time: Notepad++, Chrome, Explorer. Also EventViewer shows nothing but 'unexpected shutdown' after the fact. Windows' 'Previous Versions' have no recollection of past data. And I do make backups, but I was working on this file on my local machine and caught off guard. Occurred on an NTFS data drive (not system drive).

share|improve this question
That is odd. Is the aim here recovering the original file, or working out what happened? – Journeyman Geek Apr 9 '12 at 7:37
Working out what happened. My code was begging for a rewrite anyway. – jay Apr 9 '12 at 7:52
There's a reason why unsafe shutdowns are to be avoided. When you randomly power off the computer, you can interrupt write processes and corrupt your filesystem. The only way to recover your file now if your editor doesn't have a file recovery function, is to use something like time machine or file system journal analysis if using a journaling filesystem. Some claim that overwritten data can be recovered by analyzing the analog image of the storage medium, but there's no evidence of this in actual practice. – Lèse majesté Apr 9 '12 at 7:57
@Lèsemajesté: lol sounds like something from CSI/Numb3rs, interruption during a write sounds legit. But I had no choice given the system was locked-up for a while (no response from input devices or Ctrl+Alt+Del presses). – jay Apr 9 '12 at 8:05
@jay: No doubt. I'm not saying you were at fault here, just that this is one of the main reasons why unsafe shutdowns are typically avoided. Filesystem corruption and lost data is probably the number one negative side-effect from unplanned shutdowns and system crashes. If this happened on a non-system volume, then you may not have had NTFS' USN journal enabled. Try enabling this on all volumes in the future. It may reduce the chances of such problems happening in the future, or at least present a way to easily recover from it. – Lèse majesté Apr 9 '12 at 8:10

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.