1

I have deployed loopback backend application in ec2 instance. I am using Pm2 server. How can I calculate ram and cpu for traffic or hit ?

MLu
  • 24,849
  • 5
  • 59
  • 86

1 Answers1

1

With EC2 you don’t have to make it right from the start because it’s easy to change the instance size later.

For start make a guess - e.g. new project may be ok with t3.small, moderately busy site may do for example with m5.large, etc. Once it’s up and running monitor the CPU and memory utilisation in CloudWatch and if the chosen instance type was too big for your needs downsize it, if it’s too small make it bigger. It’s easy.

Better yet deploy your app in Auto Scaling Group that will automatically adjust the number of running instances based on the traffic. That way you don’t have to pay for over-provisioned resources.

Hope that helps :)

MLu
  • 24,849
  • 5
  • 59
  • 86