I have an issue that has come up out of nowhere in NServiceBus
System.UnauthorizedAccessException
HResult=0x80070005
Message=Access to the path 'd:\SfDevCluster\Data\_App\_Node_0\PATH\.diagnostics' is denied.
Source=mscorlib
StackTrace:
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.IO.Directory.InternalCreateDirectory(String fullPath, String path, Object dirSecurityObj, Boolean checkHost)
at System.IO.Directory.InternalCreateDirectoryHelper(String path, Boolean checkHost)
at NServiceBus.HostStartupDiagnostics.BuildDefaultDiagnosticsWriter(ReadOnlySettings settings)
at NServiceBus.HostStartupDiagnostics.GetDiagnosticsWriter(ReadOnlySettings settings)
at NServiceBus.HostStartupDiagnostics.Setup(FeatureConfigurationContext context)
at NServiceBus.Features.FeatureActivator.ActivateFeature(FeatureInfo featureInfo, List`1 featuresToActivate, IConfigureComponents container, PipelineSettings pipelineSettings, RoutingComponent routing, ReceiveConfiguration receiveConfiguration)
at NServiceBus.Features.FeatureActivator.SetupFeatures(IConfigureComponents container, PipelineSettings pipelineSettings, RoutingComponent routing, ReceiveConfiguration receiveConfiguration)
at NServiceBus.InitializableEndpoint.<Initialize>d__1.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at NServiceBus.Endpoint.<Start>d__1.MoveNext()
at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()
at Inspired.CommonConfiguration.<ApplyEndpointConfigurationAndStartEndpointAsync>d__3.MoveNext() in C:\Source\Inspired.TradingPlatform\src\Inspired.TradingPlatform.NServiceBus\Extensions\CommonConfiguration.cs:line 113
How can I set the permissions to allow the log file to be created?
I have never had this issue before, no idea why it has suddenly started
I dont even want logging really, so I am happy to just disable it, I just any solution to get round this error as I need to get on with other stuff
I have tried the logic below to disable logging but it has not made any difference
This is called BEFORE I start up my end point
var config = new LoggingConfiguration();
NLog.LogManager.Configuration = config;
NServiceBus.Logging.LogManager.Use<NLogFactory>();
This is happening on a local 1 node dev cluster. It looks like this is being run under network service account. This user has full permissions
Cheers
Paul