I created an "Instance" in Google Cloud (Windows server 2016 with RDP). On this server, I launch a console application (written in C ++), the simplest example of a web server. The web server listens on port 2246 and sends an OK response regardless of the request. After launching the application, I exit RDP and on a remote Linux server (online.net Data Centre) I begin to send requests to Google Instance every 2 seconds. If Google instance does not respond within 2 seconds, I get an email (this email is sent to me by the Linux server). As soon as the connection to the Google instance is restored, I receive an email stating that the connection is established.
The problem occurs several times a day, sometimes the connection is broken for 10 minutes, sometimes for several hours. At the time of the disconnection, I can not access the Windows server via RDP. After recovery, which happens by itself, I see in the Event Log that the RDP process has ended with an error
The RDP port is closed for everyone except me, and even if you do not log in via RDP, the process ends with an error and because of it the Google instance stops responding to any of the ports. The problem is also that using dedicated servers I could specify in my simple C ++ application that it listened to EXTERNAL IP and port, so even if there was a problem with RDP (there are errors every day on all our windows servers 2012-2019) the server kept responding. But on the Google Instance I can point my web server to listen only INTERNAL IP.
What should bedone in this situation? Is it possible to solve the problem with the instability of the RDP process? I want stable operation of windows servers and move from dedicated servers to cloud servers.