Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Service Error #187

Closed
gtmsew opened this issue Nov 24, 2019 · 4 comments
Closed

Service Error #187

gtmsew opened this issue Nov 24, 2019 · 4 comments

Comments

@gtmsew
Copy link

gtmsew commented Nov 24, 2019

Hi, on the 2.7.0 today morning service on one of the server hang with below error details in Even Log:

Application: Myrtille.Services.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.InvalidOperationException
   at System.Diagnostics.Process.EnsureState(State)
   at System.Diagnostics.Process.get_HasExited()
   at Myrtille.Services.RemoteSessionProcess.ProcessExited(System.Object, System.EventArgs)
   at System.Diagnostics.Process.OnExited()
   at System.Diagnostics.Process.RaiseOnExited()
   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._ThreadPoolWaitOrTimerCallback.PerformWaitOrTimerCallback(System.Object, Boolean)

Faulting application name: Myrtille.Services.exe, version: 2.7.0.0, time stamp: 0x5dd40ff7
Faulting module name: KERNELBASE.dll, version: 10.0.14393.3321, time stamp: 0x5da7fdee
Exception code: 0xe0434352
Fault offset: 0x0000000000034c48
Faulting process id: 0xafc
Faulting application start time: 0x01d5a0f5f121dde2
Faulting application path: C:\Program Files (x86)\Myrtille\bin\Myrtille.Services.exe
Faulting module path: C:\Windows\System32\KERNELBASE.dll
Report Id: c8b68e3a-51d0-40a1-9e41-e9f19cbb094a
Faulting package full name: 
Faulting package-relative application ID: 

Setup info:
OS: Windows Server 2016
Type: VM on GCP
Hardware info: 6*CPU + 14GB RAM + 250GB SSD
Roles Installed: IIS, AD
This server works as a gateway to the RDS server
At that time there were around 10 users connected.

I did not find anything in the Myrtille Service Log, and when I started the service everything started to work normally. Currently I set up the service to try to recovery after fail, however it would be great to prevent this to happend in the future ;)

@cedrozor
Copy link
Owner

cedrozor commented Nov 25, 2019

Hi, thanks for the report. I modified in 2.7.0 the way to notify a session disconnect (https://github.com/cedrozor/myrtille/blob/master/Myrtille.Services/RemoteSessionProcess.cs#L455). It was to avoid deadlocks occuring in some rare cases when invoking the callback of a WCF duplex channel; but that's not good if it brings new issues :/

I will investigate and, at least, have the async task instanciation into a try/catch block so that it doesn't crash Myrtille.Services.exe.

cedrozor added a commit that referenced this issue Nov 27, 2019
…a disconnect notification (#187, thanks gtmsew)

the automatic application pool recycling is now disabled by default, and is not applicable if using the enterprise mode (this prevents enterprise sessions to be dropped unexpectedly!)
if recycling is enabled, a new http session is now acquired on disconnect; this prevents a subsequent login failure (due to the old http session being invalid) without any error message
@cedrozor
Copy link
Owner

cedrozor commented Nov 27, 2019

Did you had the issue happening again?
If yes, it should be fixed in myrtille 2.7.1.

@gtmsew
Copy link
Author

gtmsew commented Dec 5, 2019

It was one-time error for me.

@cedrozor
Copy link
Owner

cedrozor commented Dec 5, 2019

Well... anyway, I improved the exception handling around that call, so it shouldn't happen again

@cedrozor cedrozor closed this as completed Dec 5, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants