We are using the Dynamics GP web services in our project and we find that over the night the service will not respond anymore and will actually error out. I have to go into the services and restart the Dynamics Service Host. Has anyone encountered this as well? Is there a fix for this?
*This post is locked for comments
For the scripts listed, you can modify them to work with Office365 by doing the following:
First, Generate an encrypted password file by doing the following (in PowerShell):
Read-Host -Prompt "Enter Password" -AsSecureString | ConvertFrom-SecureString | Out-File "Path"
*Path is the path to where you want to save the file (ie. c:\temp\pass.txt
Second, Then you can edit the RestartGPWebService_Email.ps1 file to have the following:
$AdminName = "email@emailaddress.com"
$Pass = Get-Content "C:\Conexus\Prod-Scripts\creds.txt" | ConvertTo-SecureString
$cred = new-object -typename System.Management.Automation.PSCredential -argumentlist $AdminName, $Pass
send-mailmessage -to "to_email@emailaddress.com" -from "from_email@emailaddress.com" -subject "Email Subject goes here" -Body "Email body goes here" -SmtpServer "smtp.office365.com" -UseSsl -Port "587" -Credential $cred
I hope it helps!
After Microsoft bailed on fixing this (I still call it a bug) I taught myself just enough PowerShell to generate this solution. It's worked well here for a last few years. Our Web Services outages since are measures in minutes, not days.
The email piece is not required, it just helps me track the restarts.
Thank you David,
I'm going to check this out and try to implement that on the customer site.. The only thing I might not be able to do is the e-mail notification, as they use Office 365 and already have jobs that fail to authenticate every once in a while when trying to send e-mail notifications thru the SMTP gateway of O365..
I actually came up with a decent solution to the HRESULT: 0x80070006 (E_HANDLE)) error a few years ago.
First Microsoft said it was our network causing the issue, then when we paid them to take a look, it was a never-fix GP Web Services bug.
My solution was a combination of a PowerShell script looking in the event log for that error, and a Windows Scheduler task to kick it off.
Thanks Lucas Miller for the input.
I'm going to check around if I can find a way to track the event logs and catch that type of error messages early in the case this happens again.. I used to have a centralized monitor for critical windows services, but it would be of no help in such situations, as the service isn't really failing.. it just can't communicate anymore with the back-end data server.
Have a nice day
Beat,
This is something we've been asked about often, but in conversations with the Dynamics GP Dev folks we found out that it is actually an issue with the Authorization Manager (AzMan) functionality that GP Web Services relies on that fails when the connection to the security store (e.g. a SQL Server instance) is lost. So, there really isn't anything that can be patched.
At one time there was a Product Suggestion entered around this, so the Product Group was made aware of it, but this would require a larger change than just GP Web Services.
I know some customers are using a workaround that involves an automated task that checks for the "Handle is invalid" error that signifies the issue and restarts the GP Service Host service in response.
I don't know if that issue was fixed with a patch.. but I'd hope so at least in GP 2018...
I have customer running GP 2016 and using GP Web Services on a dedicated app server for CRM on-Prem to make calls to the GP back-end.. every once in a while the integration stops working and we have to restart the GP Web Services on the app server..
Last week the SQL back-end server was rebooted due to windows updates applied, but the other systems did not.. guess what, the integration stopped working and we didn't realized that the GP Web Services had lost connectivity with the SQL back-end due to the reboot.. This is very annoying, because you don't get any helpful messages to track down the issue..
Hello,
Any idea if this was fixed by a recent patch?
We recently upgraded to GP 2016 web services and we're still getting this same issue once in a while. Our workaround for now is to just restart the service.
This is a known issue with GP 2010 Web Services. We have seen the same for many customers. We end up scheduling a daily reset of Web Services until MS resolve this.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,253 Super User 2024 Season 2
Martin Dráb 230,188 Most Valuable Professional
nmaenpaa 101,156