EDA windows Task Scheduler error running sync

We are trying to get EDA sync to run on the task scheduler and keep getting this error.
The user is a domain admin AD account. we are on .net 4.8 on that db server and the app server where EDA sync lives.

below is the error


Application: SyncCLI.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.Security.Authentication.AuthenticationException
   at System.Net.Security.SslState.StartSendAuthResetSignal(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest, System.Exception)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[], Int32, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[], Int32, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[], Int32, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[], Int32, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessReceivedBlob(Byte[], Int32, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.StartReceiveBlob(Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.CheckCompletionBeforeNextReceive(System.Net.Security.ProtocolToken, System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ForceAuthentication(Boolean, Byte[], System.Net.AsyncProtocolRequest)
   at System.Net.Security.SslState.ProcessAuthentication(System.Net.LazyAsyncResult)
   at System.Threading.ExecutionContext.RunInternal(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
   at System.Net.TlsStream.ProcessAuthentication(System.Net.LazyAsyncResult)
   at System.Net.TlsStream.Write(Byte[], Int32, Int32)
   at System.Net.PooledStream.Write(Byte[], Int32, Int32)
   at System.Net.ConnectStream.WriteHeaders(Boolean)

Exception Info: System.Net.WebException
   at System.Net.HttpWebRequest.GetResponse()
   at Phocas.Sync.Client.Utilities.SendJsonPost[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=]](System.String, System.String, System.String, System.String, System.Object, Int32)

Exception Info: System.Exception
   at Phocas.Sync.Client.Utilities.SendJsonPost[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=]](System.String, System.String, System.String, System.String, System.Object, Int32)
   at SyncCLI.Program+DataSourceWrapper.TestServerConnection(System.String, System.String, System.String, System.String)
   at SyncCLI.Program.InnerMain(System.String[])
   at SyncCLI.Program.Main(System.String[])

We had to run it as the AD Admin account… I’m not sure if it’s a ‘logon as service’ or ‘impersonate’ setting on the AD account that needs to be there in order for the OS System to spawn a task as the user you specified in the Task configuration.

1 Like

Thanks Mike. we updated that setting and sync still did not run via the task agent when logged off.
when i log in with my AD and open task agent i can hit Run on those tasks and it works.
Are there any other ideas out there?

ok, let’s see if this helps… I’ll assume the SYNC works manually, so here is the Task Scheduler Entry broken down for you. I would focus on the first screen, red box.

image

image

image

image

image

1 Like

yep we have all those set correct. that was the first thing Epicor support looked at.

we had to create a new AD account. not sure why the other one wasnt working but with a new Ad and log on as service set up on the AD it worked.

1 Like

Glad I could help (?) :slight_smile: