@Override
  public void perform() throws Exception {
    getLogger().info("Start deleting data files");
    FileSystem fs = CommonFSUtils.getRootDirFileSystem(getConf());
    Path rootDir = CommonFSUtils.getRootDir(getConf());
    Path defaultDir = rootDir.suffix("/data/default");
    RemoteIterator<LocatedFileStatus> iterator = fs.listFiles(defaultDir, true);
    Random rand = ThreadLocalRandom.current();
    while (iterator.hasNext()) {
      LocatedFileStatus status = iterator.next();
      if (!HFile.isHFileFormat(fs, status.getPath())) {
        continue;
      }
      if ((100 * rand.nextFloat()) > chance) {
        continue;
      }
      fs.delete(status.getPath(), true);
      getLogger().info("Deleting {}", status.getPath());
    }
    getLogger().info("Done deleting data files");
  }
Delets HFiles with a certain chance
@param chance chance to delete any give data file (0.5 => 50%)
hbase-it/src/test/java/org/apache/hadoop/hbase/chaos/actions/DeleteDataFilesAction.java