0

We have Sitecore 9.1.1 - JSS instance at my local machine. While opening page in the experience editor we are getting below error message:

Exception: System.InvalidOperationException
Message: Failed to start Node process. To resolve this:

[1] Ensure that the configured path to the Node.js executable is valid.
    Configured executable path: C:\Program Files\nodejs\
    Make sure the Node executable is available at this path.

[2] See the InnerException for further details of the cause.
Source: Sitecore.JavaScriptServices.ViewEngine.NodeServices
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.HostingModels.OutOfProcessNodeInstance.LaunchNodeProcess(ProcessStartInfo startInfo)
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.HostingModels.OutOfProcessNodeInstance..ctor(String entryPointScript, String projectPath, String[] watchFileExtensions, String commandLineArguments, ILogger nodeOutputLogger, IDictionary`2 environmentVars, Int32 invocationTimeoutMilliseconds, Boolean launchWithDebugging, Int32 debuggingPort, String nodePath)
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.HostingModels.Http.HttpNodeInstance..ctor(NodeServicesOptions options, Int32 port)
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.NodeServicesOptions.<.ctor>b__3_0()
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.DefaultNodeServices.GetOrCreateCurrentNodeInstance()
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.DefaultNodeServices.InvokeExportWithPossibleRetry[T](String moduleName, String exportedFunctionName, Object[] args, Boolean allowRetry)
   at Sitecore.JavaScriptServices.ViewEngine.NodeServices.DefaultNodeServices.InvokeExport[T](String moduleName, String exportedFunctionName, Object[] args)
   at Sitecore.JavaScriptServices.ViewEngine.Node.NodeRenderEngine.Invoke[T](String moduleName, String functionName, Object[] functionArgs)
   at Sitecore.JavaScriptServices.ViewEngine.Presentation.JssRenderer.PerformRender(TextWriter writer, IRenderEngine renderEngine, String moduleName, String functionName, Object[] functionArgs)
   at Sitecore.JavaScriptServices.ViewEngine.Presentation.JssRenderer.Render(TextWriter writer)
   at Sitecore.Mvc.Pipelines.Response.RenderRendering.ExecuteRenderer.Render(Renderer renderer, TextWriter writer, RenderRenderingArgs args)

We have checked the following things:

  1. Update the node path in the file Sitecore.JavaScriptServices.ViewEngine.Node.config

<NodePath>C:\Program Files\nodejs\</NodePath>

  1. Given full permission to user everyone on the above mentioned (#1) path.
  2. Uninstalled the NodeJs and re-installed the NodeJS. But no luck..
  3. Checked blog(https://gary.wenneker.org/sitecore-jss-failed-to-start-node-process/). Since we have just one version of NodeJs installed on our local instance, so NVM has not use for us.

Seeking help here from community ...

| improve this question | | | | |
  • Maybe the NodePath parameter's location path is not correct, Did you verify nodejs is installed in that path ? – Abhay Dhar Apr 11 at 5:20
0

Node path should include node.exe as well. So it's value should be:

<NodePath>C:\Program Files\nodejs\node.exe</NodePath>

| improve this answer | | | | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.