Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Azure Service Fabric: Errors on node when using RunAs User policy & non local admin

See original GitHub issue


When using EventFlow on an on premise cluster and the <RunAsPolicy CodePackageRef="Code" UserRef="SqlUser" /> construct in the ApplicationManifest.xml; I get the following error.

The object is closed. at System.Fabric.Interop.Utility.WrapNativeSyncInvoke[TResult](Func1 func, String functionTag, String functionArgs) at System.Fabric.Interop.Utility.WrapNativeSyncInvoke(Action action, String functionTag, String functionArgs) at System.Fabric.Interop.Utility.RunInMTA(Action action) at System.Fabric.FabricClient.HealthClient.ReportHealth(HealthReport healthReport) at Microsoft.Diagnostics.EventFlow.ServiceFabric.ServiceFabricHealthReporter.ReportMessage(HealthState healthState, String description) at Microsoft.Diagnostics.EventFlow.DiagnosticPipelineFactory.ReportItemCreationFailedAndThrow(IHealthReporter healthReporter, String itemType, Exception e) at Microsoft.Diagnostics.EventFlow.DiagnosticPipelineFactory.ProcessSection[PipelineItemType,PipelineItemChildType](IConfigurationSection configurationSection, IHealthReporter healthReporter, IDictionary2 itemFactories, IDictionary`2 childFactories, String childSectionName) at Microsoft.Diagnostics.EventFlow.DiagnosticPipelineFactory.CreatePipeline(IConfiguration configuration, IHealthReporter healthReporter) at Program.Main() in C:\dev\Service\Program.cs:line 21

This translates to an error on the line:

using (diagnosticsPipeline = ServiceFabricDiagnosticPipelineFactory.CreatePipeline("AcmeService"))

This error does not appear if the account named in the RunAs policy is a member of the LocalAdministrators group on the node. This is not an ideal security group for our user though.

Can anyone help?

Thanks in advance.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Reactions:1
  • Comments:8

github_iconTop GitHub Comments

karolz-mscommented, Mar 5, 2018

Cool, thx. @knowhoper fix is on the way, will let you know when it is available on

karolz-mscommented, Mar 19, 2018

I assume this has been fixed. Feel free to complain if it is still not working for you.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Running Azure Service Fabric as different user
I was able to accomplish this by running 'Service Fabric Host Service' in services as logged in user(instead of local account).
Read more >
Run a service under system and local security accounts
Learn how to run a Service Fabric application under system and local security accounts. Create security principals and apply the Run-As ...
Read more >
Run a service startup script as a local user or system account
This policy tells Service Fabric that when the MySetup.bat file is run it should run as SetupAdminUser ( with administrator privileges). Since ...
Read more >
Change Azure Service Fabric cluster settings
This article describes the fabric settings and the fabric upgrade policies that you can customize.
Read more >
Troubleshoot your local Azure Service Fabric cluster setup
This article covers a set of suggestions for troubleshooting your local development cluster.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Post

No results found

github_iconTop Related Hashnode Post

No results found