I have a very strange situation where I have a file system that contains a number of files that are of varying size but appear to have been corrupted and show no contents when cat-ing the file.
I have no idea how many of these files there are and they look like all the other files around them. So far the best method I've found to discover them is to run
find . -type f | xargs wc -l and look for the files that return 0.
However, some of these files are 10s of GB and even when they're empty take over a minute to check one file. I have to check approximately 50 million files, so that's pretty much a non-starter.
My biggest question is if there's a lower level way to check the contents of these files that will be much faster than running a simple find.