Because I have a constant rsync copying the suitcased data from its initial location to another where users can access it, it sometimes catches this initial incorrect file. The filesizes of the complete file with the wrong header and the final correct file are often identical so they are difficult to recognize automatically without a costly checksum. Seems better to write the file to a temporary location and only write to disk when it is complete?
Because I have a constant rsync copying the suitcased data from its initial location to another where users can access it, it sometimes catches this initial incorrect file. The filesizes of the complete file with the wrong header and the final correct file are often identical so they are difficult to recognize automatically without a costly checksum. Seems better to write the file to a temporary location and only write to disk when it is complete?