ok so I have this magento 2 in a aws server 16 GB RAM, 4 vCPUs, 320 GB SSD. works perfectly.
Today I had a live stream so I made a simple html page with the embedded code for the video and it had a paywall to watch the video. I was a little worried it had a call for a JS file that had 38 mb.
I asked around many times :
do playing live video causes problem in my server if is embedded? everyone said no because is being streamed from vimeo not your server. so I was calm.
20 minutes before the live stream, the site went down. around 4000 people were on the site at that moment.
I check the CPU usage on lightsail it says is in the burstable zone but it was never even over 50% but the site still couldn't be reached it. browsers were giving this error:
ERR_CONNECTION_TIMED_OUT
However I could login with SSH. and even run commands. so it was weird this never happened to before.
The Outgoing network traffic was showing 112 MB, is that too much?
I restarted the server, did a clean cache, setup upgrade etc is like the site was not reachable at all even seconds after restarting.
So I created a new instance with a server with double capacity and pointed the domain to it. but it took around 20 minutes or more to appear online.
So I don't know if is working because the traffic was lower after 20 minutes or that the new server DNS was just distributing during this time.
I am still not 100% why the site went down. 2 days prior we have over 3000 people in the site and it was ok today we have 4000 and it went down for 30 minutes.
Only difference is that today they were visiting that html page with the embedded code. could it be only that? HELP