Reorganize and really close the IOUtils class

This commit introduces no changes to any logic bits - only code
reorganizing, as in moving bits of code from one place in the file
to another. IOUtils looking good for now but it should be looked
into whether checkMounts() can be shrunk or even gotten rid of
completely.