Compute server down after ec2 restart + bootstrap file issues

I had set up an AWS EC2 Rhino.Compute server which was working fine throughout testing. Before deploying my website, I wanted to reset an AWS access key that could’ve been compromised so I stopped the ec2 instance, attached a new key and restarted. I’m nearly certain that’s the only change I made that affected the compute server. Afterwards, my calls to the server would cause timeouts. I checked that the server was running (pinging activechildren and healthcheck also worked). The logs on the server showed this error:

2023-09-17 00:33:14.012 +00:00 [INF] Rhino compute started at 9/17/2023 12:33:13 AM
2023-09-17 00:33:14.213 +00:00 [INF] Initiliazing reverse proxy at 9/17/2023 12:33:14 AM
2023-09-17 00:33:14.213 +00:00 [INF] Spawn children at startup is set to False
2023-09-17 00:33:14.407 +00:00 [INF] Application started. Press Ctrl+C to shut down.
2023-09-17 00:33:14.409 +00:00 [INF] Hosting environment: Production
2023-09-17 00:33:14.410 +00:00 [INF] Content root path: C:\inetpub\wwwroot\aspnet_client\system_web\4_0_30319\rhino.compute
2023-09-17 00:33:14.503 +00:00 [INF] HTTP GET / responded 401 in 43.5986 ms
2023-09-17 00:33:14.663 +00:00 [ERR] HTTP POST /rhino/geometry/areamassproperties/compute-curve responded 500 in 85.6233 ms
System.Exception: No compute server found
   at rhino.compute.ComputeChildren.GetComputeServerBaseUrl() in /home/runner/work/compute.rhino3d/compute.rhino3d/src/rhino.compute/ComputeChildren.cs:line 108
   at rhino.compute.ReverseProxyModule.ReverseProxyPost(HttpRequest req, HttpResponse res) in /home/runner/work/compute.rhino3d/compute.rhino3d/src/rhino.compute/ReverseProxy.cs:line 177
   at Carter.CarterExtensions.<>c__DisplayClass1_0.<<CreateRouteHandler>b__0>d.MoveNext()
--- End of stack trace from previous location ---
   at Microsoft.AspNetCore.Routing.EndpointMiddleware.<Invoke>g__AwaitRequestTask|6_0(Endpoint endpoint, Task requestTask, ILogger logger)
   at rhino.compute.ApiKeyMiddleware.InvokeAsync(HttpContext context) in /home/runner/work/compute.rhino3d/compute.rhino3d/src/rhino.compute/ApiKeyMiddleware.cs:line 34
   at Serilog.AspNetCore.RequestLoggingMiddleware.Invoke(HttpContext httpContext)
2023-09-17 00:33:14.715 +00:00 [ERR] Connection ID "18302628886439002114", Request ID "40000003-0000-fe00-b63f-84710c7967bb": An unhandled exception was thrown by the application.

I tried updating rhino on my VM according to the guide and that didn’t work. It prompts you for an email address and when I put mine in it raised this error:

Then because I wanted to speed things along and thought that maybe I managed to mess something up, I started a new instance from scratch. Following the guide, I ran the first bootstrap script and got the following error:

As always, any help would be much appreciated!

Hmm… You said you started a new instance from scratch and then ran the bootstrap script and it fails installing Rhino? That’s from a brand new EC2 instance? The download URL that’s used in the bootstrap script should be https://www.rhino3d.com/download/rhino-for-windows/7/latest/direct?email=EnterYourEmailHere You need to replace the last part that says EnterYourEmailHere with a valid email address. If you copy that URL into a browser and replace the last part with a valid email, does your browser download the file?

I should’ve relayed this sooner because I just saw someone link to this post with the same issue. I’m fairly sure my issue was that I had either a trailing or a leading space in the API key I had copy-pasted. The script didn’t raise any kind of error when I inputted the key, but I would get the errors above. After I generated a new key and more carefully copied it, the bootstrap scripts ran without a problem.

1 Like