Rhino Compute not working with IIS

So I set up a remote Compute server using the tutorial on Rhino - Deployment to Production Servers.

Everything should be installed now, but somehow, it doesn’t work, even localhost isn’t reachable on said VM.

More observations:

  • I can start Rhino 7 on the VM and it doesn’t ask for a license, so core hour billing should be set up correctly
  • There is a RhinoComputeUser set up on the VM, I can sign it to that account and copied some GH scripts there
  • Starting compute.geometry.exe manually in a command line does work and I can reach it from inside the VM (localhost) and outside (from another machine)
  • Starting rhino.compute.exe does NOT work correctly. It looks like it starts up the main process, but spawns no compute.geometry children. Also, localhost is unavailable in that scenario
  • Installation with the PS scripts did not work flawlessly and I ran some parts two or more times and did end up installing Rhino manually on the VM.

Any ideas what could be the issue here?

Rhino Compute in a terminal, not launching child processes:

Trying to reach it while the above is running:

Running Compute.Geometry directly:

Reaching the VM with Compute.Geometry running directly:

@ThomasM I’m sorry to hear that the installation didn’t work smoothly. I guess I’d love to know what parts of the bootstrap script didn’t work correctly… but that’s for a different time. Regarding your issue… I’m not 100% sure that it’s not working. First, notice that the 4th line in your console screenshot says that the “Spawn children on start is set to False”… That is the correct behavior BTW when running rhino.compute.exe on a VM. However, it does mean that it won’t automatically start the compute.geometry children by default. To get the children to “launch”, you need to send a valid request which requires the children in some capacity. The easiest way to do this is to send a GET request to the endpoint /activechildren. This should return an integer value with the number of children that are currently active. The first time you send it, it will likely come back as 0, but just the act of sending that request should kick off the “spawning” process of kicking off the children processes. So, you should start to see more stuff happening in the console window when that happens. Can you try that and see if any children get launched that way?

Hi @AndyPayne ,

what did not work was the installation of Rhino itself. Not sure, why, but it wasn’t installed after finishing everything. I did that manually by basically copying the relevant parts from your scripts on Github to the command line.

As for the issue: I just restarted the VM to make sure everything is new and shiny and sent the request. See the answer below:

(I did send it several times, also waited a few minutes and sent again. Always the same result.)

It looks like the request isn’t getting through because the API key is not correct. I think the issue is not the value, but the word ApiKey that you’re using. I think you need to use RhinoComputeKey as the key in the Header of your request.

That did work! Thanks a lot!

Also, the original use case using Hops did now work. Not sure what is/was different now, but at the moment, it works.

Ok. I’m glad it seems to be working… Now, you shouldn’t have to manually launch the rhino.compute.exe at all. This should all be handled via IIS. In fact, you should probably close that instance and restart the VM. When you launch your VM, IIS should handle launching rhino.compute.exe for you. Then, if you send it a valid request (either to the /activechildren endpoint or by sending it a definition via Hops) then it should handle spinning up the children for you. Can you try sending it a Hops definition from your local machine (to your remote VM) and see if that works now. Make sure to input the correct URL and API Key in the Hops preferences before sending the Hops request.

Ah, yes, sorry for the confusion. I did all the tests you asked for with a restarted VM and without manually launching the rhino-compute.exe. So, it seems that IIS is working (also with a GH definition via Hops).

I will do some more tests with it and come back to you in case I find other issues.

Thanks again!

Great. Glad it’s working for you.