public static int getTotalTableFragmentation(final HMaster master) throws IOException {
    Map<String, Integer> map = getTableFragmentation(master);
    return map.isEmpty() ? -1 : map.get("-TOTAL-");
  }
Returns the total overall fragmentation percentage. Includes hbase:meta and -ROOT- as well.
@param master The master defining the HBase root and file system
@return A map for each table and its percentage (never null)
@throws IOException When scanning the directory fails
hbase-server/src/main/java/org/apache/hadoop/hbase/util/FSUtils.java