We have a windows service in production server which is Windows Server 2008 r2 standard and installed .net framework version 4.5.2 in it. Service stopped twice in last one week suddenly with below event viewer sourced exception :
Event Id :1026 , .net runtime exception:
Application: XXX.Application.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: System.AccessViolationException
Stack:
at System.Buffer.__Memcpy(Byte*, Byte*, Int32)
at System.Buffer.__Memcpy(Byte*, Byte*, Int32)
at System.Buffer._Memcpy(Byte*, Byte*, Int32)
at System.Buffer.Memcpy(Byte*, Byte*, Int32)
at System.String.ToCharArray()
at FluentValidation.Internal.Extensions+<>c__DisplayClassd`2[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.Nullable`1[[System.Decimal, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]], mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].<CoerceToNonGeneric>b__c(System.Object)
at FluentValidation.Validators.PropertyValidatorContext.get_PropertyValue()
at FluentValidation.Validators.AbstractComparisonValidator.IsValid(FluentValidation.Validators.PropertyValidatorContext)
at FluentValidation.Validators.PropertyValidator.Validate(FluentValidation.Validators.PropertyValidatorContext)
at FluentValidation.Internal.PropertyRule+<Validate>d__8.MoveNext()
at System.Linq.Enumerable+<SelectManyIterator>d__14`2[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089],[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].MoveNext()
at System.Collections.Generic.List`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]]..ctor(System.Collections.Generic.IEnumerable`1<System.__Canon>)
at System.Linq.Enumerable.ToList[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]](System.Collections.Generic.IEnumerable`1<System.__Canon>)
at FluentValidation.AbstractValidator`1[[System.__Canon, mscorlib, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089]].Validate(FluentValidation.ValidationContext`1<System.__Canon>)
Event ID :1000
Faulting application name: XX.Application.exe, version: 2.1.0.5017, time stamp: 0x59b1865e
Faulting module name: MSVCR120_CLR0400.dll, version: 12.0.51209.34209, time stamp: 0x5348a2f4
Exception code: 0xc0000005
Fault offset: 0x0000000000001630
Faulting process id: 0x12a8
Faulting application start time: 0x01d3307a3a9dca66
Faulting application path: XX.Application.exe
Faulting module path: C:\Windows\system32\MSVCR120_CLR0400.dll
Report Id: 5ea7c0b6-a0f0-11e7-8d71-0050568c317d
I've googled for a week but couldn't get any answer. Would you please help me about what could be the problem with our windows service or what should I do to find problem ? Thanks.