none
"No process is associated with this object" - does this process means the HPCServiceHost process? RRS feed

  • Question

  • We have several environments (TEST, DEV, PROD, etc) but we are able to run excel jobs in some of them and failed in the others. I looked at the event logs under Microsoft/HPC/Excel and found many of below two kinda errors:

    Task 1 -
    ExcelService failed to handle a request on CGXU980C01. The failure was caused
    by a configuration, installation, or resource accessibility problem:
    System.InvalidOperationException: No process is associated with this object.   at
    System.Diagnostics.Process.EnsureState(State state)   at
    System.Diagnostics.Process.get_HasExited()   at
    Microsoft.Hpc.Excel.ExcelService.Calculate(String macroName, Byte[] inputs,
    Nullable`1 lastSaveDate)
    Error while starting Excel process: System.InvalidOperationException: No process is
    associated with this object.   at
    System.Diagnostics.Process.EnsureState(State state)   at
    System.Diagnostics.Process.EnsureState(State state)   at
    System.Diagnostics.Process.EnsureState(State state)   at
    System.Diagnostics.Process.get_MainWindowHandle()   at
    Microsoft.Hpc.Excel.ExcelDriver.LaunchExcelProcess()   at
    Microsoft.Hpc.Excel.ExcelDriver.OpenWorkbook(String filePath, Boolean
    updateLinks, String password, String writeResPassword, Nullable`1 lastSaveDate)

    Don't quite understand what happened, compared to the environments that have excel jobs running successfully, there seemed no difference.

    Anyone encountered similar issues? Does this "No process" means the HPCServiceHost process?

     

    Thanks,

    Marvin

    Monday, March 14, 2016 5:43 AM

All replies

  • There was another error which said "unreadable content", this was resolved after applied what Yutong suggested, to use the HPC_ATTACHTOPROCESS=Try in HPCServiceRegistration config and had the service credential logged on the compute node(s). However the IT division updated the server recently and had the service session logged off. After I asked them the logged on the service account again, the "unreadable content" issue went away, and this "No process associated" issue also went away..
    Tuesday, March 15, 2016 3:45 AM
  • Hi Marvin,

    That's right. The "System.InvalidOperationException: No process is associated with this object." is thrown when calling the ExcelProcess.MainWindowHandle in the ExcelDriver.LaunchExcelProcess() but the Excel process has exited. Running Excel without user log-on sessions may lead to such an issue especially when there are many cores/service hosts launching many Excel processes at the same time. One of the solutions is to use <add name="HPC_ATTACHTOSESSION" value="Try"/> in the service registration file, and use the built-in RDP console or the RDCMan tool to create user RDP sessions. Alternatively, using value="True" for "HPC_ATTACHTOSESSION" would force the service hosts to launch Excel in the user log-on session and failing the whole job if no session is available.

    BR,

    Yutong Sun

    Tuesday, March 15, 2016 9:22 AM
    Moderator