Jump to content

RPC across domains - "The RPC server is unavailable. (Exception from


Recommended Posts

Guest terry@foldingspace.net
Posted

Hi,

 

I'm having an issue using WMI to stop/start a service.

 

I have two domains, domain1 and domain2, domain1 is where the user

account and the Desktop I'm currently using is located. Domain2 is

where the target Server is located.

 

The Desktop PC in domain1 is using Windows XP Pro SP2, the Server PC

in domain2 is using Windows Server 2003 SP2.

 

There is a two way trust setup between domain1 and domain2.

 

The user account in domain1 is a member of the Administrators group in

Domain2 and is also a local administrator on the Server PC.

 

On the Desktop in domain1 I'm running a powershell script that

retrieves the WMI object for a service and then attempts to stop it:

 

# Get IIS Service

$W3service = get-wmiobject win32_service -computername

$RemoteWebServer -filter "name='W3SVC'";

 

# stop the service.

$W3service.StopService();

 

but it gives us an error:

 

Exception retrieving member "StopService": "The RPC server is

unavailable. (Exception from HRESULT: 0x800706BA)"

At line:1 char:16

+ $W3.StopService( <<<< )

 

If this script is run from a PC in domain2 whilst logged on as the

user from domain1 it works fine.

 

We've checked that all firewalls are off and restarted both the

Desktop and Server after applying all permissions.

 

As a workaround we have switched to using:

 

sc \\servername stop servicename

 

Could anyone give us an insight into why this is happening?

Any clues or comments would be greatly appreciated :)

 

AndyJ

  • Replies 6
  • Created
  • Last Reply
Guest Ace Fekay [MVP]
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

In news:3b160b47-2c15-47c2-b45e-6281202c6781@s8g2000prg.googlegroups.com,

terry@foldingspace.net <terry@foldingspace.net> typed:

> Hi,

>

> I'm having an issue using WMI to stop/start a service.

>

> I have two domains, domain1 and domain2, domain1 is where the user

> account and the Desktop I'm currently using is located. Domain2 is

> where the target Server is located.

>

> The Desktop PC in domain1 is using Windows XP Pro SP2, the Server PC

> in domain2 is using Windows Server 2003 SP2.

>

> There is a two way trust setup between domain1 and domain2.

>

> The user account in domain1 is a member of the Administrators group in

> Domain2 and is also a local administrator on the Server PC.

>

> On the Desktop in domain1 I'm running a powershell script that

> retrieves the WMI object for a service and then attempts to stop it:

>

> # Get IIS Service

> $W3service = get-wmiobject win32_service -computername

> $RemoteWebServer -filter "name='W3SVC'";

>

> # stop the service.

> $W3service.StopService();

>

> but it gives us an error:

>

> Exception retrieving member "StopService": "The RPC server is

> unavailable. (Exception from HRESULT: 0x800706BA)"

> At line:1 char:16

> + $W3.StopService( <<<< )

>

> If this script is run from a PC in domain2 whilst logged on as the

> user from domain1 it works fine.

>

> We've checked that all firewalls are off and restarted both the

> Desktop and Server after applying all permissions.

>

> As a workaround we have switched to using:

>

> sc \\servername stop servicename

>

> Could anyone give us an insight into why this is happening?

> Any clues or comments would be greatly appreciated :)

>

> AndyJ

 

I'm not much of a scripter, but I can tell you an "RPC service not

available" error usually means it can't resolve the name in DNS. I believe

if you specify by single computer name, as I believe I understand the

script, it may be using DNS to resolve it by normal devolution process,

which means it's using the machine's suffix to resolve it. How is DNS setup?

If these are two AD domains in different forests, you would also want to

configure conditional forwarding or hosts secondaries of each other. Then

try it again by using the machine's FQDN.

 

 

--

Regards,

Ace

 

This posting is provided "AS-IS" with no warranties or guarantees and

confers no rights.

 

Ace Fekay, MCSE 2003 & 2000, MCSA 2003 & 2000, MCSE+I, MCT,

MVP Microsoft MVP - Directory Services

Microsoft Certified Trainer

 

For urgent issues, you may want to contact Microsoft PSS directly. Please

check http://support.microsoft.com for regional support phone numbers.

 

Infinite Diversities in Infinite Combinations

Guest terry@foldingspace.net
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception

 

Re: RPC across domains - "The RPC server is unavailable. (Exception

 

On Mar 14, 4:54 am, "Ace Fekay [MVP]" <PleaseAs...@SomeDomain.com>

wrote:

> Innews:3b160b47-2c15-47c2-b45e-6281202c6781@s8g2000prg.googlegroups.com,

> te...@foldingspace.net <te...@foldingspace.net> typed:

>

>

>

>

>

> > Hi,

>

> > I'm having an issue using WMI to stop/start a service.

>

> > I have two domains, domain1 and domain2, domain1 is where the user

> > account and the Desktop I'm currently using is located. Domain2 is

> > where the target Server is located.

>

> > The Desktop PC in domain1 is using Windows XP Pro SP2, the Server PC

> > in domain2 is using Windows Server 2003 SP2.

>

> > There is a two way trust setup between domain1 and domain2.

>

> > The user account in domain1 is a member of the Administrators group in

> > Domain2 and is also a local administrator on the Server PC.

>

> > On the Desktop in domain1 I'm running a powershell script that

> > retrieves the WMI object for a service and then attempts to stop it:

>

> > # Get IIS Service

> > $W3service = get-wmiobject win32_service -computername

> > $RemoteWebServer -filter "name='W3SVC'";

>

> > # stop the service.

> > $W3service.StopService();

>

> > but it gives us an error:

>

> > Exception retrieving member "StopService": "The RPC server is

> > unavailable. (Exception from HRESULT: 0x800706BA)"

> > At line:1 char:16

> > + $W3.StopService( <<<< )

>

> > If this script is run from a PC in domain2 whilst logged on as the

> > user from domain1 it works fine.

>

> > We've checked that all firewalls are off and restarted both the

> > Desktop and Server after applying all permissions.

>

> > As a workaround we have switched to using:

>

> > sc \\servername stop servicename

>

> > Could anyone give us an insight into why this is happening?

> > Any clues or comments would be greatly appreciated :)

>

> > AndyJ

>

> I'm not much of a scripter, but I can tell you an "RPC service not

> available" error usually means it can't resolve the name in DNS. I believe

> if you specify by single computer name, as I believe I understand the

> script, it may be using DNS to resolve it by normal devolution process,

> which means it's using the machine's suffix to resolve it. How is DNS setup?

> If these are two AD domains in different forests, you would also want to

> configure conditional forwarding or hosts secondaries of each other. Then

> try it again by using the machine's FQDN.

>

> --

> Regards,

> Ace

>

> This posting is provided "AS-IS" with no warranties or guarantees and

> confers no rights.

>

> Ace Fekay, MCSE 2003 & 2000, MCSA 2003 & 2000, MCSE+I, MCT,

> MVP Microsoft MVP - Directory Services

> Microsoft Certified Trainer

>

> For urgent issues, you may want to contact Microsoft PSS directly. Please

> checkhttp://support.microsoft.comfor regional support phone numbers.

>

> Infinite Diversities in Infinite Combinations- Hide quoted text -

>

> - Show quoted text -

 

Thanks for the reply :)

 

We're using the FQDN "MachineName.Domain2.local" and that works fine,

it can be pinged and using the SC command also works without problem.

We have configured the DNS server in each domain with secondary zones.

Guest Ace Fekay [MVP]
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

In news:9c2e9e25-89e2-48cf-86ca-22f9d876934c@t54g2000hsg.googlegroups.com,

terry@foldingspace.net <terry@foldingspace.net> typed:

> Thanks for the reply :)

>

> We're using the FQDN "MachineName.Domain2.local" and that works fine,

> it can be pinged and using the SC command also works without problem.

> We have configured the DNS server in each domain with secondary zones.

 

Sounds great. :-)

 

Ace

Guest terry@foldingspace.net
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception

 

Re: RPC across domains - "The RPC server is unavailable. (Exception

 

On Mar 14, 11:37 am, "Ace Fekay [MVP]" <PleaseAs...@SomeDomain.com>

wrote:

> Innews:9c2e9e25-89e2-48cf-86ca-22f9d876934c@t54g2000hsg.googlegroups.com,

> te...@foldingspace.net <te...@foldingspace.net> typed:

>

> > Thanks for the reply :)

>

> > We're using the FQDN "MachineName.Domain2.local" and that works fine,

> > it can be pinged and using the SC command also works without problem.

> > We have configured the DNS server in each domain with secondary zones.

>

> Sounds great. :-)

>

> Ace

 

Ahhhh I didn't explain very clearly ;)

 

That was all done and setup previously and the issue still remains,

the SC command works and we are now using that route but going via WMI

we still get the RPC error message.

 

It's why the WMI/RPC is failing that I'd like to find out.

Guest Ace Fekay [MVP]
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

In news:4b27f7b5-afe1-4c93-9f2d-d08f8562db41@s19g2000prg.googlegroups.com,

terry@foldingspace.net <terry@foldingspace.net> typed:

> Ahhhh I didn't explain very clearly ;)

>

> That was all done and setup previously and the issue still remains,

> the SC command works and we are now using that route but going via WMI

> we still get the RPC error message.

>

> It's why the WMI/RPC is failing that I'd like to find out.

 

Sorry about that. Thought you meant the FQDN worked and didn't try it

before.

 

WMI/RPC failures. If not DNS, then I would imagine if RPC permissions is not

enabled, incorrect DCOM permissions for the account, local firewall, etc,

may be the cause.

 

See if the following help:

 

 

RPC Server Unavailable when auditing machines running Windows 2003 SP1 or XP

SP2

http://www.microforge.net/kb/39

 

Topic: WMI Can't Connect - RPC server unavailable

http://www.systemtools.com/board/Forum13/HTML/000023.html

 

 

WMI : The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)

(scroll to bottom past the ads):

http://www.experts-exchange.com/Programming/Languages/.NET/Visual_Basic.NET/Q_22875156.html

Guest Ace Fekay [MVP]
Posted

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

Re: RPC across domains - "The RPC server is unavailable. (Exception from HRESULT: 0x800706BA)"

 

In news:4b27f7b5-afe1-4c93-9f2d-d08f8562db41@s19g2000prg.googlegroups.com,

terry@foldingspace.net <terry@foldingspace.net> typed:

>

> It's why the WMI/RPC is failing that I'd like to find out.

 

Oops, hit send to soon.

 

One more that may help troubleshoot it:

 

WMI Isn't Working! Troubleshooting Problems with WMI Scripts and the WMI

Service:

http://www.microsoft.com/technet/scriptcenter/topics/help/wmi.mspx

 

Ace


×
×
  • Create New...