|Problem: When different versions of the same file are |linked to a database at different times, the Data Links File Manager (DLFM) |Retrieve daemon does not retrieve the correct version of the file from an |archive when the database gets restored.
|Background: When a database is restored from a backup |image, the files that were linked in that backup image also get restored in |the Data Links Manager file system (DLFS) from the archive. Here is how |the Data Links Manager retrieve-and-restore process works. |
|Important: It is possible to modify a file but not have |the last modification time and size attributes change. Such "hidden |modifications" are done by making a change that does not affect the file size, |and then resetting the last modification time attribute to that of the |original file.
|Example: Suppose you have a database called DBTEST, and it |contains a table with a DATALINK column. You then perform the following |tasks, in the order listed: |
|The DLFM Retrieve Daemon copies the second version of fileA to |fileA.MOD, then copies the first version of fileA |from the archive onto the DLFS-mounted volume as the working version of |fileA.
|However, if both versions of fileA have the same last |modification time and size attributes, the DLFM Retrieve Daemon does nothing, |because it assumes that the files are actually the same version.
|The result is that the second version of the file -- rather than the first |version -- remains on the DLFS-mounted volume. You have not truly |restored the file system to the same state it was at the time of the |backup.
|Solution: Ensure that your application does not replace a |file with a newer version of that file with the same attributes (last |modification time and size).