Connect-ServiceFabricCluster : Argument 'Connect-ServiceFabricCluster' is not recognized as a cmdlet: Unable to load DLL 'FabricCommon.dll'


I installed Service Fabric by using the Install the Service Fabric runtime, SDK, and tools for Visual Studio 2015 Update 2 link from Prepare your development environment.

Trying to publish a Service Fabric Application fails with:

2>Connect-ServiceFabricCluster : Argument 'Connect-ServiceFabricCluster' is not recognized as a cmdlet: Unable to load
2>DLL 'FabricCommon.dll': The specified module could not be found. (Exception from HRESULT: 0x8007007E)

Same error described in Troubleshoot your local development cluster setup, but it does not matter what PowerShell version I use, 64 or 32.

The Service Fabric SDK version I got is 2.1.163.

I am running Windows 10 10586 with Visual Studio 2015 Update 3.

FabricCommon.dll is located at c:\Program Files\Microsoft Service Fabric\bin\Fabric\Fabric.Code\FabricCommon.dll

What am I missing?

asked on Stack Overflow Aug 15, 2016 by kiewic

7 Answers


I will focus on this error first:

DLL 'FabricCommon.dll': The specified module could not be found

You can fix this by re-installing the service fabric SDK. This happens to me before during installation and I thought it was fixed but you never know.

Also make sure you are using the same version of the SDK and nuget package that you referenced in your Service Fabric application.

answered on Stack Overflow Aug 15, 2016 by alltej

A workaround for this issue (which does not include reinstall of the Service Fabric SDK) is to add the following to your path environment variable and restart the application which is throwing error (Visual Studio or PowerShell so that it can access the new environment variable):

C:\Program Files\Microsoft Service Fabric\bin\Fabric\Fabric.Code

You do not need to restart your computer, just restart the application after you have update the path environment variable. The dll fabricCommon.dll lives in this folder.

This workaround is inspired by (but is not identical to) the solution to a somewhat related issue presented here:

answered on Stack Overflow Oct 12, 2018 by shivesh suman • edited Feb 11, 2021 by shivesh suman

Please Run Windows PowerShell as Administrator and then try.

answered on Stack Overflow Sep 10, 2016 by callee.args

I have experienced the same problem on my Win10 box, and even adding the relevant powershell module that contained necessary cmdlets didn't work. The solution that worked for me was: Control Panel -> "Programs and Features", uninstall Service Fabric SDK, then click "Turn Windows features on or off" link and uninstall PowerShell. Next, reboot Windows, back to Control Panel -> "Programs and Features" -> "Turn Windows features on or off", install PowerShell, after which download/install Service Fabric SDK. Again, restart the PC, start the Service Fabric Cluster Manager (if it doesn't auto-start), right-click its icon on the task-bar and try creating 1-node or 5-node cluster.

answered on Stack Overflow May 30, 2018 by Mike Osipov

I was facing same issue on vs2017 and window server 2016. I reinstalled service fabric sdk and issue fixed.

answered on Stack Overflow Jul 31, 2018 by Vishal Sharma

I had similar issue after creating a cluster on windows server 2016.

In my scenario all I had to do was log out/in again and issue was fixed.

You could try restarting VM too - only if it still fails would I try re-installing the SDK.

answered on Stack Overflow Mar 11, 2019 by Adriaan de Beer

All I had to do is restart Visual Studio and it worked. This happens time to time.

answered on Stack Overflow Oct 3, 2020 by OpMt

User contributions licensed under CC BY-SA 3.0