Robot randomly disconnects after an Orchestrator upgrade

Why does the robot randomly disconnect after an Orchestrator upgrade?

After an Orchestrator upgrade to 23.4 or newer, the UiPath Robot might randomly disconnect or lose connection to Orchestrator.

This is because the newer versions of Orchestrator use the ASP.NET version 6, which is listed as a prerequisite for the installation.

In order to fix this, upgrade the ASP.NET package to version 6 on the server where UiPath Orchestrator is installed.
Find the installation bundle on this Microsoft page.

Run powershell as an admin on the server and run the iisreset command.