Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-58126

Windows DLL loading mechanism is incompatible with symlinking binaries during resmoke.py setup-multiversion

    • Fully Compatible
    • v5.0, v4.4, v4.2, v4.0
    • STM 2021-07-26, STM 2021-08-09
    • 200
    • 2

      The multiversion resmoke test downloads the older version of the server, and create a common directory in which it creates symlinks to each of the old versions. It then runs the old versions out of that common directory.

       

      The renaming causes the DLL's to not be loaded because the executable is looking for a specific name. Instead the DLL is loaded from the system path, because the renamed version of the DLL does not match.

       

      I discovered this when working on BUILD-11371, see attached screenshot. I reran the old version command line from the test, and checked the DLL modules loaded using Visual Studio debugger, and found that changing the name of the symlink allows the correct dll to be loaded.

        1. image-2021-06-28-11-21-30-734.png
          image-2021-06-28-11-21-30-734.png
          3.97 MB
        2. no-dll-5.0.png
          no-dll-5.0.png
          2.19 MB
        3. symlink-4.4.png
          symlink-4.4.png
          2.66 MB
        4. symlink-5.0.png
          symlink-5.0.png
          2.44 MB

            Assignee:
            robert.guo@mongodb.com Robert Guo (Inactive)
            Reporter:
            daniel.moody@mongodb.com Daniel Moody
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: