Udostępnij za pośrednictwem


Group Policy Sample Script Issue, solved

This is an interesting one-off that we felt would be worth posting.  Might help a few folks not pull their hair out one late evening…

Issue: Running the ‘getreportsforallgpos.wsf’ script from the GPMC sample scripts, from a command prompt (even as admin) – I get the following error message:

Exact syntax is: 

C:\Program Files\Microsoft Group Policy\Sample Scripts>cscript getreportsforallgpos.wsf c:\users\bob\desktop\gpoexport /domain:Contoso

Error:  (47, 18) (null) : A referral was returned from the server

Resolution:  Use the domain’s FQDN instead of short name (NetBIOS name)

Example:   C:\Program Files\Microsoft Group Policy\Sample Scripts>cscript getreportsforallgpos.wsf c:\users\bob\desktop\gpoexport /domain:Contoso.com

Hope that helps someone out there in the great big world someday.  Shout out to Roger Southgate, fellow PFE, for finding this gem.

 

Cheers!

Comments

  • Anonymous
    January 01, 2003
    Yeah no doubt :)  Glad it helped! Jeff

  • Anonymous
    July 10, 2012
    Thanks for posting this -- what an easy fix, if you know what it is :-)

  • Anonymous
    January 30, 2013
    simple but outstanding ..... thank you so much