title: Write zeros to file blocks
body: <p>I'm attempting to identify the blocks that are tied to a specific file and write zeros to them. I've found several methods that do this to the free space on a disk, but so far I haven't found any slid suggestions for doing the following:</p>
  
  <ul>
  <li>identify the blocks for a file</li>
  <li>Write zeros to those blocks.</li>
  </ul>
  
  <p>The purpose of this is for a virtualized system. This system has the ability to dedupe blocks that are identified as being the same. This is used to reduce space used by the guest OSes on the drive. </p>
  
  <p>Currently this is being done using <code>dd</code> to write zeros to the free space on the drive. However this has the side effect on VMWare systems to cause the guest OS drive to use the entire disk space it has been allocated as from that point on the system things all the bytes have been written to.</p>