Dec
24
2012

Get-WmiObject: The RPC server is unavailable (Exception from HRESULT: 0x80070721)

While I tried to use PowerShell to find disk space of a remote server using WMI query,

Get-WmiObject -computer <myservername> win32_volume

 

…faced following error/s,

——-

Error 1:

Get-WmiObject : The RPC server is unavailable

 

Error 2:

Get-WmiObject : A security package specific error occurred. (Exception from HRESULT: 0x80070721)

 

——

After some Googling and search found some useful tips to troubleshoot the issue, please find below the consolidated troubleshooting steps,

 

1) Check that DCOM is enabled on both the host and the target PC. Check the following registry value on both computers:
Key: HKLM\Software\Microsoft\OLE, value: EnableDCOM, should be set to ‘Y’

2) On a Windows XP Pro computer, make sure that remote logons are not being coerced to the GUEST account (aka “ForceGuest”, which is enabled by default computers that are not attached to a domain). To do this, open the Local Security Policy editor (e.g. by typing ‘secpol.msc’ into the Run box, without quotes). Expand the “Local Policies” node and select “Security Options”. Now scroll down to the setting titled “Network access: Sharing and security model for local accounts”. If this is set to “Guest only”, change it to “Classic” and restart your computer.

3) Make sure that no remote access or WMI-related services have been disabled. On an machine, the following services should be running (or at least allowed to start on demand):

COM+ Event System
Remote Access Auto Connection Manager
Remote Access Connection Manager
Remote Procedure Call (RPC)
Remote Procedure Call (RPC) Locator
Remote Registry
Server
Windows Management Instrumentation
Windows Management Instrumentation Driver Extensions
WMI Performance Adapter
Workstation

4) Also check to make sure that your antivirus software isn’t running any type of firewall protocol that would be preventing access.

There is also some good info on troubleshooting winrm and wsman here: http://www.computerperformance.co.uk/powershell/powershell_wsman.htm

 

5)

Under the Local Computer Policy heading, double-click Computer Configuration.
Double-click Administrative Templates, Network, Network Connections, and
then Windows Firewall.
If the computer is in the domain, then double-click Domain Profile;
otherwise, double-click Standard Profile.
Click Windows Firewall: Allow remote administration exception.
On the Action menu, select Properties.
Click Enable, and then click OK.

 

6) Might be a bug in system as per MSKB article: http://support.microsoft.com/kb/960007

Bug is: FIX: Error message when you run an application that makes “burst load” style activation requests and calls a server component through DCOM: “0x800706ba” or “0x800706bf”

 

In my case I suspect the bug, trying to get the hotfix installed to fix the issue.

 

Useful References:

http://social.technet.microsoft.com/Forums/en-US/winserverpowershell/thread/f15f233f-097f-42fd-8c05-1aa1d03e4646/

http://stackoverflow.com/questions/11330874/get-wmiobject-the-rpc-server-is-unavailable-exception-from-hresult-0x800706

http://www.techtalkz.com/microsoft-windows-powershell/426873-rpc-server-unavaliable.html

http://social.technet.microsoft.com/Forums/sk/winserverpowershell/thread/e0007dde-3a65-412b-8070-d7604069bf6f

Download PDF

About the Author: Nitin G

Indian born, trekker, biker, photographer, lover of monsoons. I've been working full time with SQL Server since year 2005 and blogs to post the content aquired during my research on new topics or fixing issues faced by me as a DBA while working in different kind of projects, hope some of my posts may helps others in SQLDBA community. Everything you read on my blog is my own personal opinion and any code is provided "AS-IS" with no warranties!

Leave a comment

Subscribe to this blog via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Join 108 other subscribers

Translate this blog!

EnglishFrenchGermanItalianPortugueseRussianSpanish

Calender

December 2018
M T W T F S S
« Nov    
 12
3456789
10111213141516
17181920212223
24252627282930
31  

View Post by Categories

%d bloggers like this: