I've run into a strange problem that I suspect may be related to DC replication.
We have two DCs, let's called them domaincontroller1
and domaincontroller2
for the purpose of this question.
We've put a Powershell file (.ps1 extension) in \\domain.local\sysvol\domain.local\scripts\Logon
. This is used as a GPO logon script.
On some machines on our domain, the script is working as intended. On others, Event Viewer reports that the file can't be accessed.
If I run \\domain.local\sysvol\domain.local\scripts\Logon
from my desktop, I can see a load of scripts - but not the PowerShell script in question.
If I run \\domaincontroller2\sysvol\domain.local\scripts\Logon
, I still can't see the PowerShell script.
However, if I run \\domaincontroller1\sysvol\domain.local\scripts\Logon
, I can.
If I log on to domaincontroller1
and run \\domain.local\sysvol\domain.local\scripts\Logon
, I can also see the file.
I've tried running repadmin /replicate domaincontroller2 domaincontroller1
in case that was the problem, but this says "Sync completed successfully" and still the file doesn't appear.
[EDIT] Additional information:
We're using FRS for SYSVOL replication.
Here's an excerpt from today's FRS log (from DOMAINCONTROLLER1
, the PDC) which may highlight the problem:
<SndCsMain: 5708: 883: S0: 13:46:04> ++ ERROR - EXCEPTION (000006ba) : WStatus: RPC_S_SERVER_UNAVAILABLE
<SndCsMain: 5708: 884: S0: 13:46:04> :SR: Cmd 0ba573b0, CxtG 3fdec058, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - rpc exception]
<SndCsMain: 5708: 904: S0: 13:46:04> :SR: Cmd 0ba573b0, CxtG 3fdec058, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - Send Penalty]
<FrsHashCalcString: 6048: 5192: S0: 13:46:04> Name = S-1-5-21-201938778-1626411824-782984527-19720
<SERVER_FrsRpcSendCommPkt: 6048: 449: S0: 13:46:04> ++ ERROR - Invalid Partner: AuthClient:DOMAIN\DOMAINCONTROLLER2$, AuthSid:S-1-5-21-201938778-1626411824-782984527-19720
<FrsHashCalcString: 6360: 5192: S0: 13:46:04> Name = S-1-5-21-201938778-1626411824-782984527-19720
<SERVER_FrsRpcSendCommPkt: 6360: 449: S0: 13:46:04> ++ ERROR - Invalid Partner: AuthClient:DOMAIN\DOMAINCONTROLLER2$, AuthSid:S-1-5-21-201938778-1626411824-782984527-19720
<SndCsMain: 5708: 883: S0: 13:46:25> ++ ERROR - EXCEPTION (000006ba) : WStatus: RPC_S_SERVER_UNAVAILABLE
<SndCsMain: 5708: 884: S0: 13:46:25> :SR: Cmd 0ba570b0, CxtG 08968a89, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - rpc exception]
<SndCsMain: 5708: 904: S0: 13:46:25> :SR: Cmd 0ba570b0, CxtG 08968a89, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - Send Penalty]
<FrsDsFindComputer: 2204: 9312: S2: 13:48:52> :DS: Computer FQDN is cn=DOMAINCONTROLLER1,ou=domain controllers,dc=domain,dc=local
<FrsDsFindComputer: 2204: 9318: S2: 13:48:52> :DS: Computer's dns name is DOMAINCONTROLLER1.domain.local
<FrsDsFindComputer: 2204: 9332: S2: 13:48:52> :DS: Settings reference is cn=ntds settings,cn=DOMAINCONTROLLER1,cn=servers,cn=default-first-site-name,cn=sites,cn=configuration,dc=domain,dc=local
<SndCsMain: 5708: 883: S0: 13:49:13> ++ ERROR - EXCEPTION (000006ba) : WStatus: RPC_S_SERVER_UNAVAILABLE
<SndCsMain: 5708: 884: S0: 13:49:13> :SR: Cmd 0ba57230, CxtG 08968a89, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - rpc exception]
<SndCsMain: 5708: 904: S0: 13:49:13> :SR: Cmd 0ba57230, CxtG 08968a89, WS RPC_S_SERVER_UNAVAILABLE, To OLDDOMAINCONTROLLER.domain.local Len: (364) [SndFail - Send Penalty]
<FrsHashCalcString: 6360: 5192: S0: 13:49:13> Name = S-1-5-21-201938778-1626411824-782984527-19720
<SERVER_FrsRpcSendCommPkt: 6360: 449: S0: 13:49:13> ++ ERROR - Invalid Partner: AuthClient:DOMAIN\DOMAINCONTROLLER2$, AuthSid:S-1-5-21-201938778-1626411824-782984527-19720
Our old DC is still being referenced in there (I'm not actually sure if that was ever demoted, or just turned off!) but I think the bigger problem is the line ++ ERROR - Invalid Partner: AuthClient:DOMAIN\DOMAINCONTROLLER2$
- that DC is still active and clearly isn't replicating correctly.
Any help would be greatly appreciated.