You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
PowerShell error from Edge on Win 10 connecting to Server 2016 #697
Exception:
System.UnauthorizedAccessException: Access to the path 'PSReadlineHistoryFile_46696421' is denied.
at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
at System.Threading.Mutex.MutexTryCodeHelper.MutexTryCode(Object userData)
at System.Runtime.CompilerServices.RuntimeHelpers.ExecuteCodeWithGuaranteedCleanup(TryCode code, CleanupCode backoutCode, Object userData)
at System.Threading.Mutex.CreateMutexWithGuaranteedCleanup(Boolean initiallyOwned, String name, Boolean& createdNew, SECURITY_ATTRIBUTES secAttrs)
at System.Threading.Mutex..ctor(Boolean initiallyOwned, String name, Boolean& createdNew, MutexSecurity mutexSecurity)
at System.Threading.Mutex..ctor(Boolean initiallyOwned, String name)
at Microsoft.PowerShell.PSConsoleReadLine.DelayedOneTimeInitialize()
at Microsoft.PowerShell.PSConsoleReadLine.Initialize(Runspace runspace, EngineIntrinsics engineIntrinsics)
at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)
I have the same Problem.
I when I try to use the PowerShell function in Windows Admin Center.
The Setup witch is not working:
The Windows Admin Center is installed at a Server 2016 (Name: Server1).
Admin1 = not Admin at Server1 but have Client Admin Rights at Client1 and Client2
Admin2 = Admin at Server1 and have Client Admin Rights at Client1 and Client2
Admin1 is using the Admin Center via Web (Server1) on the Client1 and want to Administrate Client2.
Every function is working correct just the PowerShell function is not working with the upper error message.
Admin2 is using the Admin Center via Web on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
The Setup witch is working:
The Windows Admin Center is installed at Client1.
Admin1 = not Admin at Server1 but have Client Admin Rights at Client1 and Client2
Admin2 = Admin at Server1 and have Client Admin Rights at Client1 and Client2
Admin1 is using the Admin Center via Web (localhost) on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
Admin2 is using the Admin Center via Web on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
#1061 and #1602 were made to improve how PSReadLine uses mutex for history file. Also, it's been a long time that I don't see new issues reporting about UnauthorizedAccessException regarding the mutex. So I think the issue was resolved. Please upgrade to the 2.1.0 version of PSReadLine from PowerShell Gallery.
See the upgrading section for instructions. Please let us know if you run into the same issue with the latest version.
Activity
lzybkr commentedon Jun 4, 2018
Do you have more information on how to reproduce the problem?
Without additional details, the best I can probably do is just suppress the error and not use the history file.
Protesthb commentedon Jul 23, 2018
Hi lzybkr,
I have the same Problem.
I when I try to use the PowerShell function in Windows Admin Center.
The Setup witch is not working:
The Windows Admin Center is installed at a Server 2016 (Name: Server1).
Admin1 = not Admin at Server1 but have Client Admin Rights at Client1 and Client2
Admin2 = Admin at Server1 and have Client Admin Rights at Client1 and Client2
Admin1 is using the Admin Center via Web (Server1) on the Client1 and want to Administrate Client2.
Every function is working correct just the PowerShell function is not working with the upper error message.
Admin2 is using the Admin Center via Web on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
The Setup witch is working:
The Windows Admin Center is installed at Client1.
Admin1 = not Admin at Server1 but have Client Admin Rights at Client1 and Client2
Admin2 = Admin at Server1 and have Client Admin Rights at Client1 and Client2
Admin1 is using the Admin Center via Web (localhost) on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
Admin2 is using the Admin Center via Web on the Client1 and want to Administrate Client2.
Every function is working correct also the PowerShell function.
Regards,
Protesthb
daxian-dbw commentedon Feb 22, 2021
#1061 and #1602 were made to improve how PSReadLine uses mutex for history file. Also, it's been a long time that I don't see new issues reporting about
UnauthorizedAccessExceptionregarding the mutex. So I think the issue was resolved. Please upgrade to the 2.1.0 version of PSReadLine from PowerShell Gallery.See the upgrading section for instructions. Please let us know if you run into the same issue with the latest version.