Add logging for IO failures