Monday, 20 May 2019

windows 10 - query session command gives error code 5 even when AllowRemoteRPC is set to 1


in cmd, 'Query Session' command is returning,


Error 5 getting sessionnames
Error [5]:Access is denied

on Windows 10 Remote desktop - Administrator user.


we have set, AllowRemoteRPC 's value to 1


under this HKLM\SYSTEM\CurrentControlSet\Control\Terminal Server


But still problem persists.


Questions:



  • what does AllowRemoteRPC actually do and how it's value is being used.

  • what to do to make Query Session command work.



Answer



I think the problem is in the UAC remote restrictions.


Do this on the target computer:



  • Run regedit


  • Navigate to the following registry subkey:


    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System


  • If an entry named LocalAccountTokenFilterPolicy registry entry does not exist, create it as DWORD




  • Double-click LocalAccountTokenFilterPolicy and set its value to 1.




Reference:


Microsoft's Description of User Account Control and remote restrictions in Windows Vista.


No comments:

Post a Comment

How can I VLOOKUP in multiple Excel documents?

I am trying to VLOOKUP reference data with around 400 seperate Excel files. Is it possible to do this in a quick way rather than doing it m...