NAS freezes with heavy import at CREATEOUTSTREAM

GhaiathOgt
Member Posts: 4
Hi all,
I'm facing an issue that drive me crazy, I hope I can find the answer among all you experts.
We are running NAV2009R2 with a Navision Application server that run as a windows service.
When we do import documents via NAS, sometimes, the import just freeze in the job queue with status "In progress", to solve that, we do restart the NAS windows service and then the import continues. When I restart the service, I get "Error 109, The Pipe has been ended".
Added some log lines in the code to see where it stopps. I can see it always stopps at "rRequest.Data.CREATEOUTSTREAM(RequestOutStream)"
Along with the import, we do a SOAP request in a separate codeunit where the code execution freezes.
The strange thing is there are two companies in the same database. And the problem occurs only in one of them.
The problem occurs usually along with heavy import. There is no problem with few documents but when NAS import too many documents, the probability is much higher that the problem will occur.
What I tried:
* Uninstall NAS service and reinsall it.
* Create a new service user and changed the user running the NAS service.
* Checked any deadlocks in the database. Using extended events and SQL profiler.
* Followed the SOAP request using Wireshark and Fiddler.
* Used Process monitor to see if there are any thread block.
* Checked Event Viewer.
None of the above showed any hint where is the problem.
Googled a lot and the most similar case is here: https://forum.mibuso.com/discussion/49235/nas-getting-stuck-when-ran-as-service
The common thing is that the user has proxy settings in internet options.
Any idea, hint?
I'm facing an issue that drive me crazy, I hope I can find the answer among all you experts.

We are running NAV2009R2 with a Navision Application server that run as a windows service.
When we do import documents via NAS, sometimes, the import just freeze in the job queue with status "In progress", to solve that, we do restart the NAS windows service and then the import continues. When I restart the service, I get "Error 109, The Pipe has been ended".
Added some log lines in the code to see where it stopps. I can see it always stopps at "rRequest.Data.CREATEOUTSTREAM(RequestOutStream)"
Along with the import, we do a SOAP request in a separate codeunit where the code execution freezes.
rDataLog.INSERT(TRUE); Dlg.Update(4, 'Create SOAP request...'); SLEEP(10); CLEAR(btSoapEnvelope); btSoapEnvelope.ADDTEXT('<?xml version="1.0" encoding="utf-8"?>'); btSoapEnvelope.ADDTEXT('<soapenv:Envelope '); . . btSoapEnvelope.ADDTEXT('<soapenv:Header>'); . . btSoapEnvelope.ADDTEXT('</soapenv:Header>'); btSoapEnvelope.ADDTEXT('<soapenv:Body>'); . . btSoapEnvelope.ADDTEXT('</soapenv:Body>'); btSoapEnvelope.ADDTEXT('</soapenv:Envelope>'); rRequest.Data.CREATEOUTSTREAM(RequestOutStream); btSoapEnvelope.WRITE(RequestOutStream); rRequest.Data.CREATEINSTREAM(RequestInStream); xmlhttp.open('POST', 'https:\\soapEndPoint'); xmlhttp.setRequestHeader('Content-Type', 'text/xml; charset=utf-8'); xmlhttp.setRequestHeader('SoapAction', rType."Soap Action"); xmlhttp.send(RequestInStream); xmlhttp.waitForResponse(500); Dlg.Update(4, 'Wait for an answer...'); SLEEP(10); xmldomResponse4 := xmlhttp.responseXML; xmldomResponse4.save(ResponseOutStream); rDataLog.Response.CREATEOUTSTREAM(osResponse); xmldomResponse3.save(osResponse); rDataLog.MODIFY; COMMIT;
The strange thing is there are two companies in the same database. And the problem occurs only in one of them.
The problem occurs usually along with heavy import. There is no problem with few documents but when NAS import too many documents, the probability is much higher that the problem will occur.
What I tried:
* Uninstall NAS service and reinsall it.
* Create a new service user and changed the user running the NAS service.
* Checked any deadlocks in the database. Using extended events and SQL profiler.
* Followed the SOAP request using Wireshark and Fiddler.
* Used Process monitor to see if there are any thread block.
* Checked Event Viewer.
None of the above showed any hint where is the problem.
Googled a lot and the most similar case is here: https://forum.mibuso.com/discussion/49235/nas-getting-stuck-when-ran-as-service
The common thing is that the user has proxy settings in internet options.
Any idea, hint?
0
Answers
-
Well, the quick work-around solution is of course to ensure you never have to perform heavy import
Maybe it could be related to your NAV 2009R2 version. Are you on build 6.0.38655 ?0 -
Thanks @jesperkenborg,
We actually have all documents in one file, and will be a bit harder to separate it apart. But yes, I agree, it's a work-around.
Version we use: 6.00.32942.0 -
If it will be hard to separate, then I suggest you start out with the build upgrade to 6.0.386550
-
Hello @GhaiathOgt,
You could try to use an XML Document instead an OutStream/Instream and see what happens.
I mean this type of variableName DataType Subtype Length XMLDoc Automation 'Microsoft XML, v3.0'.DOMDocument
You can create the SOAP document with that variable and send it the same way you are doing now.xmlhttp.send(XMLDoc);
Regards.0 -
Thanks @ftornero. I'll give it a try.0
-
I tried to install last version of Nav2009 R2 from Microsoft partner website but I got an older version than 6.0.38655. @jesperkenborg Do you know where I can install last build version of Nav2009 R2? I it 6.0.38655?0
-
0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions