Technology After Purchase

What a Checksum Can Reveal About an Old File

Opening an old file tests whether an application can read it now. Comparing its checksum with an earlier value tests whether its data appears unchanged since that earlier check. A file can pass the first test and fail the second. It can also match the earlier checksum while the software that once opened it is no longer available.

A black drive, a silver drive and a coiled cable sit beside a closed laptop on a pale wooden desk.

What makes the earlier value useful?

The U.S. National Archives and Records Administration defines a checksum as a relatively small code derived from a larger body of data by a specified algorithm. In a file check the larger body is the file data. The method can be applied before a transfer or period in storage and then applied again later. A familiar filename helps locate the candidate for the check. The checksum comparison concerns the data in the file that was actually read.

There are two pieces of information to retain alongside the result: what was checked and how. A short string separated from the filename, location or version may turn up later with nothing to tie it to a particular file. A string recorded without the algorithm does not give a later reader the full basis of the comparison. A date adds the boundary in time. A successful check against a value recorded during a recent move cannot speak for years that passed before that value was calculated.

In its guidance on sustaining moving image files, the archives recommends establishing a checksum when a file is first created and comparing checksums as part of ongoing monitoring. There is still value in establishing a baseline for material with no earlier record. The date of that baseline simply changes the question that can be answered. It allows a future check against the file as it is now, rather than recovering evidence of what the file contained at creation.

Where the comparison starts and stops
  • Baseline: the file version, date, algorithm and resulting value are recorded.
  • Storage or transfer: the reference stays available and associated with that file.
  • Recheck: a value is calculated for the corresponding file using the same algorithm.
  • Interpretation: the results are compared for the interval the record actually covers.

How does a straightforward copy differ from a new version?

In a transfer between drives, the question might be whether the destination file is an unchanged copy of the one on the source drive. For that question, there is a clear pair: a value calculated for the source file and a value calculated for the destination file using the same method. The names of the drives and the file's location can change without being part of the file data under comparison. A shorter folder path or a tidier filename cannot resolve a difference in the values.

The situation changes when the task includes conversion. An old recording saved in a different file format can carry recognisably the same scenes while being represented by different data. That new file can have a checksum of its own, which provides a reference for later copies of the converted file. Comparing it with the old recording's checksum is asking whether the data stayed unchanged through a process that was intended to change its representation. The comparison does not judge whether the same scenes and sound survived.

Even an application that seems to leave the visible content alone may be used to save a deliberate revision. The archives' moving image guidance distinguishes filename organisation from information embedded inside a file. That distinction matters here: a revision of embedded descriptive information can change the bytes even if the picture displayed to a viewer remains the same. A dated note that identifies the revised version helps a later reader tell an expected difference from one that needs investigating.

An unchanged recording and a shorter version intended for viewing can each be useful, and each can carry a separate reference value. The useful comparison for the shorter version is against the version that was actually released for viewing, rather than the source from which it was cut. The difference is easiest to record while both versions can still be identified. Later, the shortened copy may have the more familiar name, while the earlier file may be the one intended for preservation. Naming the role of each version saves a later comparison from being asked to settle a question of intent.

What does a mismatch actually establish?

Once the file identity and algorithm have been checked, different checksum values establish that the data supplied to the algorithm differed. The result does not name the byte that changed, the reason it changed or the stage at which it changed. A file selected from the wrong folder and a file altered after the baseline may both yield a difference. The mismatch establishes the boundary of the problem; opening the correct candidate and working out its history are separate tasks.

What the result does and does not say
ResultWhat it supportsWhat it leaves open
Match against a documented baselineNo change detected by this comparisonReadability in current software and the quality of the original
Mismatch using the same algorithmData differs, if the intended versions were comparedWhen, where and why it differed
No baseline or unknown algorithmNo usable comparison with the earlier stateWhether the file changed before the current check

The most useful response is to keep the differing copies separate while the references are sorted out. If one candidate is immediately saved over the other, the very thing the comparison revealed may no longer be available for examination. Where a transfer has just happened and an earlier copy exists, comparing that copy against the reference can narrow the interval under review. It still cannot pinpoint the failing device or step on its own. A check that could not read the whole file is yet another case: an incomplete read has not supplied a usable second value to compare.

A useful record also distinguishes a mismatch from a recheck that never took place. If a drive is unavailable or a folder cannot be reached, there is no result to enter against that file. Treating it as changed would confuse lack of access with evidence about the data. Treating it as unchanged would overlook the missing comparison. The same distinction applies across a batch: a matching result for one item covers the item that was checked, even if the neighbouring files were copied at the same time. This is where retaining the file identity beside each result pays off, especially when the next person to need the record did not take part in the transfer.

What if the checksum matches but the file will not open?

The two checks are answering different questions. The checksum process reads the file as data. An application needs to do something meaningful with that data. If a recorded checksum still matches, an unsuccessful attempt to open the file gives a reason to look at what the application supports, rather than assume the bytes changed in storage. A file that cannot be read by the storage system at all offers no such comparison because there is no new value from a complete read.

A match also carries the limits of the reference. If a file already had a missing segment before its original checksum was recorded, a matching value now gives no reason to expect that segment to be present. A checksum is compact, so the same value is not an absolute proof against every conceivable difference. Its practical use is to flag a discrepancy against a trusted reference when the file and method are known. A separate look at the contents still matters when a copy needs to be usable rather than merely preserved as recorded.

When is there a reason to repeat the check?

A storage move is an obvious point to compare: there is a source version and a destination version, and the purpose of copying is clear. A later check creates another point in the file's history, particularly if the material has not been opened for a long time. Regular comparisons are part of the archives' guidance, alongside backups and multiple copies. This use of a checksum is closer to an inspection record than a one-off stamp on a successful transfer.

Minimum details for a useful recheck
  • File or version identified unambiguously
  • Date of the reference check
  • Algorithm used for the reference and the recheck
  • Where the recorded value and corresponding copies are kept
  • Whether the expected operation is copying, editing or conversion

The checksum cannot take the place of the backup. If the only surviving file no longer agrees with its recorded value, the earlier string does not contain a spare copy of the data. A second copy has value because it can be examined and compared in its own right. A sensible record leaves enough information for a later reader to tell which version is being recovered, rather than simply which of two files has the most familiar name.

Frequently Asked Questions

Can a checksum help if no one recorded one when the file was made?

A value recorded now can serve as the first reliable point of comparison for later checks. It cannot establish whether the file changed before that point.

Can two tools produce results that are useful to compare?

They can if they apply the same checksum algorithm to the same scope of file data and report values that can be compared. Different algorithms do not supply an earlier and later measurement on the same basis.

Is an identical name enough to identify the right file?

Two versions can share a filename across separate folders or drives. A reference is easier to interpret when its date and version can be tied to the exact file of interest.

Does a mismatch mean the drive needs replacing?

The mismatch shows a difference in the data compared, once a mismatch in method or file selection has been ruled out. Identifying the drive as the cause requires additional evidence about what happened between the two readings.

Sources

  • U.S. National Archives and Records Administration — Archival Formats: Glossary of Terms
  • U.S. National Archives and Records Administration — Motion Picture Film Guidance: Sustaining Moving Image Files