3 Replies Latest reply: Mar 9, 2017 11:54 AM by Vindhya Giri RSS

    Error: Failed to create QlikView Engine

    Ali Azizi

      Hi guys

       

      We are running QV11.2 SR15 on Windows 2012 R2. We recently upgraded from QV11.2 SR11 to this SR15 version.

       

      After upgrading we are experiencing some warning issues for some reloading tasks on the publisher server. It's not occuring constantly and not for all tasks, but most likely randomly in different times and for different tasks.

       

      The publisher server has 2 x "Intel(R) Xeon(R) CPU E5-2643 v3 @ 3.40GHz, 3396 Mhz, 6 Core(s), 12 Logical Processor(s)", and the "Max number of simultaneous QlikView engines for distribution" is set to 10. The server is a physical machine.

       

      The error messages we get in the task log is as following:

      Information Attempt:01

      Error Failed to create QlikView Engine.. Exception=System.Runtime.InteropServices.COMException (0x80080005)...

      Information Failed to create QlikView Engine - Cleanup and retry (3 second pause before trying again)

      Information Attempt:11

      .

      .

      Information Failed to create QlikView Engine - Cleanup and retry (3 second pause before trying again)

      Warning Failed to allocate new QlikView Engine. Retrying! Current usage count=8 of 10 (of type non-reader).

      Information Allocating new QlikView Engine. Current usage count=5 of 10 (of type non-reader).

      Information Max retries:5

      Information Attempt:01

      Information Opened the QlikView Engine successfully. ProcessID=8160

       

      And then the task runs successfully.

       

      Do you know anything about this issue?

       

      Thank you in advance

        • Re: Error: Failed to create QlikView Engine
          Chip Matejowsky

          Hello Ali,

          Typically this warning is returned when there are more Publisher tasks scheduled than there are available QlikView engines. You'll notice in the snippet of the task log you created, that after the warning there are available engines to complete the task.

           

          The tell here is the error: "Error Failed to create QlikView Engine.. Exception=System.Runtime.InteropServices.COMException (0x80080005)..." this error indicates you're running into Windows default limitation of 10 COM objects, commonly known as the Desktop Memory Heap.


          The memory heap is a Windows settings that effects the number of concurrent processes of the same kind. If you enable a high number of reload engines, and start seeing windows errors related to Windows running out of DeskTop Heap Size. This will be visible in the Windows System Event log, with errors saying "DeskTop Heap exhausted". If so, you will need to adjust Windows DeskTop Heap Size to allow for a higher server load.

          IMPORTANT: Windows registry changes are made at your own risk and are not supported by Qlik Support. Please make a backup of the Windows registry before applying changes to enable rollback if the settings change fails or introduces Windows instability.

          Desktop Memory Heap size is control in the following Windows registry key:
          HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Session Manager\SubSystems\Windows

          Change the desktop heap setting by setting the SharedSection value to 1024,20480,2048. After change the registry key should look something like the following (all on one line):

          %SystemRoot%\system32\csrss.exe ObjectDirectory=\Windows
          SharedSection=1024,20480,2048 Windows=On SubSystemType=Windows
          ServerDll=basesrv,1 ServerDll=winsrv:UserServerDllInitialization,3
          ServerDll=winsrv:ConServerDllInitialization,2 ProfileControl=Off
          MaxRequestThreads=16

          Notice that the default value is 1024,3072,512 in x86 or 1024,20480,768 in x64 environments.

          Microsoft references on Windows heap size:
          http://blogs.msdn.com/ntdebugging/archive/2007/07/05/desktop-heap-part-2.aspx
          http://blogs.msdn.com/ntdebugging/archive/2007/01/04/desktop-heap-overview.aspx

          Microsoft reference regarding Windows heap and Server 2012:
          https://support.microsoft.com/en-us/kb/947246

          - Chip

            • Re: Error: Failed to create QlikView Engine
              Ali Azizi

              Thank you Chip for your response

              • Re: Error: Failed to create QlikView Engine
                Vindhya Giri

                Hi Chip,

                 

                We are using Tidal Scheduler for scheduling our DLY and MTH QV cycles through EDX.

                We recently upgraded from QV 11.2 to QV12.10 SR1.

                After the upgrade , tested the tasks and cycles through tidal as well as QMC. Did not come across any issues.

                 

                Yesterday, In our DEV machine, when trying to run the tasks through Tidal, some of the tasks completed normally but for some of them I am getting the following in task log. Also, this is bringing down our server. We had to reboot the server.

                 

                QMC task log Error:

                 

                Error: Failed to create QlikView Engine.. Exception=System.Runjavascript:void(0)time.InteropServices.COMException (0x8007012B): Retrieving the COM class factory for component with CLSID {BE1F19B5-415E-11D1-934D-0040333C91CC} failed due to the following error: 8007012b Only part of a ReadProcessMemory or WriteProcessMemory request was completed. (Exception from HRESULT: 0x8007012B). ||    at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) ||    at System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) ||    at System.Activator.CreateInstance(Type type, Boolean nonPublic) ||    at System.Activator.CreateInstance(Type type) ||    at QVBWrapper.Document.<CreateQVBProcess>b__123_0(Boolean mutexCreated) ||    at SolutionGlobal.GlobalMutex.Lock(Action`1 action, TimeSpan timeout) ||    at QVBWrapper.Document.CreateQVBProcess

                 

                Tidal Result log error:

                The HTTP request is unauthorized with client authentication scheme 'Ntlm'. The authentication header received from the server was 'NTLM'.

                Retry in 10s...

                Failed to create a client to the specified Uri, retries=1.

                The HTTP request is unauthorized with client authentication scheme 'Ntlm'. The authentication header received from the server was 'NTLM'.

                 

                Computer Management--> Event Viewer log

                 

                Warning: Failed to allocate new QlikView Engine. Retrying! Current usage count=2 of 4 (of type non-reader).

                 

                 

                Please advise.

                 

                Thanks

                 

                Regards

                Vindhya