Want to access performance counters via WMI. Receive the following error when accessing the local counters (when attempting to authenticate) on my 64 bit Windows 7 work station.
org.jinterop.dcom.common.JIException: Access is denied, please check whether the are correct. …, so as to avoid such exceptions.
In the following Java code the 'new JIComServer' call produces the above error. Domain is "localhost", hostname is the work station name, username and password are my login on Windows 7. My login has been granted administrator privilege.
dcomSession = init(domain, username, password);
comServer = new JIComServer(valueOf("WbemScripting.SWbemLocator"), hostname, dcomSession);
On the windows 7 workstation in 'Component Services->My Computer->Properties->Default Properties' 'Distributed COM' and 'COM Internet Services' are both enabled. 'Default Authentication Level' is set to Connect. 'Default Impersonation Level' is set to Identify.
In 'COM Security->Access Permissions' my login has Local and Remote Access checked.
In 'COM Security->Launch and Access Permissions' my login has Local and Remote with Launch and Activation checked. i.e. all 4 check boxes.
Help! Would very much like to use j-Interlop.
Note: A C++ program running under my login encounters no issues authenticating and issuing WMI queries to the local Windows 7 workstation.
Can u check permission on HKEY_CLASSES_ROOT\CLSID\76a64158-cb41-11d1-8b02-00600806d9b6, which is for the WBEM Scripting Locator.
It worked. Thank you!
I'm having the same issue. If I enable autoRegistration, I get access denied. Tried modifying the HKCR key but no change.
On Win7, i think only the "TrustedInstaller" has the right to make changes to the Hive. Can you confirm ?
i'm having the same issues too. I tried to run the examples MSADO, MSWMI and MSWMI2 provided in the test package. However, in all three cases i get the "Access is denied" error message. Changing permissions of WBEM Scripting Locator has no effect. Also i ran the examples locally and remote, involving different user accounts. The result is always the same…
I'm kinda stuck. There must be a way to successfully execute the examples. Any suggestions are greatly appreciated…
Thanks in advance
Can you check the "Local Security Policy" , what does it say for "Network Access: Sharing and security model for Local accounts " ? Should be "Classic -- " .
thanks for your answer. While searching this forum for possible solutions, I already stumbled upon the local security policy hint. However, even though its set to 'Classic- …', i am still getting the 'access denied' error message.
Any other advice?
Btw, my OS is Win7x64…
If you're running x64, can you check the permission for for the following registry key also?
It may occurs when a user have empty password in the system.
Log in to post a comment.
Sign up for the SourceForge newsletter:
You seem to have CSS turned off.
Please don't fill out this field.