Product: PowerShell Universal Version: 3.9.1 / 3.9.7 / 4.0.1
hey,
Since installing KB5027544 (2023-06 CU .net) on Windows Server 2022, the PowerShell Universal Service no longer starts with the specified service account.
Does anyone else have this problem?
The settings described under Running as a Service Account - PowerShell Universal have been made
If we set the local service as the account, the service will run as intended
in Eventlog there are 2 Events
Application: Universal.Server.exe CoreCLR Version: 7.0.222.60605 .NET Version: 7.0.2 Description: The process was terminated due to an unhandled exception. Exception Info: System.UnauthorizedAccessException: Access to the path 'C:\ProgramData\UniversalAutomation\database.db' is denied. at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options) at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode) at System.IO.Strategies.OSFileStreamStrategy..ctor(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode) at System.IO.Strategies.FileStreamHelpers.ChooseStrategyCore(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options, Int64 preallocationSize) at System.IO.FileStream..ctor(String path, FileMode mode, FileAccess access, FileShare share, Int32 bufferSize, FileOptions options) at LiteDB.Engine.FileStreamFactory.GetStream(Boolean canWrite, Boolean sequencial) at LiteDB.Engine.StreamPool.<>c__DisplayClass3_0.<.ctor>b__0() at System.Lazy`1.ViaFactory(LazyThreadSafetyMode mode) at System.Lazy`1.ExecutionAndPublication(LazyHelper executionAndPublication, Boolean useDefaultConstructor) at System.Lazy`1.CreateValue() at LiteDB.Engine.StreamPool.get_Writer() at LiteDB.Engine.DiskService..ctor(EngineSettings settings, Int32[] memorySegmentSizes) at LiteDB.Engine.LiteEngine..ctor(EngineSettings settings) at LiteDB.ConnectionString.CreateEngine() at LiteDB.LiteDatabase..ctor(ConnectionString connectionString, BsonMapper mapper) at LiteDB.LiteDatabase..ctor(String connectionString, BsonMapper mapper) at LiteDB.LiteRepository..ctor(String connectionString, BsonMapper mapper) at UniversalAutomation.LiteDBv5Database.SetupTables() in C:\actions-runner\_work\universal\universal\src\UniversalAutomation.LiteDBv5\LiteDBDatabase.cs:line 115 at UniversalAutomation.LiteDBv5Database..ctor(IServiceProvider serviceProvider, String connectionString) in C:\actions-runner\_work\universal\universal\src\UniversalAutomation.LiteDBv5\LiteDBDatabase.cs:line 81 at UniversalAutomation.LiteDBv5.DatabaseFeature.GetDatabase(IServiceProvider serviceProvider, String connectionString) in C:\actions-runner\_work\universal\universal\src\UniversalAutomation.LiteDBv5\Plugin.cs:line 41 at Universal.Server.Services.SystemPluginService.<>c__DisplayClass3_0.<AddDatabase>b__2(IServiceProvider x) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Services\SystemPluginService.cs:line 92 at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitRootCache(ServiceCallSite callSite, RuntimeResolverContext context) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitIEnumerable(IEnumerableCallSite enumerableCallSite, RuntimeResolverContext context) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSiteMain(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument) at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope) at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>b__0(ServiceProviderEngineScope scope) at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(Type serviceType, ServiceProviderEngineScope serviceProviderEngineScope) at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType) at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService[T](IServiceProvider provider) at Microsoft.Extensions.Hosting.Internal.Host.StartAsync(CancellationToken cancellationToken) at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token) at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.RunAsync(IHost host, CancellationToken token) at Microsoft.Extensions.Hosting.HostingAbstractionsHostExtensions.Run(IHost host) at Universal.Server.Program.<>c__DisplayClass3_0.<Main>b__0(Options o) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Program.cs:line 72 at CommandLine.ParserResultExtensions.WithParsed[T](ParserResult`1 result, Action`1 action) at Universal.Server.Program.Main(String[] args) in C:\actions-runner\_work\universal\universal\src\Universal.Server\Program.cs:line 52
Name der fehlerhaften Anwendung: Universal.Server.exe, Version: 1.0.0.0, Zeitstempel: 0x638f99ee Name des fehlerhaften Moduls: KERNELBASE.dll, Version: 10.0.20348.1787, Zeitstempel: 0x99873638 Ausnahmecode: 0xe0434352 Fehleroffset: 0x000000000003ef5c ID des fehlerhaften Prozesses: 0x23e0 Startzeit der fehlerhaften Anwendung: 0x01d99f5fc6270fe4 Pfad der fehlerhaften Anwendung: C:\Program Files (x86)\Universal\Universal.Server.exe Pfad des fehlerhaften Moduls: C:\Windows\System32\KERNELBASE.dll Berichtskennung: 01da95b9-49d1-4cc0-be52-9d38b12fe282 Vollständiger Name des fehlerhaften Pakets: Anwendungs-ID, die relativ zum fehlerhaften Paket ist:
Recommended Answer
ok,
after opening this topics, I gave the service account the change rights to the following directory as a test. Now it’s working
C:\ProgramData\UniversalAutomationok,
after opening this topics, I gave the service account the change rights to the following directory as a test. Now it’s working
C:\ProgramData\UniversalAutomation