libsodium-64.dll not found in production Azure Service Fabric cluster

后端 未结 1 1645

Using libsodium-net for all of its security goodness in an Azure Service Fabric Reliable Service, on my local dev cluster everything is working fine (although I did have to

相关标签:
1条回答
  • 2021-01-06 11:29

    Turns out libsodium-64.dll depends on the Visual C++ Runtime, which didn't seem to be present on the Azure VMs. Ran Process Monitor as mentioned here and saw it was picking up "libsodium-64.dll" but failing on "vcruntime140.dll" - the exception message alone makes this pretty much impossible to work out.

    Installed the Visual C++ Redistributable on the VMs and everything seems to be working fine now.

    If anyone happens to run into the same problem, you can solve it by adding the following extension to the VM profile of the scale set in your ARM deployment template (VMSS -> properties -> virtualMachineProfile -> extensionProfile -> extensions):

    {
        "name": "InstallVCRuntime",
        "properties": {
            "publisher": "Microsoft.Compute",
            "type": "CustomScriptExtension",
            "typeHandlerVersion": "1.7",
            "autoUpgradeMinorVersion": true,
            "settings": {
                "fileUris": [
                    "https://some.blob.storage.url/vc_redist.x64.exe"
                ],
                "commandToExecute": "vc_redist.x64.exe /q /norestart"
            }
        }
    }
    

    All it does is grab the installer, and run it silently. There didn't seem to be a public link to the redistributable, so I just downloaded it and put it into blob storage.

    0 讨论(0)
提交回复
热议问题